diff --git a/implementations/om-1.0.0-alpha/.gitignore b/implementations/om-1.0.0-alpha/.gitignore new file mode 100644 index 000000000..708713c94 --- /dev/null +++ b/implementations/om-1.0.0-alpha/.gitignore @@ -0,0 +1,3 @@ +pom.xml +target +out diff --git a/implementations/om-1.0.0-alpha/app.js b/implementations/om-1.0.0-alpha/app.js new file mode 100644 index 000000000..e9fe0d2bb --- /dev/null +++ b/implementations/om-1.0.0-alpha/app.js @@ -0,0 +1,12056 @@ +if(typeof Math.imul == "undefined" || (Math.imul(0xffffffff,5) == 0)) { + Math.imul = function (a, b) { + var ah = (a >>> 16) & 0xffff; + var al = a & 0xffff; + var bh = (b >>> 16) & 0xffff; + var bl = b & 0xffff; + // the shift by 0 fixes the sign on the high part + // the final |0 converts the unsigned value into a signed value + return ((al * bl) + (((ah * bl + al * bh) << 16) >>> 0)|0); + } +} + +/** + * React v15.3.1 + * + * Copyright 2013-present, Facebook, Inc. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. An additional grant + * of patent rights can be found in the PATENTS file in the same directory. + * + */ +!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.React=e()}}(function(){return function e(t,n,r){function o(i,s){if(!n[i]){if(!t[i]){var u="function"==typeof require&&require;if(!s&&u)return u(i,!0);if(a)return a(i,!0);var l=new Error("Cannot find module '"+i+"'");throw l.code="MODULE_NOT_FOUND",l}var c=n[i]={exports:{}};t[i][0].call(c.exports,function(e){var n=t[i][1][e];return o(n?n:e)},c,c.exports,e,t,n,r)}return n[i].exports}for(var a="function"==typeof require&&require,i=0;i8&&x<=11),w=32,P=String.fromCharCode(w),k=f.topLevelTypes,M={beforeInput:{phasedRegistrationNames:{bubbled:b({onBeforeInput:null}),captured:b({onBeforeInputCapture:null})},dependencies:[k.topCompositionEnd,k.topKeyPress,k.topTextInput,k.topPaste]},compositionEnd:{phasedRegistrationNames:{bubbled:b({onCompositionEnd:null}),captured:b({onCompositionEndCapture:null})},dependencies:[k.topBlur,k.topCompositionEnd,k.topKeyDown,k.topKeyPress,k.topKeyUp,k.topMouseDown]},compositionStart:{phasedRegistrationNames:{bubbled:b({onCompositionStart:null}),captured:b({onCompositionStartCapture:null})},dependencies:[k.topBlur,k.topCompositionStart,k.topKeyDown,k.topKeyPress,k.topKeyUp,k.topMouseDown]},compositionUpdate:{phasedRegistrationNames:{bubbled:b({onCompositionUpdate:null}),captured:b({onCompositionUpdateCapture:null})},dependencies:[k.topBlur,k.topCompositionUpdate,k.topKeyDown,k.topKeyPress,k.topKeyUp,k.topMouseDown]}},S=!1,R=null,O={eventTypes:M,extractEvents:function(e,t,n,r){return[l(e,t,n,r),d(e,t,n,r)]}};t.exports=O},{140:140,158:158,16:16,20:20,21:21,95:95,99:99}],3:[function(e,t,n){"use strict";function r(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}var o={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridColumn:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},a=["Webkit","ms","Moz","O"];Object.keys(o).forEach(function(e){a.forEach(function(t){o[r(t,e)]=o[e]})});var i={background:{backgroundAttachment:!0,backgroundColor:!0,backgroundImage:!0,backgroundPositionX:!0,backgroundPositionY:!0,backgroundRepeat:!0},backgroundPosition:{backgroundPositionX:!0,backgroundPositionY:!0},border:{borderWidth:!0,borderStyle:!0,borderColor:!0},borderBottom:{borderBottomWidth:!0,borderBottomStyle:!0,borderBottomColor:!0},borderLeft:{borderLeftWidth:!0,borderLeftStyle:!0,borderLeftColor:!0},borderRight:{borderRightWidth:!0,borderRightStyle:!0,borderRightColor:!0},borderTop:{borderTopWidth:!0,borderTopStyle:!0,borderTopColor:!0},font:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,lineHeight:!0,fontFamily:!0},outline:{outlineWidth:!0,outlineStyle:!0,outlineColor:!0}},s={isUnitlessNumber:o,shorthandPropertyExpansions:i};t.exports=s},{}],4:[function(e,t,n){"use strict";var r=e(3),o=e(140),a=(e(66),e(142),e(113)),i=e(153),s=e(159),u=(e(161),s(function(e){return i(e)})),l=!1,c="cssFloat";if(o.canUseDOM){var p=document.createElement("div").style;try{p.font=""}catch(e){l=!0}void 0===document.documentElement.style.cssFloat&&(c="styleFloat")}var d={createMarkupForStyles:function(e,t){var n="";for(var r in e)if(e.hasOwnProperty(r)){var o=e[r];null!=o&&(n+=u(r)+":",n+=a(r,o,t)+";")}return n||null},setValueForStyles:function(e,t,n){var o=e.style;for(var i in t)if(t.hasOwnProperty(i)){var s=a(i,t[i],n);if("float"!==i&&"cssFloat"!==i||(i=c),s)o[i]=s;else{var u=l&&r.shorthandPropertyExpansions[i];if(u)for(var p in u)o[p]="";else o[i]=""}}}};t.exports=d},{113:113,140:140,142:142,153:153,159:159,161:161,3:3,66:66}],5:[function(e,t,n){"use strict";function r(){this._callbacks=null,this._contexts=null}var o=e(132),a=e(162),i=e(25);e(154);a(r.prototype,{enqueue:function(e,t){this._callbacks=this._callbacks||[],this._contexts=this._contexts||[],this._callbacks.push(e),this._contexts.push(t)},notifyAll:function(){var e=this._callbacks,t=this._contexts;if(e){e.length!==t.length?o("24"):void 0,this._callbacks=null,this._contexts=null;for(var n=0;n8));var L=!1;_.canUseDOM&&(L=w("input")&&(!("documentMode"in document)||document.documentMode>11));var U={get:function(){return D.get.call(this)},set:function(e){I=""+e,D.set.call(this,e)}},F={eventTypes:S,extractEvents:function(e,t,n,o){var a,i,s=t?E.getNodeFromInstance(t):window;if(r(s)?A?a=u:i=l:P(s)?L?a=f:(a=m,i=h):v(s)&&(a=g),a){var c=a(e,t);if(c){var p=T.getPooled(S.change,c,n,o);return p.type="change",C.accumulateTwoPhaseDispatches(p),p}}i&&i(e,s,t)}};t.exports=F},{121:121,128:128,129:129,140:140,158:158,16:16,17:17,20:20,40:40,88:88,97:97}],7:[function(e,t,n){"use strict";function r(e,t){return Array.isArray(t)&&(t=t[1]),t?t.nextSibling:e.firstChild}function o(e,t,n){c.insertTreeBefore(e,t,n)}function a(e,t,n){Array.isArray(t)?s(e,t[0],t[1],n):v(e,t,n)}function i(e,t){if(Array.isArray(t)){var n=t[1];t=t[0],u(e,t,n),e.removeChild(n)}e.removeChild(t)}function s(e,t,n,r){for(var o=t;;){var a=o.nextSibling;if(v(e,o,r),o===n)break;o=a}}function u(e,t,n){for(;;){var r=t.nextSibling;if(r===n)break;e.removeChild(r)}}function l(e,t,n){var r=e.parentNode,o=e.nextSibling;o===t?n&&v(r,document.createTextNode(n),o):n?(m(o,n),u(r,o,t)):u(r,e,t)}var c=e(8),p=e(12),d=e(70),f=(e(40),e(66),e(112)),h=e(134),m=e(135),v=f(function(e,t,n){e.insertBefore(t,n)}),g=p.dangerouslyReplaceNodeWithMarkup,y={dangerouslyReplaceNodeWithMarkup:g,replaceDelimitedText:l,processUpdates:function(e,t){for(var n=0;n-1?void 0:i("96",e),!l.plugins[n]){t.extractEvents?void 0:i("97",e),l.plugins[n]=t;var r=t.eventTypes;for(var a in r)o(r[a],t,a)?void 0:i("98",a,e)}}}function o(e,t,n){l.eventNameDispatchConfigs.hasOwnProperty(n)?i("99",n):void 0,l.eventNameDispatchConfigs[n]=e;var r=e.phasedRegistrationNames;if(r){for(var o in r)if(r.hasOwnProperty(o)){var s=r[o];a(s,t,n)}return!0}return!!e.registrationName&&(a(e.registrationName,t,n),!0)}function a(e,t,n){l.registrationNameModules[e]?i("100",e):void 0,l.registrationNameModules[e]=t,l.registrationNameDependencies[e]=t.eventTypes[n].dependencies}var i=e(132),s=(e(154),null),u={},l={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},possibleRegistrationNames:null,injectEventPluginOrder:function(e){s?i("101"):void 0,s=Array.prototype.slice.call(e),r()},injectEventPluginsByName:function(e){var t=!1;for(var n in e)if(e.hasOwnProperty(n)){var o=e[n];u.hasOwnProperty(n)&&u[n]===o||(u[n]?i("102",n):void 0,u[n]=o,t=!0)}t&&r()},getPluginModuleForEvent:function(e){var t=e.dispatchConfig;if(t.registrationName)return l.registrationNameModules[t.registrationName]||null;for(var n in t.phasedRegistrationNames)if(t.phasedRegistrationNames.hasOwnProperty(n)){var r=l.registrationNameModules[t.phasedRegistrationNames[n]];if(r)return r}return null},_resetEventPlugins:function(){s=null;for(var e in u)u.hasOwnProperty(e)&&delete u[e];l.plugins.length=0;var t=l.eventNameDispatchConfigs;for(var n in t)t.hasOwnProperty(n)&&delete t[n];var r=l.registrationNameModules;for(var o in r)r.hasOwnProperty(o)&&delete r[o]}};t.exports=l},{132:132,154:154}],19:[function(e,t,n){"use strict";function r(e){return e===y.topMouseUp||e===y.topTouchEnd||e===y.topTouchCancel}function o(e){return e===y.topMouseMove||e===y.topTouchMove}function a(e){return e===y.topMouseDown||e===y.topTouchStart}function i(e,t,n,r){var o=e.type||"unknown-event";e.currentTarget=b.getNodeFromInstance(r),t?v.invokeGuardedCallbackWithCatch(o,n,e):v.invokeGuardedCallback(o,n,e),e.currentTarget=null}function s(e,t){var n=e._dispatchListeners,r=e._dispatchInstances;if(Array.isArray(n))for(var o=0;o1?1-t:void 0;return this._fallbackText=o.slice(e,s),this._fallbackText}}),a.addPoolingTo(r),t.exports=r},{125:125,162:162,25:25}],22:[function(e,t,n){"use strict";var r=e(10),o=r.injection.MUST_USE_PROPERTY,a=r.injection.HAS_BOOLEAN_VALUE,i=r.injection.HAS_NUMERIC_VALUE,s=r.injection.HAS_POSITIVE_NUMERIC_VALUE,u=r.injection.HAS_OVERLOADED_BOOLEAN_VALUE,l={isCustomAttribute:RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+r.ATTRIBUTE_NAME_CHAR+"]*$")),Properties:{accept:0,acceptCharset:0,accessKey:0,action:0,allowFullScreen:a,allowTransparency:0,alt:0,async:a,autoComplete:0,autoPlay:a,capture:a,cellPadding:0,cellSpacing:0,charSet:0,challenge:0,checked:o|a,cite:0,classID:0,className:0,cols:s,colSpan:0,content:0,contentEditable:0,contextMenu:0,controls:a,coords:0,crossOrigin:0,data:0,dateTime:0,default:a,defer:a,dir:0,disabled:a,download:u,draggable:0,encType:0,form:0,formAction:0,formEncType:0,formMethod:0,formNoValidate:a,formTarget:0,frameBorder:0,headers:0,height:0,hidden:a,high:0,href:0,hrefLang:0,htmlFor:0,httpEquiv:0,icon:0,id:0,inputMode:0,integrity:0,is:0,keyParams:0,keyType:0,kind:0,label:0,lang:0,list:0,loop:a,low:0,manifest:0,marginHeight:0,marginWidth:0,max:0,maxLength:0,media:0,mediaGroup:0,method:0,min:0,minLength:0,multiple:o|a,muted:o|a,name:0,nonce:0,noValidate:a,open:a,optimum:0,pattern:0,placeholder:0,poster:0,preload:0,profile:0,radioGroup:0,readOnly:a,referrerPolicy:0,rel:0,required:a,reversed:a,role:0,rows:s,rowSpan:i,sandbox:0,scope:0,scoped:a,scrolling:0,seamless:a,selected:o|a,shape:0,size:s,sizes:0,span:s,spellCheck:0,src:0,srcDoc:0,srcLang:0,srcSet:0,start:i,step:0,style:0,summary:0,tabIndex:0,target:0,title:0,type:0,useMap:0,value:0,width:0,wmode:0,wrap:0,about:0,datatype:0,inlist:0,prefix:0,property:0,resource:0,typeof:0,vocab:0,autoCapitalize:0,autoCorrect:0,autoSave:0,color:0,itemProp:0,itemScope:a,itemType:0,itemID:0,itemRef:0,results:0,security:0,unselectable:0},DOMAttributeNames:{acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv"},DOMPropertyNames:{}};t.exports=l},{10:10}],23:[function(e,t,n){"use strict";function r(e){var t=/[=:]/g,n={"=":"=0",":":"=2"},r=(""+e).replace(t,function(e){return n[e]});return"$"+r}function o(e){var t=/(=0|=2)/g,n={"=0":"=","=2":":"},r="."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1);return(""+r).replace(t,function(e){return n[e]})}var a={escape:r,unescape:o};t.exports=a},{}],24:[function(e,t,n){"use strict";function r(e){null!=e.checkedLink&&null!=e.valueLink?s("87"):void 0}function o(e){r(e),null!=e.value||null!=e.onChange?s("88"):void 0}function a(e){r(e),null!=e.checked||null!=e.onChange?s("89"):void 0}function i(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}var s=e(132),u=e(76),l=e(75),c=e(77),p=(e(154),e(161),{button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0}),d={value:function(e,t,n){return!e[t]||p[e.type]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.")},checked:function(e,t,n){return!e[t]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")},onChange:u.func},f={},h={checkPropTypes:function(e,t,n){for(var r in d){if(d.hasOwnProperty(r))var o=d[r](t,r,e,l.prop,null,c);o instanceof Error&&!(o.message in f)&&(f[o.message]=!0,i(n))}},getValue:function(e){return e.valueLink?(o(e),e.valueLink.value):e.value},getChecked:function(e){return e.checkedLink?(a(e),e.checkedLink.value):e.checked},executeOnChange:function(e,t){return e.valueLink?(o(e),e.valueLink.requestChange(t.target.value)):e.checkedLink?(a(e),e.checkedLink.requestChange(t.target.checked)):e.onChange?e.onChange.call(void 0,t):void 0}};t.exports=h},{132:132,154:154,161:161,75:75,76:76,77:77}],25:[function(e,t,n){"use strict";var r=e(132),o=(e(154),function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)}),a=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},i=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},s=function(e,t,n,r){var o=this;if(o.instancePool.length){var a=o.instancePool.pop();return o.call(a,e,t,n,r),a}return new o(e,t,n,r)},u=function(e,t,n,r,o){var a=this;if(a.instancePool.length){var i=a.instancePool.pop();return a.call(i,e,t,n,r,o),i}return new a(e,t,n,r,o)},l=function(e){var t=this;e instanceof t?void 0:r("25"),e.destructor(),t.instancePool.length=0||null!=t.is}function h(e){var t=e.type;d(t),this._currentElement=e,this._tag=t.toLowerCase(),this._namespaceURI=null,this._renderedChildren=null,this._previousStyle=null,this._previousStyleCopy=null,this._hostNode=null,this._hostParent=null,this._rootNodeID=0,this._domID=0,this._hostContainerInfo=null,this._wrapperState=null,this._topLevelWrapper=null,this._flags=0}var m=e(132),v=e(162),g=e(1),y=e(4),b=e(8),C=e(9),_=e(10),E=e(11),x=e(16),T=e(17),N=e(18),w=e(27),P=e(37),k=e(39),M=e(40),S=e(46),R=e(47),O=e(48),I=e(52),D=(e(66),e(69)),A=e(84),L=(e(146),e(114)),U=(e(154),e(128),e(158)),F=(e(160),e(138),e(161),k),V=T.deleteListener,j=M.getNodeFromInstance,B=w.listenTo,W=N.registrationNameModules,H={string:!0,number:!0},q=U({style:null}),K=U({__html:null}),Y={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null},z=11,X={topAbort:"abort",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topSeeked:"seeked",topSeeking:"seeking",topStalled:"stalled",topSuspend:"suspend",topTimeUpdate:"timeupdate",topVolumeChange:"volumechange",topWaiting:"waiting"},G={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},Q={listing:!0,pre:!0,textarea:!0},$=v({menuitem:!0},G),Z=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,J={},ee={}.hasOwnProperty,te=1;h.displayName="ReactDOMComponent",h.Mixin={mountComponent:function(e,t,n,r){this._rootNodeID=te++,this._domID=n._idCounter++,this._hostParent=t,this._hostContainerInfo=n;var a=this._currentElement.props;switch(this._tag){case"audio":case"form":case"iframe":case"img":case"link":case"object":case"source":case"video":this._wrapperState={listeners:null},e.getReactMountReady().enqueue(c,this);break;case"button":a=P.getHostProps(this,a,t);break;case"input":S.mountWrapper(this,a,t),a=S.getHostProps(this,a),e.getReactMountReady().enqueue(c,this);break;case"option":R.mountWrapper(this,a,t),a=R.getHostProps(this,a);break;case"select":O.mountWrapper(this,a,t),a=O.getHostProps(this,a),e.getReactMountReady().enqueue(c,this);break;case"textarea":I.mountWrapper(this,a,t),a=I.getHostProps(this,a),e.getReactMountReady().enqueue(c,this)}o(this,a);var i,p;null!=t?(i=t._namespaceURI,p=t._tag):n._tag&&(i=n._namespaceURI,p=n._tag),(null==i||i===C.svg&&"foreignobject"===p)&&(i=C.html),i===C.html&&("svg"===this._tag?i=C.svg:"math"===this._tag&&(i=C.mathml)),this._namespaceURI=i;var d;if(e.useCreateElement){var f,h=n._ownerDocument;if(i===C.html)if("script"===this._tag){var m=h.createElement("div"),v=this._currentElement.type;m.innerHTML="<"+v+">",f=m.removeChild(m.firstChild)}else f=a.is?h.createElement(this._currentElement.type,a.is):h.createElement(this._currentElement.type);else f=h.createElementNS(i,this._currentElement.type);M.precacheNode(this,f),this._flags|=F.hasCachedChildNodes,this._hostParent||E.setAttributeForRoot(f),this._updateDOMProperties(null,a,e);var y=b(f);this._createInitialChildren(e,a,r,y),d=y}else{var _=this._createOpenTagMarkupAndPutListeners(e,a),x=this._createContentMarkup(e,a,r);d=!x&&G[this._tag]?_+"/>":_+">"+x+""}switch(this._tag){case"input":e.getReactMountReady().enqueue(s,this),a.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"textarea":e.getReactMountReady().enqueue(u,this),a.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"select":a.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"button":a.autoFocus&&e.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"option":e.getReactMountReady().enqueue(l,this)}return d},_createOpenTagMarkupAndPutListeners:function(e,t){var n="<"+this._currentElement.type;for(var r in t)if(t.hasOwnProperty(r)){var o=t[r];if(null!=o)if(W.hasOwnProperty(r))o&&a(this,r,o,e);else{r===q&&(o&&(o=this._previousStyleCopy=v({},t.style)),o=y.createMarkupForStyles(o,this));var i=null;null!=this._tag&&f(this._tag,t)?Y.hasOwnProperty(r)||(i=E.createMarkupForCustomAttribute(r,o)):i=E.createMarkupForProperty(r,o),i&&(n+=" "+i)}}return e.renderToStaticMarkup?n:(this._hostParent||(n+=" "+E.createMarkupForRoot()),n+=" "+E.createMarkupForID(this._domID))},_createContentMarkup:function(e,t,n){var r="",o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&(r=o.__html);else{var a=H[typeof t.children]?t.children:null,i=null!=a?null:t.children;if(null!=a)r=L(a);else if(null!=i){var s=this.mountChildren(i,e,n);r=s.join("")}}return Q[this._tag]&&"\n"===r.charAt(0)?"\n"+r:r},_createInitialChildren:function(e,t,n,r){var o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&b.queueHTML(r,o.__html);else{var a=H[typeof t.children]?t.children:null,i=null!=a?null:t.children;if(null!=a)b.queueText(r,a);else if(null!=i)for(var s=this.mountChildren(i,e,n),u=0;u"},receiveComponent:function(){},getHostNode:function(){return a.getNodeFromInstance(this)},unmountComponent:function(){a.uncacheNode(this)}}),t.exports=i},{162:162,40:40,8:8}],43:[function(e,t,n){"use strict";var r=e(56),o=r.createFactory,a={a:o("a"),abbr:o("abbr"),address:o("address"),area:o("area"),article:o("article"),aside:o("aside"),audio:o("audio"),b:o("b"),base:o("base"),bdi:o("bdi"),bdo:o("bdo"),big:o("big"),blockquote:o("blockquote"),body:o("body"),br:o("br"),button:o("button"),canvas:o("canvas"),caption:o("caption"),cite:o("cite"),code:o("code"),col:o("col"),colgroup:o("colgroup"),data:o("data"),datalist:o("datalist"),dd:o("dd"),del:o("del"),details:o("details"),dfn:o("dfn"),dialog:o("dialog"),div:o("div"),dl:o("dl"),dt:o("dt"),em:o("em"),embed:o("embed"),fieldset:o("fieldset"),figcaption:o("figcaption"),figure:o("figure"),footer:o("footer"),form:o("form"),h1:o("h1"),h2:o("h2"),h3:o("h3"),h4:o("h4"),h5:o("h5"),h6:o("h6"),head:o("head"),header:o("header"),hgroup:o("hgroup"),hr:o("hr"),html:o("html"),i:o("i"),iframe:o("iframe"),img:o("img"),input:o("input"),ins:o("ins"),kbd:o("kbd"),keygen:o("keygen"),label:o("label"),legend:o("legend"),li:o("li"),link:o("link"),main:o("main"),map:o("map"),mark:o("mark"),menu:o("menu"),menuitem:o("menuitem"),meta:o("meta"),meter:o("meter"),nav:o("nav"),noscript:o("noscript"),object:o("object"),ol:o("ol"),optgroup:o("optgroup"),option:o("option"),output:o("output"),p:o("p"),param:o("param"),picture:o("picture"),pre:o("pre"),progress:o("progress"),q:o("q"),rp:o("rp"),rt:o("rt"),ruby:o("ruby"),s:o("s"),samp:o("samp"),script:o("script"),section:o("section"),select:o("select"),small:o("small"),source:o("source"),span:o("span"),strong:o("strong"),style:o("style"),sub:o("sub"),summary:o("summary"),sup:o("sup"),table:o("table"),tbody:o("tbody"),td:o("td"),textarea:o("textarea"),tfoot:o("tfoot"),th:o("th"),thead:o("thead"),time:o("time"),title:o("title"),tr:o("tr"),track:o("track"),u:o("u"),ul:o("ul"),var:o("var"),video:o("video"),wbr:o("wbr"),circle:o("circle"),clipPath:o("clipPath"),defs:o("defs"),ellipse:o("ellipse"),g:o("g"),image:o("image"),line:o("line"),linearGradient:o("linearGradient"),mask:o("mask"),path:o("path"),pattern:o("pattern"),polygon:o("polygon"),polyline:o("polyline"),radialGradient:o("radialGradient"),rect:o("rect"),stop:o("stop"),svg:o("svg"),text:o("text"),tspan:o("tspan")};t.exports=a},{56:56}],44:[function(e,t,n){"use strict";var r={useCreateElement:!0};t.exports=r},{}],45:[function(e,t,n){"use strict";var r=e(7),o=e(40),a={dangerouslyProcessChildrenUpdates:function(e,t){var n=o.getNodeFromInstance(e);r.processUpdates(n,t)}};t.exports=a},{40:40,7:7}],46:[function(e,t,n){"use strict";function r(){this._rootNodeID&&d.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=l.executeOnChange(t,e);p.asap(r,this);var o=t.name;if("radio"===t.type&&null!=o){for(var i=c.getNodeFromInstance(this),s=i;s.parentNode;)s=s.parentNode;for(var u=s.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),d=0;dt.end?(n=t.end,r=t.start):(n=t.start,r=t.end),o.moveToElementText(e),o.moveStart("character",n),o.setEndPoint("EndToStart",o),o.moveEnd("character",r-n),o.select()}function s(e,t){if(window.getSelection){var n=window.getSelection(),r=e[c()].length,o=Math.min(t.start,r),a=void 0===t.end?o:Math.min(t.end,r);if(!n.extend&&o>a){var i=a;a=o,o=i}var s=l(e,o),u=l(e,a);if(s&&u){var p=document.createRange();p.setStart(s.node,s.offset),n.removeAllRanges(),o>a?(n.addRange(p),n.extend(u.node,u.offset)):(p.setEnd(u.node,u.offset),n.addRange(p))}}}var u=e(140),l=e(124),c=e(125),p=u.canUseDOM&&"selection"in document&&!("getSelection"in window),d={getOffsets:p?o:a,setOffsets:p?i:s};t.exports=d},{124:124,125:125,140:140}],50:[function(e,t,n){"use strict";var r=e(55),o=e(83),a=e(89);r.inject();var i={renderToString:o.renderToString,renderToStaticMarkup:o.renderToStaticMarkup,version:a};t.exports=i},{55:55,83:83,89:89}],51:[function(e,t,n){"use strict";var r=e(132),o=e(162),a=e(7),i=e(8),s=e(40),u=e(114),l=(e(154),e(138),function(e){this._currentElement=e,this._stringText=""+e,this._hostNode=null,this._hostParent=null,this._domID=0,this._mountIndex=0,this._closingComment=null,this._commentNodes=null});o(l.prototype,{mountComponent:function(e,t,n,r){var o=n._idCounter++,a=" react-text: "+o+" ",l=" /react-text ";if(this._domID=o,this._hostParent=t,e.useCreateElement){var c=n._ownerDocument,p=c.createComment(a),d=c.createComment(l),f=i(c.createDocumentFragment());return i.queueChild(f,i(p)),this._stringText&&i.queueChild(f,i(c.createTextNode(this._stringText))),i.queueChild(f,i(d)),s.precacheNode(this,p),this._closingComment=d,f}var h=u(this._stringText);return e.renderToStaticMarkup?h:""+h+""},receiveComponent:function(e,t){if(e!==this._currentElement){this._currentElement=e;var n=""+e;if(n!==this._stringText){this._stringText=n;var r=this.getHostNode();a.replaceDelimitedText(r[0],r[1],n)}}},getHostNode:function(){var e=this._commentNodes;if(e)return e;if(!this._closingComment)for(var t=s.getNodeFromInstance(this),n=t.nextSibling;;){if(null==n?r("67",this._domID):void 0,8===n.nodeType&&" /react-text "===n.nodeValue){this._closingComment=n;break}n=n.nextSibling}return e=[this._hostNode,this._closingComment],this._commentNodes=e,e},unmountComponent:function(){this._closingComment=null,this._commentNodes=null,s.uncacheNode(this)}}),t.exports=l},{114:114,132:132,138:138,154:154,162:162,40:40,7:7,8:8}],52:[function(e,t,n){"use strict";function r(){this._rootNodeID&&p.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=u.executeOnChange(t,e);return c.asap(r,this),n}var a=e(132),i=e(162),s=e(14),u=e(24),l=e(40),c=e(88),p=(e(154),e(161),{getHostProps:function(e,t){null!=t.dangerouslySetInnerHTML?a("91"):void 0;var n=i({},s.getHostProps(e,t),{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue,onChange:e._wrapperState.onChange});return n},mountWrapper:function(e,t){var n=u.getValue(t),r=n;if(null==n){var i=t.defaultValue,s=t.children;null!=s&&(null!=i?a("92"):void 0,Array.isArray(s)&&(s.length<=1?void 0:a("93"),s=s[0]),i=""+s),null==i&&(i=""),r=i}e._wrapperState={initialValue:""+r,listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=l.getNodeFromInstance(e),r=u.getValue(t);if(null!=r){var o=""+r;o!==n.value&&(n.value=o),null==t.defaultValue&&(n.defaultValue=o)}null!=t.defaultValue&&(n.defaultValue=t.defaultValue)},postMountWrapper:function(e){var t=l.getNodeFromInstance(e);t.value=t.textContent}});t.exports=p},{132:132,14:14,154:154,161:161,162:162,24:24,40:40,88:88}],53:[function(e,t,n){"use strict";function r(e,t){"_hostNode"in e?void 0:u("33"),"_hostNode"in t?void 0:u("33");for(var n=0,r=e;r;r=r._hostParent)n++;for(var o=0,a=t;a;a=a._hostParent)o++;for(;n-o>0;)e=e._hostParent,n--;for(;o-n>0;)t=t._hostParent,o--;for(var i=n;i--;){if(e===t)return e;e=e._hostParent,t=t._hostParent}return null}function o(e,t){"_hostNode"in e?void 0:u("35"),"_hostNode"in t?void 0:u("35");for(;t;){if(t===e)return!0;t=t._hostParent}return!1}function a(e){return"_hostNode"in e?void 0:u("36"),e._hostParent}function i(e,t,n){for(var r=[];e;)r.push(e),e=e._hostParent;var o;for(o=r.length;o-- >0;)t(r[o],!1,n);for(o=0;o0;)n(u[l],!1,a)}var u=e(132);e(154);t.exports={isAncestor:o,getLowestCommonAncestor:r,getParentInstance:a,traverseTwoPhase:i,traverseEnterLeave:s}},{132:132,154:154}],54:[function(e,t,n){"use strict";function r(){this.reinitializeTransaction()}var o=e(162),a=e(88),i=e(106),s=e(146),u={initialize:s,close:function(){d.isBatchingUpdates=!1}},l={initialize:s,close:a.flushBatchedUpdates.bind(a)},c=[l,u];o(r.prototype,i.Mixin,{getTransactionWrappers:function(){return c}});var p=new r,d={isBatchingUpdates:!1,batchedUpdates:function(e,t,n,r,o,a){var i=d.isBatchingUpdates;d.isBatchingUpdates=!0,i?e(t,n,r,o,a):p.perform(e,null,t,n,r,o,a)}};t.exports=d},{106:106,146:146,162:162,88:88}],55:[function(e,t,n){"use strict";function r(){E||(E=!0,g.EventEmitter.injectReactEventListener(v),g.EventPluginHub.injectEventPluginOrder(i),g.EventPluginUtils.injectComponentTree(p),g.EventPluginUtils.injectTreeTraversal(f),g.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:_,EnterLeaveEventPlugin:s,ChangeEventPlugin:a,SelectEventPlugin:C,BeforeInputEventPlugin:o}),g.HostComponent.injectGenericComponentClass(c),g.HostComponent.injectTextComponentClass(h),g.DOMProperty.injectDOMPropertyConfig(u),g.DOMProperty.injectDOMPropertyConfig(b),g.EmptyComponent.injectEmptyComponentFactory(function(e){return new d(e)}),g.Updates.injectReconcileTransaction(y),g.Updates.injectBatchingStrategy(m),g.Component.injectEnvironment(l))}var o=e(2),a=e(6),i=e(13),s=e(15),u=e(22),l=e(32),c=e(38),p=e(40),d=e(42),f=e(53),h=e(51),m=e(54),v=e(60),g=e(63),y=e(79),b=e(90),C=e(91),_=e(92),E=!1;t.exports={inject:r}},{13:13,15:15,2:2,22:22,32:32,38:38,40:40,42:42,51:51,53:53,54:54,6:6,60:60,63:63,79:79,90:90,91:91,92:92}],56:[function(e,t,n){"use strict";function r(e){return void 0!==e.ref}function o(e){return void 0!==e.key}var a=e(162),i=e(35),s=(e(161),e(110),Object.prototype.hasOwnProperty),u="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,l={key:!0,ref:!0,__self:!0,__source:!0},c=function(e,t,n,r,o,a,i){var s={$$typeof:u,type:e,key:t,ref:n,props:i,_owner:a};return s};c.createElement=function(e,t,n){var a,u={},p=null,d=null,f=null,h=null;if(null!=t){r(t)&&(d=t.ref),o(t)&&(p=""+t.key),f=void 0===t.__self?null:t.__self,h=void 0===t.__source?null:t.__source;for(a in t)s.call(t,a)&&!l.hasOwnProperty(a)&&(u[a]=t[a])}var m=arguments.length-2;if(1===m)u.children=n;else if(m>1){for(var v=Array(m),g=0;g1){for(var b=Array(y),C=0;C/,a=/^<\!\-\-/,i={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(e){var t=r(e);return a.test(e)?e:e.replace(o," "+i.CHECKSUM_ATTR_NAME+'="'+t+'"$&')},canReuseMarkup:function(e,t){var n=t.getAttribute(i.CHECKSUM_ATTR_NAME);n=n&&parseInt(n,10);var o=r(e);return o===n}};t.exports=i},{109:109}],68:[function(e,t,n){"use strict";function r(e,t){for(var n=Math.min(e.length,t.length),r=0;r.":"function"==typeof t?" Instead of passing a class like Foo, pass React.createElement(Foo) or .":null!=t&&void 0!==t.props?" This may be caused by unintentionally loading two independent copies of React.":"");var i,s=C(F,null,null,null,null,null,t);if(e){var u=E.get(e);i=u._processChildContext(u._context)}else i=P;var c=d(n);if(c){var p=c._currentElement,h=p.props;if(S(h,t)){var m=c._renderedComponent.getPublicInstance(),v=r&&function(){r.call(m)};return V._updateRootComponent(c,s,i,n,v),m}V.unmountComponentAtNode(n)}var g=o(n),y=g&&!!a(g),b=l(n),_=y&&!c&&!b,x=V._renderNewRootComponent(s,n,_,i)._renderedComponent.getPublicInstance();return r&&r.call(x),x},render:function(e,t,n){return V._renderSubtreeIntoContainer(null,e,t,n)},unmountComponentAtNode:function(e){c(e)?void 0:f("40");var t=d(e);return t?(delete L[t._instance.rootID],w.batchedUpdates(u,t,e,!1),!0):(l(e),1===e.nodeType&&e.hasAttribute(O),!1)},_mountImageIntoNode:function(e,t,n,a,i){if(c(t)?void 0:f("41"),a){var s=o(t);if(x.canReuseMarkup(e,s))return void g.precacheNode(n,s);var u=s.getAttribute(x.CHECKSUM_ATTR_NAME);s.removeAttribute(x.CHECKSUM_ATTR_NAME);var l=s.outerHTML;s.setAttribute(x.CHECKSUM_ATTR_NAME,u);var p=e,d=r(p,l),m=" (client) "+p.substring(d-20,d+20)+"\n (server) "+l.substring(d-20,d+20);t.nodeType===D?f("42",m):void 0}if(t.nodeType===D?f("43"):void 0,i.useCreateElement){for(;t.lastChild;)t.removeChild(t.lastChild);h.insertTreeBefore(t,e,null)}else M(t,e),g.precacheNode(n,t.firstChild)}};t.exports=V},{10:10,127:127,132:132,134:134,136:136,147:147,154:154,161:161,27:27,35:35,40:40,41:41,44:44,56:56,61:61,65:65,66:66,67:67,8:8,80:80,87:87,88:88}],69:[function(e,t,n){"use strict";function r(e,t,n){return{type:d.INSERT_MARKUP,content:e,fromIndex:null,fromNode:null,toIndex:n,afterNode:t}}function o(e,t,n){return{type:d.MOVE_EXISTING,content:null,fromIndex:e._mountIndex,fromNode:f.getHostNode(e),toIndex:n,afterNode:t}}function a(e,t){return{type:d.REMOVE_NODE,content:null,fromIndex:e._mountIndex,fromNode:t,toIndex:null,afterNode:null}}function i(e){return{type:d.SET_MARKUP,content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function s(e){return{type:d.TEXT_CONTENT,content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function u(e,t){return t&&(e=e||[],e.push(t)),e}function l(e,t){p.processChildrenUpdates(e,t)}var c=e(132),p=e(33),d=(e(65),e(66),e(70)),f=(e(35),e(80)),h=e(28),m=(e(146),e(116)),v=(e(154),{Mixin:{_reconcilerInstantiateChildren:function(e,t,n){return h.instantiateChildren(e,t,n)},_reconcilerUpdateChildren:function(e,t,n,r,o,a){var i,s=0;return i=m(t,s),h.updateChildren(e,i,n,r,o,this,this._hostContainerInfo,a,s),i},mountChildren:function(e,t,n){var r=this._reconcilerInstantiateChildren(e,t,n);this._renderedChildren=r;var o=[],a=0;for(var i in r)if(r.hasOwnProperty(i)){var s=r[i],u=0,l=f.mountComponent(s,t,this,this._hostContainerInfo,n,u);s._mountIndex=a++,o.push(l)}return o},updateTextContent:function(e){var t=this._renderedChildren;h.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&c("118");var r=[s(e)];l(this,r)},updateMarkup:function(e){var t=this._renderedChildren;h.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&c("118");var r=[i(e)];l(this,r)},updateChildren:function(e,t,n){this._updateChildren(e,t,n)},_updateChildren:function(e,t,n){var r=this._renderedChildren,o={},a=[],i=this._reconcilerUpdateChildren(r,e,a,o,t,n);if(i||r){var s,c=null,p=0,d=0,h=0,m=null;for(s in i)if(i.hasOwnProperty(s)){var v=r&&r[s],g=i[s];v===g?(c=u(c,this.moveChild(v,m,p,d)),d=Math.max(v._mountIndex,d),v._mountIndex=p):(v&&(d=Math.max(v._mountIndex,d)),c=u(c,this._mountChildAtIndex(g,a[h],m,p,t,n)),h++),p++,m=f.getHostNode(g)}for(s in o)o.hasOwnProperty(s)&&(c=u(c,this._unmountChild(r[s],o[s])));c&&l(this,c),this._renderedChildren=i}},unmountChildren:function(e){var t=this._renderedChildren;h.unmountChildren(t,e),this._renderedChildren=null},moveChild:function(e,t,n,r){if(e._mountIndex>"),P={array:i("array"),bool:i("boolean"),func:i("function"),number:i("number"),object:i("object"),string:i("string"),symbol:i("symbol"),any:s(),arrayOf:u,element:l(),instanceOf:c,node:h(),objectOf:d,oneOf:p,oneOfType:f,shape:m};o.prototype=Error.prototype,t.exports=P},{123:123,146:146,161:161,56:56,74:74,77:77}],77:[function(e,t,n){"use strict";var r="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";t.exports=r},{}],78:[function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=u,this.updater=n||s}function o(){}var a=e(162),i=e(31),s=e(72),u=e(147);o.prototype=i.prototype,r.prototype=new o,r.prototype.constructor=r,a(r.prototype,i.prototype),r.prototype.isPureReactComponent=!0,t.exports=r},{147:147,162:162,31:31,72:72}],79:[function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=!1,this.reactMountReady=a.getPooled(null),this.useCreateElement=e}var o=e(162),a=e(5),i=e(25),s=e(27),u=e(64),l=(e(66),e(106)),c=e(87),p={initialize:u.getSelectionInformation,close:u.restoreSelection},d={initialize:function(){var e=s.isEnabled();return s.setEnabled(!1),e},close:function(e){s.setEnabled(e)}},f={initialize:function(){this.reactMountReady.reset()},close:function(){this.reactMountReady.notifyAll()}},h=[p,d,f],m={getTransactionWrappers:function(){return h},getReactMountReady:function(){return this.reactMountReady},getUpdateQueue:function(){return c},checkpoint:function(){return this.reactMountReady.checkpoint()},rollback:function(e){this.reactMountReady.rollback(e)},destructor:function(){a.release(this.reactMountReady),this.reactMountReady=null}};o(r.prototype,l.Mixin,m),i.addPoolingTo(r),t.exports=r},{106:106,162:162,25:25,27:27,5:5,64:64,66:66,87:87}],80:[function(e,t,n){"use strict";function r(){o.attachRefs(this,this._currentElement)}var o=e(81),a=(e(66),e(161),{mountComponent:function(e,t,n,o,a,i){var s=e.mountComponent(t,n,o,a,i);return e._currentElement&&null!=e._currentElement.ref&&t.getReactMountReady().enqueue(r,e),s},getHostNode:function(e){return e.getHostNode()},unmountComponent:function(e,t){o.detachRefs(e,e._currentElement),e.unmountComponent(t)},receiveComponent:function(e,t,n,a){var i=e._currentElement;if(t!==i||a!==e._context){var s=o.shouldUpdateRefs(i,t);s&&o.detachRefs(e,i),e.receiveComponent(t,n,a),s&&e._currentElement&&null!=e._currentElement.ref&&n.getReactMountReady().enqueue(r,e)}},performUpdateIfNecessary:function(e,t,n){e._updateBatchNumber===n&&e.performUpdateIfNecessary(t)}});t.exports=a},{161:161,66:66,81:81}],81:[function(e,t,n){"use strict";function r(e,t,n){"function"==typeof e?e(t.getPublicInstance()):a.addComponentAsRefTo(t,e,n)}function o(e,t,n){"function"==typeof e?e(null):a.removeComponentAsRefFrom(t,e,n)}var a=e(73),i={};i.attachRefs=function(e,t){if(null!==t&&t!==!1){var n=t.ref;null!=n&&r(n,e,t._owner)}},i.shouldUpdateRefs=function(e,t){var n=null===e||e===!1,r=null===t||t===!1;return n||r||t.ref!==e.ref||"string"==typeof t.ref&&t._owner!==e._owner},i.detachRefs=function(e,t){if(null!==t&&t!==!1){var n=t.ref;null!=n&&o(n,e,t._owner)}},t.exports=i},{73:73}],82:[function(e,t,n){"use strict";var r={isBatchingUpdates:!1,batchedUpdates:function(e){}};t.exports=r},{}],83:[function(e,t,n){"use strict";function r(e,t){var n;try{return h.injection.injectBatchingStrategy(d),n=f.getPooled(t),g++,n.perform(function(){var r=v(e,!0),o=p.mountComponent(r,n,null,s(),m,0);return t||(o=c.addChecksumToMarkup(o)),o},null)}finally{g--,f.release(n),g||h.injection.injectBatchingStrategy(u)}}function o(e){return l.isValidElement(e)?void 0:i("46"),r(e,!1)}function a(e){return l.isValidElement(e)?void 0:i("47"),r(e,!0)}var i=e(132),s=e(41),u=e(54),l=e(56),c=(e(66),e(67)),p=e(80),d=e(82),f=e(84),h=e(88),m=e(147),v=e(127),g=(e(154),0);t.exports={renderToString:o,renderToStaticMarkup:a}},{127:127,132:132,147:147,154:154,41:41,54:54,56:56,66:66,67:67,80:80,82:82,84:84,88:88}],84:[function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=e,this.useCreateElement=!1,this.updateQueue=new s(this)}var o=e(162),a=e(25),i=e(106),s=(e(66),e(85)),u=[],l={enqueue:function(){}},c={getTransactionWrappers:function(){return u},getReactMountReady:function(){return l},getUpdateQueue:function(){return this.updateQueue},destructor:function(){},checkpoint:function(){},rollback:function(){}};o(r.prototype,i.Mixin,c),a.addPoolingTo(r),t.exports=r},{106:106,162:162,25:25,66:66,85:85}],85:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){}var a=e(87),i=(e(106),e(161),function(){function e(t){r(this,e),this.transaction=t}return e.prototype.isMounted=function(e){return!1},e.prototype.enqueueCallback=function(e,t,n){this.transaction.isInTransaction()&&a.enqueueCallback(e,t,n)},e.prototype.enqueueForceUpdate=function(e){this.transaction.isInTransaction()?a.enqueueForceUpdate(e):o(e,"forceUpdate")},e.prototype.enqueueReplaceState=function(e,t){this.transaction.isInTransaction()?a.enqueueReplaceState(e,t):o(e,"replaceState")},e.prototype.enqueueSetState=function(e,t){this.transaction.isInTransaction()?a.enqueueSetState(e,t):o(e,"setState")},e}());t.exports=i},{106:106,161:161,87:87}],86:[function(e,t,n){"use strict";var r=e(162),o=e(36),a=e(50),i=e(26),s=r({__SECRET_DOM_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:o,__SECRET_DOM_SERVER_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:a},i);t.exports=s},{162:162,26:26,36:36,50:50}],87:[function(e,t,n){"use strict";function r(e){u.enqueueUpdate(e)}function o(e){var t=typeof e;if("object"!==t)return t;var n=e.constructor&&e.constructor.name||t,r=Object.keys(e);return r.length>0&&r.length<20?n+" (keys: "+r.join(", ")+")":n}function a(e,t){var n=s.get(e);return n?n:null}var i=e(132),s=(e(35),e(65)),u=(e(66),e(88)),l=(e(154),e(161),{isMounted:function(e){var t=s.get(e);return!!t&&!!t._renderedComponent},enqueueCallback:function(e,t,n){l.validateCallback(t,n);var o=a(e);return o?(o._pendingCallbacks?o._pendingCallbacks.push(t):o._pendingCallbacks=[t],void r(o)):null},enqueueCallbackInternal:function(e,t){e._pendingCallbacks?e._pendingCallbacks.push(t):e._pendingCallbacks=[t],r(e)},enqueueForceUpdate:function(e){var t=a(e,"forceUpdate");t&&(t._pendingForceUpdate=!0,r(t))},enqueueReplaceState:function(e,t){var n=a(e,"replaceState");n&&(n._pendingStateQueue=[t],n._pendingReplaceState=!0,r(n))},enqueueSetState:function(e,t){var n=a(e,"setState");if(n){var o=n._pendingStateQueue||(n._pendingStateQueue=[]);o.push(t),r(n)}},enqueueElementInternal:function(e,t,n){e._pendingElement=t,e._context=n,r(e)},validateCallback:function(e,t){e&&"function"!=typeof e?i("122",t,o(e)):void 0}});t.exports=l},{132:132,154:154,161:161,35:35,65:65,66:66,88:88}],88:[function(e,t,n){"use strict";function r(){P.ReactReconcileTransaction&&_?void 0:c("123")}function o(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=d.getPooled(),this.reconcileTransaction=P.ReactReconcileTransaction.getPooled(!0)}function a(e,t,n,o,a,i){r(),_.batchedUpdates(e,t,n,o,a,i)}function i(e,t){return e._mountOrder-t._mountOrder}function s(e){var t=e.dirtyComponentsLength;t!==g.length?c("124",t,g.length):void 0,g.sort(i),y++;for(var n=0;n]/;t.exports=o},{}],115:[function(e,t,n){"use strict";function r(e){if(null==e)return null;if(1===e.nodeType)return e;var t=i.get(e);return t?(t=s(t),t?a.getNodeFromInstance(t):null):void("function"==typeof e.render?o("44"):o("45",Object.keys(e)))}var o=e(132),a=(e(35),e(40)),i=e(65),s=e(122);e(154),e(161);t.exports=r},{122:122,132:132,154:154,161:161,35:35,40:40,65:65}],116:[function(e,t,n){(function(n){"use strict";function r(e,t,n,r){if(e&&"object"==typeof e){var o=e,a=void 0===o[n];a&&null!=t&&(o[n]=t)}}function o(e,t){if(null==e)return e;var n={};return a(e,r,n),n}var a=(e(23),e(137));e(161);"undefined"!=typeof n&&n.env,t.exports=o}).call(this,void 0)},{137:137,161:161,23:23}],117:[function(e,t,n){"use strict";function r(e,t,n){Array.isArray(e)?e.forEach(t,n):e&&t.call(n,e)}t.exports=r},{}],118:[function(e,t,n){"use strict";function r(e){var t,n=e.keyCode;return"charCode"in e?(t=e.charCode,0===t&&13===n&&(t=13)):t=n,t>=32||13===t?t:0}t.exports=r},{}],119:[function(e,t,n){"use strict";function r(e){if(e.key){var t=a[e.key]||e.key;if("Unidentified"!==t)return t}if("keypress"===e.type){var n=o(e);return 13===n?"Enter":String.fromCharCode(n)}return"keydown"===e.type||"keyup"===e.type?i[e.keyCode]||"Unidentified":""}var o=e(118),a={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},i={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"};t.exports=r},{118:118}],120:[function(e,t,n){"use strict";function r(e){var t=this,n=t.nativeEvent;if(n.getModifierState)return n.getModifierState(e);var r=a[e];return!!r&&!!n[r]}function o(e){return r}var a={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};t.exports=o},{}],121:[function(e,t,n){"use strict";function r(e){var t=e.target||e.srcElement||window;return t.correspondingUseElement&&(t=t.correspondingUseElement),3===t.nodeType?t.parentNode:t}t.exports=r},{}],122:[function(e,t,n){"use strict";function r(e){for(var t;(t=e._renderedNodeType)===o.COMPOSITE;)e=e._renderedComponent;return t===o.HOST?e._renderedComponent:t===o.EMPTY?null:void 0}var o=e(71);t.exports=r},{71:71}],123:[function(e,t,n){"use strict";function r(e){var t=e&&(o&&e[o]||e[a]);if("function"==typeof t)return t}var o="function"==typeof Symbol&&Symbol.iterator,a="@@iterator";t.exports=r},{}],124:[function(e,t,n){"use strict";function r(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function o(e){for(;e;){if(e.nextSibling)return e.nextSibling;e=e.parentNode}}function a(e,t){for(var n=r(e),a=0,i=0;n;){if(3===n.nodeType){if(i=a+n.textContent.length,a<=t&&i>=t)return{node:n,offset:t-a};a=i}n=r(o(n))}}t.exports=a},{}],125:[function(e,t,n){"use strict";function r(){return!a&&o.canUseDOM&&(a="textContent"in document.documentElement?"textContent":"innerText"),a}var o=e(140),a=null;t.exports=r},{140:140}],126:[function(e,t,n){"use strict";function r(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n["ms"+e]="MS"+t,n["O"+e]="o"+t.toLowerCase(),n}function o(e){if(s[e])return s[e];if(!i[e])return e;var t=i[e];for(var n in t)if(t.hasOwnProperty(n)&&n in u)return s[e]=t[n];return""}var a=e(140),i={animationend:r("Animation","AnimationEnd"),animationiteration:r("Animation","AnimationIteration"),animationstart:r("Animation","AnimationStart"),transitionend:r("Transition","TransitionEnd")},s={},u={};a.canUseDOM&&(u=document.createElement("div").style,"AnimationEvent"in window||(delete i.animationend.animation,delete i.animationiteration.animation,delete i.animationstart.animation),"TransitionEvent"in window||delete i.transitionend.transition),t.exports=o},{140:140}],127:[function(e,t,n){"use strict";function r(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}function o(e){return"function"==typeof e&&"undefined"!=typeof e.prototype&&"function"==typeof e.prototype.mountComponent&&"function"==typeof e.prototype.receiveComponent}function a(e,t){var n;if(null===e||e===!1)n=l.create(a);else if("object"==typeof e){var s=e;!s||"function"!=typeof s.type&&"string"!=typeof s.type?i("130",null==s.type?s.type:typeof s.type,r(s._owner)):void 0,"string"==typeof s.type?n=c.createInternalComponent(s):o(s.type)?(n=new s.type(s),n.getHostNode||(n.getHostNode=n.getNativeNode)):n=new p(s)}else"string"==typeof e||"number"==typeof e?n=c.createInstanceForText(e):i("131",typeof e);return n._mountIndex=0,n._mountImage=null,n}var i=e(132),s=e(162),u=e(34),l=e(57),c=e(62),p=(e(154),e(161),function(e){this.construct(e)});s(p.prototype,u.Mixin,{_instantiateReactComponent:a});t.exports=a},{132:132,154:154,161:161,162:162,34:34,57:57,62:62}],128:[function(e,t,n){"use strict";function r(e,t){if(!a.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,r=n in document;if(!r){var i=document.createElement("div");i.setAttribute(n,"return;"),r="function"==typeof i[n]}return!r&&o&&"wheel"===e&&(r=document.implementation.hasFeature("Events.wheel","3.0")),r}var o,a=e(140);a.canUseDOM&&(o=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),t.exports=r},{140:140}],129:[function(e,t,n){"use strict";function r(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!o[e.type]:"textarea"===t}var o={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};t.exports=r},{}],130:[function(e,t,n){"use strict";function r(e){return a.isValidElement(e)?void 0:o("143"),e}var o=e(132),a=e(56);e(154);t.exports=r},{132:132,154:154,56:56}],131:[function(e,t,n){"use strict";function r(e){return'"'+o(e)+'"'}var o=e(114);t.exports=r},{114:114}],132:[function(e,t,n){"use strict";function r(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r]/,u=e(112),l=u(function(e,t){if(e.namespaceURI!==a.svg||"innerHTML"in e)e.innerHTML=t;else{r=r||document.createElement("div"),r.innerHTML=""+t+"";for(var n=r.firstChild.childNodes,o=0;o":i.innerHTML="<"+e+">",s[e]=!i.firstChild),s[e]?d[e]:null}var o=e(140),a=e(154),i=o.canUseDOM?document.createElement("div"):null,s={},u=[1,'"],l=[1,"","
"],c=[3,"","
"],p=[1,'',""],d={"*":[1,"?
","
"],area:[1,"",""],col:[2,"","
"],legend:[1,"
","
"],param:[1,"",""],tr:[2,"","
"],optgroup:u,option:u,caption:l,colgroup:l,tbody:l,tfoot:l,thead:l,td:c,th:c},f=["circle","clipPath","defs","ellipse","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","text","tspan"];f.forEach(function(e){d[e]=p,s[e]=!0}),t.exports=r},{140:140,154:154}],151:[function(e,t,n){"use strict";function r(e){return e===window?{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}:{x:e.scrollLeft,y:e.scrollTop}}t.exports=r},{}],152:[function(e,t,n){"use strict";function r(e){return e.replace(o,"-$1").toLowerCase()}var o=/([A-Z])/g;t.exports=r},{}],153:[function(e,t,n){"use strict";function r(e){return o(e).replace(a,"-ms-")}var o=e(152),a=/^ms-/;t.exports=r},{152:152}],154:[function(e,t,n){"use strict";function r(e,t,n,r,o,a,i,s){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,a,i,s],c=0;u=new Error(t.replace(/%s/g,function(){return l[c++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}}t.exports=r},{}],155:[function(e,t,n){"use strict";function r(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}t.exports=r},{}],156:[function(e,t,n){"use strict";function r(e){return o(e)&&3==e.nodeType}var o=e(155);t.exports=r},{155:155}],157:[function(e,t,n){"use strict";var r=e(154),o=function(e){var t,n={};e instanceof Object&&!Array.isArray(e)?void 0:r(!1);for(t in e)e.hasOwnProperty(t)&&(n[t]=t);return n};t.exports=o},{154:154}],158:[function(e,t,n){"use strict";var r=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};t.exports=r},{}],159:[function(e,t,n){"use strict";function r(e){var t={};return function(n){return t.hasOwnProperty(n)||(t[n]=e.call(this,n)),t[n]}}t.exports=r},{}],160:[function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function o(e,t){if(r(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var i=0;i>> 0), ha = 0; +function ia(a, b, c) { + return a.call.apply(a.bind, arguments); +} +function ja(a, b, c) { + if (!a) { + throw Error(); + } + if (2 < arguments.length) { + var d = Array.prototype.slice.call(arguments, 2); + return function() { + var c = Array.prototype.slice.call(arguments); + Array.prototype.unshift.apply(c, d); + return a.apply(b, c); + }; + } + return function() { + return a.apply(b, arguments); + }; +} +function ka(a, b, c) { + ka = Function.prototype.bind && -1 != Function.prototype.bind.toString().indexOf("native code") ? ia : ja; + return ka.apply(null, arguments); +} +function la(a, b) { + var c = Array.prototype.slice.call(arguments, 1); + return function() { + var b = c.slice(); + b.push.apply(b, arguments); + return a.apply(this, b); + }; +} +var ma = Date.now || function() { + return +new Date; +}; +function na(a, b) { + function c() { + } + c.prototype = b.prototype; + a.Mb = b.prototype; + a.prototype = new c; + a.prototype.constructor = a; + a.base = function(a, c, f) { + for (var h = Array(arguments.length - 2), k = 2;k < arguments.length;k++) { + h[k - 2] = arguments[k]; + } + return b.prototype[c].apply(a, h); + }; +} +;function oa(a) { + return /^[\s\xa0]*$/.test(a); +} +var qa = String.prototype.trim ? function(a) { + return a.trim(); +} : function(a) { + return a.replace(/^[\s\xa0]+|[\s\xa0]+$/g, ""); +}; +function ra(a) { + if (!sa.test(a)) { + return a; + } + -1 != a.indexOf("\x26") && (a = a.replace(ta, "\x26amp;")); + -1 != a.indexOf("\x3c") && (a = a.replace(ua, "\x26lt;")); + -1 != a.indexOf("\x3e") && (a = a.replace(va, "\x26gt;")); + -1 != a.indexOf('"') && (a = a.replace(wa, "\x26quot;")); + -1 != a.indexOf("'") && (a = a.replace(xa, "\x26#39;")); + -1 != a.indexOf("\x00") && (a = a.replace(ya, "\x26#0;")); + return a; +} +var ta = /&/g, ua = //g, wa = /"/g, xa = /'/g, ya = /\x00/g, sa = /[\x00&<>"']/; +function za(a) { + return null == a ? "" : String(a); +} +function Aa(a, b) { + return a < b ? -1 : a > b ? 1 : 0; +} +;function Ba(a, b, c) { + for (var d in a) { + b.call(c, a[d], d, a); + } +} +function Ca(a, b) { + for (var c in a) { + if (b.call(void 0, a[c], c, a)) { + return !0; + } + } + return !1; +} +function Da(a, b) { + return null !== a && b in a ? a[b] : void 0; +} +var Ea = "constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" "); +function Fa(a, b) { + for (var c, d, e = 1;e < arguments.length;e++) { + d = arguments[e]; + for (c in d) { + a[c] = d[c]; + } + for (var f = 0;f < Ea.length;f++) { + c = Ea[f], Object.prototype.hasOwnProperty.call(d, c) && (a[c] = d[c]); + } + } +} +;function Ha(a, b) { + this.da = []; + this.zb = b; + for (var c = !0, d = a.length - 1;0 <= d;d--) { + var e = a[d] | 0; + c && e == b || (this.da[d] = e, c = !1); + } +} +var Ia = {}; +function Ja(a) { + if (-128 <= a && 128 > a) { + var b = Ia[a]; + if (b) { + return b; + } + } + b = new Ha([a | 0], 0 > a ? -1 : 0); + -128 <= a && 128 > a && (Ia[a] = b); + return b; +} +function La(a) { + if (isNaN(a) || !isFinite(a)) { + return Ma; + } + if (0 > a) { + return La(-a).qa(); + } + for (var b = [], c = 1, d = 0;a >= c;d++) { + b[d] = a / c | 0, c *= Na; + } + return new Ha(b, 0); +} +var Na = 4294967296, Ma = Ja(0), Oa = Ja(1), Pa = Ja(16777216); +g = Ha.prototype; +g.sf = function() { + return 0 < this.da.length ? this.da[0] : this.zb; +}; +g.hc = function() { + if (this.Ba()) { + return -this.qa().hc(); + } + for (var a = 0, b = 1, c = 0;c < this.da.length;c++) { + var d = Ra(this, c), a = a + (0 <= d ? d : Na + d) * b, b = b * Na + } + return a; +}; +g.toString = function(a) { + a = a || 10; + if (2 > a || 36 < a) { + throw Error("radix out of range: " + a); + } + if (this.eb()) { + return "0"; + } + if (this.Ba()) { + return "-" + this.qa().toString(a); + } + for (var b = La(Math.pow(a, 6)), c = this, d = "";;) { + var e = Sa(c, b), f = (c.bd(e.multiply(b)).sf() >>> 0).toString(a), c = e; + if (c.eb()) { + return f + d; + } + for (;6 > f.length;) { + f = "0" + f; + } + d = "" + f + d; + } +}; +function Ra(a, b) { + return 0 > b ? 0 : b < a.da.length ? a.da[b] : a.zb; +} +g.eb = function() { + if (0 != this.zb) { + return !1; + } + for (var a = 0;a < this.da.length;a++) { + if (0 != this.da[a]) { + return !1; + } + } + return !0; +}; +g.Ba = function() { + return -1 == this.zb; +}; +g.Fe = function(a) { + return 0 < this.compare(a); +}; +g.Ge = function(a) { + return 0 <= this.compare(a); +}; +g.zd = function() { + return 0 > this.compare(Pa); +}; +g.Ad = function(a) { + return 0 >= this.compare(a); +}; +g.compare = function(a) { + a = this.bd(a); + return a.Ba() ? -1 : a.eb() ? 0 : 1; +}; +g.qa = function() { + return this.Qe().add(Oa); +}; +g.add = function(a) { + for (var b = Math.max(this.da.length, a.da.length), c = [], d = 0, e = 0;e <= b;e++) { + var f = d + (Ra(this, e) & 65535) + (Ra(a, e) & 65535), h = (f >>> 16) + (Ra(this, e) >>> 16) + (Ra(a, e) >>> 16), d = h >>> 16, f = f & 65535, h = h & 65535; + c[e] = h << 16 | f; + } + return new Ha(c, c[c.length - 1] & -2147483648 ? -1 : 0); +}; +g.bd = function(a) { + return this.add(a.qa()); +}; +g.multiply = function(a) { + if (this.eb() || a.eb()) { + return Ma; + } + if (this.Ba()) { + return a.Ba() ? this.qa().multiply(a.qa()) : this.qa().multiply(a).qa(); + } + if (a.Ba()) { + return this.multiply(a.qa()).qa(); + } + if (this.zd() && a.zd()) { + return La(this.hc() * a.hc()); + } + for (var b = this.da.length + a.da.length, c = [], d = 0;d < 2 * b;d++) { + c[d] = 0; + } + for (d = 0;d < this.da.length;d++) { + for (var e = 0;e < a.da.length;e++) { + var f = Ra(this, d) >>> 16, h = Ra(this, d) & 65535, k = Ra(a, e) >>> 16, l = Ra(a, e) & 65535; + c[2 * d + 2 * e] += h * l; + Ta(c, 2 * d + 2 * e); + c[2 * d + 2 * e + 1] += f * l; + Ta(c, 2 * d + 2 * e + 1); + c[2 * d + 2 * e + 1] += h * k; + Ta(c, 2 * d + 2 * e + 1); + c[2 * d + 2 * e + 2] += f * k; + Ta(c, 2 * d + 2 * e + 2); + } + } + for (d = 0;d < b;d++) { + c[d] = c[2 * d + 1] << 16 | c[2 * d]; + } + for (d = b;d < 2 * b;d++) { + c[d] = 0; + } + return new Ha(c, 0); +}; +function Ta(a, b) { + for (;(a[b] & 65535) != a[b];) { + a[b + 1] += a[b] >>> 16, a[b] &= 65535; + } +} +function Sa(a, b) { + if (b.eb()) { + throw Error("division by zero"); + } + if (a.eb()) { + return Ma; + } + if (a.Ba()) { + return b.Ba() ? Sa(a.qa(), b.qa()) : Sa(a.qa(), b).qa(); + } + if (b.Ba()) { + return Sa(a, b.qa()).qa(); + } + if (30 < a.da.length) { + if (a.Ba() || b.Ba()) { + throw Error("slowDivide_ only works with positive integers."); + } + for (var c = Oa, d = b;d.Ad(a);) { + c = c.shiftLeft(1), d = d.shiftLeft(1); + } + for (var e = c.Lb(1), f = d.Lb(1), h, d = d.Lb(2), c = c.Lb(2);!d.eb();) { + h = f.add(d), h.Ad(a) && (e = e.add(c), f = h), d = d.Lb(1), c = c.Lb(1); + } + return e; + } + c = Ma; + for (d = a;d.Ge(b);) { + e = Math.max(1, Math.floor(d.hc() / b.hc())); + f = Math.ceil(Math.log(e) / Math.LN2); + f = 48 >= f ? 1 : Math.pow(2, f - 48); + h = La(e); + for (var k = h.multiply(b);k.Ba() || k.Fe(d);) { + e -= f, h = La(e), k = h.multiply(b); + } + h.eb() && (h = Oa); + c = c.add(h); + d = d.bd(k); + } + return c; +} +g.Qe = function() { + for (var a = this.da.length, b = [], c = 0;c < a;c++) { + b[c] = ~this.da[c]; + } + return new Ha(b, ~this.zb); +}; +g.shiftLeft = function(a) { + var b = a >> 5; + a %= 32; + for (var c = this.da.length + b + (0 < a ? 1 : 0), d = [], e = 0;e < c;e++) { + d[e] = 0 < a ? Ra(this, e - b) << a | Ra(this, e - b - 1) >>> 32 - a : Ra(this, e - b); + } + return new Ha(d, this.zb); +}; +g.Lb = function(a) { + var b = a >> 5; + a %= 32; + for (var c = this.da.length - b, d = [], e = 0;e < c;e++) { + d[e] = 0 < a ? Ra(this, e + b) >>> a | Ra(this, e + b + 1) << 32 - a : Ra(this, e + b); + } + return new Ha(d, this.zb); +}; +function Ua(a, b) { + null != a && this.append.apply(this, arguments); +} +g = Ua.prototype; +g.hb = ""; +g.set = function(a) { + this.hb = "" + a; +}; +g.append = function(a, b, c) { + this.hb += String(a); + if (null != b) { + for (var d = 1;d < arguments.length;d++) { + this.hb += arguments[d]; + } + } + return this; +}; +g.clear = function() { + this.hb = ""; +}; +g.toString = function() { + return this.hb; +}; +var Va = Array.prototype.indexOf ? function(a, b, c) { + return Array.prototype.indexOf.call(a, b, c); +} : function(a, b, c) { + c = null == c ? 0 : 0 > c ? Math.max(0, a.length + c) : c; + if (ca(a)) { + return ca(b) && 1 == b.length ? a.indexOf(b, c) : -1; + } + for (;c < a.length;c++) { + if (c in a && a[c] === b) { + return c; + } + } + return -1; +}, Wa = Array.prototype.forEach ? function(a, b, c) { + Array.prototype.forEach.call(a, b, c); +} : function(a, b, c) { + for (var d = a.length, e = ca(a) ? a.split("") : a, f = 0;f < d;f++) { + f in e && b.call(c, e[f], f, a); + } +}; +function Ya(a) { + Ya[" "](a); + return a; +} +Ya[" "] = function() { +}; +var Za = {}, $a; +if ("undefined" === typeof ab) { + var ab = function() { + throw Error("No *print-fn* fn set for evaluation environment"); + } +} +if ("undefined" === typeof db) { + var db = function() { + throw Error("No *print-err-fn* fn set for evaluation environment"); + } +} +var eb = null; +if ("undefined" === typeof gb) { + var gb = null +} +function hb() { + return new ib(null, 5, [jb, !0, kb, !0, lb, !1, mb, !1, nb, null], null); +} +function q(a) { + return null != a && !1 !== a; +} +function ob(a) { + return null == a; +} +function pb(a) { + return a instanceof Array; +} +function qb(a) { + return null == a ? !0 : !1 === a ? !0 : !1; +} +function t(a, b) { + return a[n(null == b ? null : b)] ? !0 : a._ ? !0 : !1; +} +function v(a, b) { + var c = null == b ? null : b.constructor, c = q(q(c) ? c.qb : c) ? c.Za : n(b); + return Error(["No protocol method ", a, " defined for type ", c, ": ", b].join("")); +} +function tb(a) { + var b = a.Za; + return q(b) ? b : "" + w(a); +} +var ub = "undefined" !== typeof Symbol && "function" === n(Symbol) ? Symbol.iterator : "@@iterator"; +function vb(a) { + for (var b = a.length, c = Array(b), d = 0;;) { + if (d < b) { + c[d] = a[d], d += 1; + } else { + break; + } + } + return c; +} +function wb(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return xb(arguments[0]); + case 2: + return xb(arguments[1]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function yb(a) { + return xb(a); +} +function xb(a) { + function b(a, b) { + a.push(b); + return a; + } + var c = []; + return zb ? zb(b, c, a) : Ab.call(null, b, c, a); +} +function Bb() { +} +function Cb() { +} +function Db() { +} +var Eb = function Eb(b) { + if (null != b && null != b.ra) { + return b.ra(b); + } + var c = Eb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Eb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ICloneable.-clone", b); +}; +function Fb() { +} +var Gb = function Gb(b) { + if (null != b && null != b.Y) { + return b.Y(b); + } + var c = Gb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Gb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ICounted.-count", b); +}, Hb = function Hb(b) { + if (null != b && null != b.Z) { + return b.Z(b); + } + var c = Hb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Hb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IEmptyableCollection.-empty", b); +}; +function Ib() { +} +var Lb = function Lb(b, c) { + if (null != b && null != b.W) { + return b.W(b, c); + } + var d = Lb[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Lb._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("ICollection.-conj", b); +}; +function Mb() { +} +var y = function y(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return y.f(arguments[0], arguments[1]); + case 3: + return y.h(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +y.f = function(a, b) { + if (null != a && null != a.K) { + return a.K(a, b); + } + var c = y[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = y._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("IIndexed.-nth", a); +}; +y.h = function(a, b, c) { + if (null != a && null != a.sa) { + return a.sa(a, b, c); + } + var d = y[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = y._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("IIndexed.-nth", a); +}; +y.F = 3; +function Nb() { +} +var Ob = function Ob(b) { + if (null != b && null != b.ba) { + return b.ba(b); + } + var c = Ob[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Ob._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ISeq.-first", b); +}, Pb = function Pb(b) { + if (null != b && null != b.ia) { + return b.ia(b); + } + var c = Pb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Pb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ISeq.-rest", b); +}; +function Qb() { +} +function Rb() { +} +var Sb = function Sb(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return Sb.f(arguments[0], arguments[1]); + case 3: + return Sb.h(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Sb.f = function(a, b) { + if (null != a && null != a.O) { + return a.O(a, b); + } + var c = Sb[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = Sb._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("ILookup.-lookup", a); +}; +Sb.h = function(a, b, c) { + if (null != a && null != a.J) { + return a.J(a, b, c); + } + var d = Sb[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = Sb._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("ILookup.-lookup", a); +}; +Sb.F = 3; +var Tb = function Tb(b, c) { + if (null != b && null != b.Rb) { + return b.Rb(b, c); + } + var d = Tb[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Tb._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IAssociative.-contains-key?", b); +}, Ub = function Ub(b, c, d) { + if (null != b && null != b.nb) { + return b.nb(b, c, d); + } + var e = Ub[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Ub._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IAssociative.-assoc", b); +}; +function Vb() { +} +var Wb = function Wb(b, c) { + if (null != b && null != b.mc) { + return b.mc(b, c); + } + var d = Wb[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Wb._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IMap.-dissoc", b); +}; +function Xb() { +} +var Yb = function Yb(b) { + if (null != b && null != b.Gc) { + return b.Gc(); + } + var c = Yb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Yb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IMapEntry.-key", b); +}, Zb = function Zb(b) { + if (null != b && null != b.Hc) { + return b.Hc(); + } + var c = Zb[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Zb._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IMapEntry.-val", b); +}; +function ac() { +} +var bc = function bc(b, c) { + if (null != b && null != b.jd) { + return b.jd(0, c); + } + var d = bc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = bc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("ISet.-disjoin", b); +}, cc = function cc(b) { + if (null != b && null != b.ob) { + return b.ob(b); + } + var c = cc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = cc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IStack.-peek", b); +}, dc = function dc(b) { + if (null != b && null != b.pb) { + return b.pb(b); + } + var c = dc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = dc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IStack.-pop", b); +}; +function ec() { +} +var fc = function fc(b, c, d) { + if (null != b && null != b.Ic) { + return b.Ic(b, c, d); + } + var e = fc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = fc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IVector.-assoc-n", b); +}, gc = function gc(b) { + if (null != b && null != b.Cb) { + return b.Cb(b); + } + var c = gc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = gc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IDeref.-deref", b); +}; +function hc() { +} +var ic = function ic(b) { + if (null != b && null != b.M) { + return b.M(b); + } + var c = ic[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = ic._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IMeta.-meta", b); +}; +function jc() { +} +var kc = function kc(b, c) { + if (null != b && null != b.P) { + return b.P(b, c); + } + var d = kc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = kc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IWithMeta.-with-meta", b); +}; +function lc() { +} +var mc = function mc(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return mc.f(arguments[0], arguments[1]); + case 3: + return mc.h(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +mc.f = function(a, b) { + if (null != a && null != a.fa) { + return a.fa(a, b); + } + var c = mc[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = mc._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("IReduce.-reduce", a); +}; +mc.h = function(a, b, c) { + if (null != a && null != a.ga) { + return a.ga(a, b, c); + } + var d = mc[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = mc._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("IReduce.-reduce", a); +}; +mc.F = 3; +var nc = function nc(b, c) { + if (null != b && null != b.B) { + return b.B(b, c); + } + var d = nc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = nc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IEquiv.-equiv", b); +}, oc = function oc(b) { + if (null != b && null != b.U) { + return b.U(b); + } + var c = oc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = oc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IHash.-hash", b); +}; +function pc() { +} +var qc = function qc(b) { + if (null != b && null != b.X) { + return b.X(b); + } + var c = qc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = qc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ISeqable.-seq", b); +}; +function rc() { +} +function sc() { +} +var tc = function tc(b, c) { + if (null != b && null != b.od) { + return b.od(0, c); + } + var d = tc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = tc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IWriter.-write", b); +}, uc = function uc(b, c, d) { + if (null != b && null != b.S) { + return b.S(b, c, d); + } + var e = uc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = uc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IPrintWithWriter.-pr-writer", b); +}, vc = function vc(b, c, d) { + if (null != b && null != b.md) { + return b.md(0, c, d); + } + var e = vc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = vc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IWatchable.-notify-watches", b); +}, xc = function xc(b, c, d) { + if (null != b && null != b.ld) { + return b.ld(0, c, d); + } + var e = xc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = xc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IWatchable.-add-watch", b); +}, yc = function yc(b, c) { + if (null != b && null != b.nd) { + return b.nd(0, c); + } + var d = yc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = yc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IWatchable.-remove-watch", b); +}, zc = function zc(b) { + if (null != b && null != b.Db) { + return b.Db(b); + } + var c = zc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = zc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IEditableCollection.-as-transient", b); +}, Ac = function Ac(b, c) { + if (null != b && null != b.Tb) { + return b.Tb(b, c); + } + var d = Ac[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Ac._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("ITransientCollection.-conj!", b); +}, Bc = function Bc(b) { + if (null != b && null != b.Ub) { + return b.Ub(b); + } + var c = Bc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Bc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ITransientCollection.-persistent!", b); +}, Cc = function Cc(b, c, d) { + if (null != b && null != b.Sb) { + return b.Sb(b, c, d); + } + var e = Cc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Cc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("ITransientAssociative.-assoc!", b); +}, Dc = function Dc(b, c, d) { + if (null != b && null != b.kd) { + return b.kd(0, c, d); + } + var e = Dc[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Dc._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("ITransientVector.-assoc-n!", b); +}, Ec = function Ec(b) { + if (null != b && null != b.gd) { + return b.gd(); + } + var c = Ec[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Ec._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IChunk.-drop-first", b); +}, Fc = function Fc(b) { + if (null != b && null != b.Ec) { + return b.Ec(b); + } + var c = Fc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Fc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IChunkedSeq.-chunked-first", b); +}, Gc = function Gc(b) { + if (null != b && null != b.Fc) { + return b.Fc(b); + } + var c = Gc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Gc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IChunkedSeq.-chunked-rest", b); +}, Hc = function Hc(b) { + if (null != b && null != b.Dc) { + return b.Dc(b); + } + var c = Hc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Hc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IChunkedNext.-chunked-next", b); +}; +function Ic() { +} +var Jc = function Jc(b, c) { + if (null != b && null != b.xe) { + return b.xe(b, c); + } + var d = Jc[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Jc._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IReset.-reset!", b); +}, Kc = function Kc(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return Kc.f(arguments[0], arguments[1]); + case 3: + return Kc.h(arguments[0], arguments[1], arguments[2]); + case 4: + return Kc.w(arguments[0], arguments[1], arguments[2], arguments[3]); + case 5: + return Kc.N(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Kc.f = function(a, b) { + if (null != a && null != a.ze) { + return a.ze(a, b); + } + var c = Kc[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = Kc._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("ISwap.-swap!", a); +}; +Kc.h = function(a, b, c) { + if (null != a && null != a.Ae) { + return a.Ae(a, b, c); + } + var d = Kc[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = Kc._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("ISwap.-swap!", a); +}; +Kc.w = function(a, b, c, d) { + if (null != a && null != a.Be) { + return a.Be(a, b, c, d); + } + var e = Kc[n(null == a ? null : a)]; + if (null != e) { + return e.w ? e.w(a, b, c, d) : e.call(null, a, b, c, d); + } + e = Kc._; + if (null != e) { + return e.w ? e.w(a, b, c, d) : e.call(null, a, b, c, d); + } + throw v("ISwap.-swap!", a); +}; +Kc.N = function(a, b, c, d, e) { + if (null != a && null != a.Ce) { + return a.Ce(a, b, c, d, e); + } + var f = Kc[n(null == a ? null : a)]; + if (null != f) { + return f.N ? f.N(a, b, c, d, e) : f.call(null, a, b, c, d, e); + } + f = Kc._; + if (null != f) { + return f.N ? f.N(a, b, c, d, e) : f.call(null, a, b, c, d, e); + } + throw v("ISwap.-swap!", a); +}; +Kc.F = 5; +var Lc = function Lc(b) { + if (null != b && null != b.Da) { + return b.Da(b); + } + var c = Lc[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Lc._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IIterable.-iterator", b); +}; +function Mc(a) { + this.qf = a; + this.m = 1073741824; + this.C = 0; +} +Mc.prototype.od = function(a, b) { + return this.qf.append(b); +}; +function Nc(a) { + var b = new Ua; + a.S(null, new Mc(b), hb()); + return "" + w(b); +} +var Oc = "undefined" !== typeof Math.imul && 0 !== Math.imul(4294967295, 5) ? function(a, b) { + return Math.imul(a, b); +} : function(a, b) { + var c = a & 65535, d = b & 65535; + return c * d + ((a >>> 16 & 65535) * d + c * (b >>> 16 & 65535) << 16 >>> 0) | 0; +}; +function Pc(a) { + a = Oc(a | 0, -862048943); + return Oc(a << 15 | a >>> -15, 461845907); +} +function Qc(a, b) { + var c = (a | 0) ^ (b | 0); + return Oc(c << 13 | c >>> -13, 5) + -430675100 | 0; +} +function Rc(a, b) { + var c = (a | 0) ^ b, c = Oc(c ^ c >>> 16, -2048144789), c = Oc(c ^ c >>> 13, -1028477387); + return c ^ c >>> 16; +} +function Sc(a) { + var b; + a: { + b = 1; + for (var c = 0;;) { + if (b < a.length) { + var d = b + 2, c = Qc(c, Pc(a.charCodeAt(b - 1) | a.charCodeAt(b) << 16)); + b = d; + } else { + b = c; + break a; + } + } + } + b = 1 === (a.length & 1) ? b ^ Pc(a.charCodeAt(a.length - 1)) : b; + return Rc(b, Oc(2, a.length)); +} +var Tc = {}, Uc = 0; +function Vc(a) { + 255 < Uc && (Tc = {}, Uc = 0); + if (null == a) { + return 0; + } + var b = Tc[a]; + if ("number" !== typeof b) { + a: { + if (null != a) { + if (b = a.length, 0 < b) { + for (var c = 0, d = 0;;) { + if (c < b) { + var e = c + 1, d = Oc(31, d) + a.charCodeAt(c), c = e + } else { + b = d; + break a; + } + } + } else { + b = 0; + } + } else { + b = 0; + } + } + Tc[a] = b; + Uc += 1; + } + return a = b; +} +function Wc(a) { + if (null != a && (a.m & 4194304 || a.Cf)) { + return a.U(null); + } + if ("number" === typeof a) { + if (q(isFinite(a))) { + return Math.floor(a) % 2147483647; + } + switch(a) { + case Infinity: + return 2146435072; + case -Infinity: + return -1048576; + default: + return 2146959360; + } + } else { + return !0 === a ? a = 1 : !1 === a ? a = 0 : "string" === typeof a ? (a = Vc(a), 0 !== a && (a = Pc(a), a = Qc(0, a), a = Rc(a, 4))) : a = a instanceof Date ? a.valueOf() : null == a ? 0 : oc(a), a; + } +} +function Xc(a, b) { + return a ^ b + 2654435769 + (a << 6) + (a >> 2); +} +function Yc(a, b, c, d, e) { + this.fc = a; + this.name = b; + this.mb = c; + this.Bb = d; + this.la = e; + this.m = 2154168321; + this.C = 4096; +} +g = Yc.prototype; +g.toString = function() { + return this.mb; +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.B = function(a, b) { + return b instanceof Yc ? this.mb === b.mb : !1; +}; +g.call = function() { + function a(a, b, c) { + return z.h ? z.h(b, this, c) : z.call(null, b, this, c); + } + function b(a, b) { + return z.f ? z.f(b, this) : z.call(null, b, this); + } + var c = null, c = function(c, e, f) { + switch(arguments.length) { + case 2: + return b.call(this, 0, e); + case 3: + return a.call(this, 0, e, f); + } + throw Error("Invalid arity: " + arguments.length); + }; + c.f = b; + c.h = a; + return c; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return z.f ? z.f(a, this) : z.call(null, a, this); +}; +g.f = function(a, b) { + return z.h ? z.h(a, this, b) : z.call(null, a, this, b); +}; +g.M = function() { + return this.la; +}; +g.P = function(a, b) { + return new Yc(this.fc, this.name, this.mb, this.Bb, b); +}; +g.U = function() { + var a = this.Bb; + return null != a ? a : this.Bb = a = Xc(Sc(this.name), Vc(this.fc)); +}; +g.S = function(a, b) { + return tc(b, this.mb); +}; +var Zc = function Zc(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return Zc.c(arguments[0]); + case 2: + return Zc.f(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Zc.c = function(a) { + if (a instanceof Yc) { + return a; + } + var b = a.indexOf("/"); + return 1 > b ? Zc.f(null, a) : Zc.f(a.substring(0, b), a.substring(b + 1, a.length)); +}; +Zc.f = function(a, b) { + var c = null != a ? [w(a), w("/"), w(b)].join("") : b; + return new Yc(a, b, c, null, null); +}; +Zc.F = 2; +function B(a) { + if (null == a) { + return null; + } + if (null != a && (a.m & 8388608 || a.ye)) { + return a.X(null); + } + if (pb(a) || "string" === typeof a) { + return 0 === a.length ? null : new C(a, 0, null); + } + if (t(pc, a)) { + return qc(a); + } + throw Error([w(a), w(" is not ISeqable")].join("")); +} +function D(a) { + if (null == a) { + return null; + } + if (null != a && (a.m & 64 || a.na)) { + return a.ba(null); + } + a = B(a); + return null == a ? null : Ob(a); +} +function $c(a) { + return null != a ? null != a && (a.m & 64 || a.na) ? a.ia(null) : (a = B(a)) ? Pb(a) : bd : bd; +} +function G(a) { + return null == a ? null : null != a && (a.m & 128 || a.nc) ? a.ma(null) : B($c(a)); +} +var H = function H(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return H.c(arguments[0]); + case 2: + return H.f(arguments[0], arguments[1]); + default: + return H.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +H.c = function() { + return !0; +}; +H.f = function(a, b) { + return null == a ? null == b : a === b || nc(a, b); +}; +H.A = function(a, b, c) { + for (;;) { + if (H.f(a, b)) { + if (G(c)) { + a = b, b = D(c), c = G(c); + } else { + return H.f(b, D(c)); + } + } else { + return !1; + } + } +}; +H.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return H.A(b, a, c); +}; +H.F = 2; +function cd(a) { + this.s = a; +} +cd.prototype.next = function() { + if (null != this.s) { + var a = D(this.s); + this.s = G(this.s); + return {value:a, done:!1}; + } + return {value:null, done:!0}; +}; +function dd(a) { + return new cd(B(a)); +} +function ed(a, b) { + var c = Pc(a), c = Qc(0, c); + return Rc(c, b); +} +function fd(a) { + var b = 0, c = 1; + for (a = B(a);;) { + if (null != a) { + b += 1, c = Oc(31, c) + Wc(D(a)) | 0, a = G(a); + } else { + return ed(c, b); + } + } +} +var gd = ed(1, 0); +function hd(a) { + var b = 0, c = 0; + for (a = B(a);;) { + if (null != a) { + b += 1, c = c + Wc(D(a)) | 0, a = G(a); + } else { + return ed(c, b); + } + } +} +var id = ed(0, 0); +Fb["null"] = !0; +Gb["null"] = function() { + return 0; +}; +Date.prototype.pe = !0; +Date.prototype.B = function(a, b) { + return b instanceof Date && this.valueOf() === b.valueOf(); +}; +nc.number = function(a, b) { + return a === b; +}; +Bb["function"] = !0; +hc["function"] = !0; +ic["function"] = function() { + return null; +}; +oc._ = function(a) { + return fa(a); +}; +function jd(a) { + return a + 1; +} +function kd() { + return !1; +} +function I(a) { + return gc(a); +} +function ld(a, b) { + var c = Gb(a); + if (0 === c) { + return b.D ? b.D() : b.call(null); + } + for (var d = y.f(a, 0), e = 1;;) { + if (e < c) { + var f = y.f(a, e), d = b.f ? b.f(d, f) : b.call(null, d, f), e = e + 1 + } else { + return d; + } + } +} +function md(a, b, c) { + var d = Gb(a), e = c; + for (c = 0;;) { + if (c < d) { + var f = y.f(a, c), e = b.f ? b.f(e, f) : b.call(null, e, f); + c += 1; + } else { + return e; + } + } +} +function nd(a, b) { + var c = a.length; + if (0 === a.length) { + return b.D ? b.D() : b.call(null); + } + for (var d = a[0], e = 1;;) { + if (e < c) { + var f = a[e], d = b.f ? b.f(d, f) : b.call(null, d, f), e = e + 1 + } else { + return d; + } + } +} +function od(a, b, c) { + var d = a.length, e = c; + for (c = 0;;) { + if (c < d) { + var f = a[c], e = b.f ? b.f(e, f) : b.call(null, e, f); + c += 1; + } else { + return e; + } + } +} +function pd(a, b, c, d) { + for (var e = a.length;;) { + if (d < e) { + var f = a[d]; + c = b.f ? b.f(c, f) : b.call(null, c, f); + d += 1; + } else { + return c; + } + } +} +function qd(a) { + return null != a ? a.m & 2 || a.le ? !0 : a.m ? !1 : t(Fb, a) : t(Fb, a); +} +function rd(a) { + return null != a ? a.m & 16 || a.hd ? !0 : a.m ? !1 : t(Mb, a) : t(Mb, a); +} +function J(a, b, c) { + var d = K.c ? K.c(a) : K.call(null, a); + if (c >= d) { + return -1; + } + !(0 < c) && 0 > c && (c += d, c = 0 > c ? 0 : c); + for (;;) { + if (c < d) { + if (H.f(sd ? sd(a, c) : td.call(null, a, c), b)) { + return c; + } + c += 1; + } else { + return -1; + } + } +} +function L(a, b, c) { + var d = K.c ? K.c(a) : K.call(null, a); + if (0 === d) { + return -1; + } + 0 < c ? (--d, c = d < c ? d : c) : c = 0 > c ? d + c : c; + for (;;) { + if (0 <= c) { + if (H.f(sd ? sd(a, c) : td.call(null, a, c), b)) { + return c; + } + --c; + } else { + return -1; + } + } +} +function ud(a, b) { + this.j = a; + this.i = b; +} +ud.prototype.ea = function() { + return this.i < this.j.length; +}; +ud.prototype.next = function() { + var a = this.j[this.i]; + this.i += 1; + return a; +}; +function C(a, b, c) { + this.j = a; + this.i = b; + this.meta = c; + this.m = 166592766; + this.C = 8192; +} +g = C.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K.c ? K.c(this) : K.call(null, this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.K = function(a, b) { + var c = b + this.i; + return c < this.j.length ? this.j[c] : null; +}; +g.sa = function(a, b, c) { + a = b + this.i; + return a < this.j.length ? this.j[a] : c; +}; +g.Da = function() { + return new ud(this.j, this.i); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new C(this.j, this.i, this.meta); +}; +g.ma = function() { + return this.i + 1 < this.j.length ? new C(this.j, this.i + 1, null) : null; +}; +g.Y = function() { + var a = this.j.length - this.i; + return 0 > a ? 0 : a; +}; +g.U = function() { + return fd(this); +}; +g.B = function(a, b) { + return vd.f ? vd.f(this, b) : vd.call(null, this, b); +}; +g.Z = function() { + return bd; +}; +g.fa = function(a, b) { + return pd(this.j, b, this.j[this.i], this.i + 1); +}; +g.ga = function(a, b, c) { + return pd(this.j, b, c, this.i); +}; +g.ba = function() { + return this.j[this.i]; +}; +g.ia = function() { + return this.i + 1 < this.j.length ? new C(this.j, this.i + 1, null) : bd; +}; +g.X = function() { + return this.i < this.j.length ? this : null; +}; +g.P = function(a, b) { + return new C(this.j, this.i, b); +}; +g.W = function(a, b) { + return N.f ? N.f(b, this) : N.call(null, b, this); +}; +C.prototype[ub] = function() { + return dd(this); +}; +function wd(a, b) { + return b < a.length ? new C(a, b, null) : null; +} +function O(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return wd(arguments[0], 0); + case 2: + return wd(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +nc._ = function(a, b) { + return a === b; +}; +var xd = function xd(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 0: + return xd.D(); + case 1: + return xd.c(arguments[0]); + case 2: + return xd.f(arguments[0], arguments[1]); + default: + return xd.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +xd.D = function() { + return zd; +}; +xd.c = function(a) { + return a; +}; +xd.f = function(a, b) { + return null != a ? Lb(a, b) : Lb(bd, b); +}; +xd.A = function(a, b, c) { + for (;;) { + if (q(c)) { + a = xd.f(a, b), b = D(c), c = G(c); + } else { + return xd.f(a, b); + } + } +}; +xd.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return xd.A(b, a, c); +}; +xd.F = 2; +function Ad(a) { + return null == a ? null : Hb(a); +} +function K(a) { + if (null != a) { + if (null != a && (a.m & 2 || a.le)) { + a = a.Y(null); + } else { + if (pb(a)) { + a = a.length; + } else { + if ("string" === typeof a) { + a = a.length; + } else { + if (null != a && (a.m & 8388608 || a.ye)) { + a: { + a = B(a); + for (var b = 0;;) { + if (qd(a)) { + a = b + Gb(a); + break a; + } + a = G(a); + b += 1; + } + } + } else { + a = Gb(a); + } + } + } + } + } else { + a = 0; + } + return a; +} +function Bd(a, b, c) { + for (;;) { + if (null == a) { + return c; + } + if (0 === b) { + return B(a) ? D(a) : c; + } + if (rd(a)) { + return y.h(a, b, c); + } + if (B(a)) { + a = G(a), --b; + } else { + return c; + } + } +} +function td(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 2: + return sd(arguments[0], arguments[1]); + case 3: + return P(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function sd(a, b) { + if ("number" !== typeof b) { + throw Error("index argument to nth must be a number"); + } + if (null == a) { + return a; + } + if (null != a && (a.m & 16 || a.hd)) { + return a.K(null, b); + } + if (pb(a)) { + return b < a.length ? a[b] : null; + } + if ("string" === typeof a) { + return b < a.length ? a.charAt(b) : null; + } + if (null != a && (a.m & 64 || a.na)) { + var c; + a: { + c = a; + for (var d = b;;) { + if (null == c) { + throw Error("Index out of bounds"); + } + if (0 === d) { + if (B(c)) { + c = D(c); + break a; + } + throw Error("Index out of bounds"); + } + if (rd(c)) { + c = y.f(c, d); + break a; + } + if (B(c)) { + c = G(c), --d; + } else { + throw Error("Index out of bounds"); + } + } + } + return c; + } + if (t(Mb, a)) { + return y.f(a, b); + } + throw Error([w("nth not supported on this type "), w(tb(null == a ? null : a.constructor))].join("")); +} +function P(a, b, c) { + if ("number" !== typeof b) { + throw Error("index argument to nth must be a number."); + } + if (null == a) { + return c; + } + if (null != a && (a.m & 16 || a.hd)) { + return a.sa(null, b, c); + } + if (pb(a)) { + return b < a.length ? a[b] : c; + } + if ("string" === typeof a) { + return b < a.length ? a.charAt(b) : c; + } + if (null != a && (a.m & 64 || a.na)) { + return Bd(a, b, c); + } + if (t(Mb, a)) { + return y.f(a, b); + } + throw Error([w("nth not supported on this type "), w(tb(null == a ? null : a.constructor))].join("")); +} +var z = function z(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return z.f(arguments[0], arguments[1]); + case 3: + return z.h(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +z.f = function(a, b) { + return null == a ? null : null != a && (a.m & 256 || a.re) ? a.O(null, b) : pb(a) ? b < a.length ? a[b | 0] : null : "string" === typeof a ? b < a.length ? a[b | 0] : null : t(Rb, a) ? Sb.f(a, b) : null; +}; +z.h = function(a, b, c) { + return null != a ? null != a && (a.m & 256 || a.re) ? a.J(null, b, c) : pb(a) ? b < a.length ? a[b] : c : "string" === typeof a ? b < a.length ? a[b] : c : t(Rb, a) ? Sb.h(a, b, c) : c : c; +}; +z.F = 3; +var S = function S(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 3: + return S.h(arguments[0], arguments[1], arguments[2]); + default: + return S.A(arguments[0], arguments[1], arguments[2], new C(c.slice(3), 0, null)); + } +}; +S.h = function(a, b, c) { + return null != a ? Ub(a, b, c) : Cd([b], [c]); +}; +S.A = function(a, b, c, d) { + for (;;) { + if (a = S.h(a, b, c), q(d)) { + b = D(d), c = D(G(d)), d = G(G(d)); + } else { + return a; + } + } +}; +S.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + var d = G(c), c = D(d), d = G(d); + return S.A(b, a, c, d); +}; +S.F = 3; +var Dd = function Dd(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return Dd.c(arguments[0]); + case 2: + return Dd.f(arguments[0], arguments[1]); + default: + return Dd.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +Dd.c = function(a) { + return a; +}; +Dd.f = function(a, b) { + return null == a ? null : Wb(a, b); +}; +Dd.A = function(a, b, c) { + for (;;) { + if (null == a) { + return null; + } + a = Dd.f(a, b); + if (q(c)) { + b = D(c), c = G(c); + } else { + return a; + } + } +}; +Dd.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return Dd.A(b, a, c); +}; +Dd.F = 2; +function Ed(a) { + var b = ea(a); + return b ? b : null != a ? a.je ? !0 : a.R ? !1 : t(Bb, a) : t(Bb, a); +} +function Gd(a, b) { + this.l = a; + this.meta = b; + this.m = 393217; + this.C = 0; +} +g = Gd.prototype; +g.M = function() { + return this.meta; +}; +g.P = function(a, b) { + return new Gd(this.l, b); +}; +g.je = !0; +g.call = function() { + function a(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M, Ka) { + a = this; + return Hd.lc ? Hd.lc(a.l, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M, Ka) : Hd.call(null, a.l, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M, Ka); + } + function b(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M) { + a = this; + return a.l.Va ? a.l.Va(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U, M); + } + function c(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U) { + a = this; + return a.l.Ua ? a.l.Ua(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da, U); + } + function d(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da) { + a = this; + return a.l.Ta ? a.l.Ta(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R, da); + } + function e(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R) { + a = this; + return a.l.Sa ? a.l.Sa(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E, R); + } + function f(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E) { + a = this; + return a.l.Ra ? a.l.Ra(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A, E); + } + function h(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A) { + a = this; + return a.l.Qa ? a.l.Qa(b, c, d, e, f, h, k, l, m, p, r, u, x, F, A) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F, A); + } + function k(a, b, c, d, e, f, h, k, l, m, p, r, u, x, F) { + a = this; + return a.l.Pa ? a.l.Pa(b, c, d, e, f, h, k, l, m, p, r, u, x, F) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x, F); + } + function l(a, b, c, d, e, f, h, k, l, m, p, r, u, x) { + a = this; + return a.l.Oa ? a.l.Oa(b, c, d, e, f, h, k, l, m, p, r, u, x) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u, x); + } + function m(a, b, c, d, e, f, h, k, l, m, p, r, u) { + a = this; + return a.l.Na ? a.l.Na(b, c, d, e, f, h, k, l, m, p, r, u) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r, u); + } + function p(a, b, c, d, e, f, h, k, l, m, p, r) { + a = this; + return a.l.Ma ? a.l.Ma(b, c, d, e, f, h, k, l, m, p, r) : a.l.call(null, b, c, d, e, f, h, k, l, m, p, r); + } + function r(a, b, c, d, e, f, h, k, l, m, p) { + a = this; + return a.l.La ? a.l.La(b, c, d, e, f, h, k, l, m, p) : a.l.call(null, b, c, d, e, f, h, k, l, m, p); + } + function u(a, b, c, d, e, f, h, k, l, m) { + a = this; + return a.l.Ya ? a.l.Ya(b, c, d, e, f, h, k, l, m) : a.l.call(null, b, c, d, e, f, h, k, l, m); + } + function x(a, b, c, d, e, f, h, k, l) { + a = this; + return a.l.Xa ? a.l.Xa(b, c, d, e, f, h, k, l) : a.l.call(null, b, c, d, e, f, h, k, l); + } + function E(a, b, c, d, e, f, h, k) { + a = this; + return a.l.Wa ? a.l.Wa(b, c, d, e, f, h, k) : a.l.call(null, b, c, d, e, f, h, k); + } + function A(a, b, c, d, e, f, h) { + a = this; + return a.l.za ? a.l.za(b, c, d, e, f, h) : a.l.call(null, b, c, d, e, f, h); + } + function F(a, b, c, d, e, f) { + a = this; + return a.l.N ? a.l.N(b, c, d, e, f) : a.l.call(null, b, c, d, e, f); + } + function R(a, b, c, d, e) { + a = this; + return a.l.w ? a.l.w(b, c, d, e) : a.l.call(null, b, c, d, e); + } + function U(a, b, c, d) { + a = this; + return a.l.h ? a.l.h(b, c, d) : a.l.call(null, b, c, d); + } + function da(a, b, c) { + a = this; + return a.l.f ? a.l.f(b, c) : a.l.call(null, b, c); + } + function Ka(a, b) { + a = this; + return a.l.c ? a.l.c(b) : a.l.call(null, b); + } + function wc(a) { + a = this; + return a.l.D ? a.l.D() : a.l.call(null); + } + var M = null, M = function(Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De, Kf, Kh, kk, Wm) { + switch(arguments.length) { + case 1: + return wc.call(this, Q); + case 2: + return Ka.call(this, Q, Y); + case 3: + return da.call(this, Q, Y, M); + case 4: + return U.call(this, Q, Y, M, Ga); + case 5: + return R.call(this, Q, Y, M, Ga, pa); + case 6: + return F.call(this, Q, Y, M, Ga, pa, Qa); + case 7: + return A.call(this, Q, Y, M, Ga, pa, Qa, Xa); + case 8: + return E.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb); + case 9: + return x.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb); + case 10: + return u.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb); + case 11: + return r.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb); + case 12: + return p.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb); + case 13: + return m.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb); + case 14: + return l.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb); + case 15: + return k.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b); + case 16: + return h.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad); + case 17: + return f.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd); + case 18: + return e.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De); + case 19: + return d.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De, Kf); + case 20: + return c.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De, Kf, Kh); + case 21: + return b.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De, Kf, Kh, kk); + case 22: + return a.call(this, Q, Y, M, Ga, pa, Qa, Xa, bb, fb, cb, rb, sb, Jb, Kb, $b, ad, Fd, De, Kf, Kh, kk, Wm); + } + throw Error("Invalid arity: " + arguments.length); + }; + M.c = wc; + M.f = Ka; + M.h = da; + M.w = U; + M.N = R; + M.za = F; + M.Wa = A; + M.Xa = E; + M.Ya = x; + M.La = u; + M.Ma = r; + M.Na = p; + M.Oa = m; + M.Pa = l; + M.Qa = k; + M.Ra = h; + M.Sa = f; + M.Ta = e; + M.Ua = d; + M.Va = c; + M.qe = b; + M.lc = a; + return M; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.D = function() { + return this.l.D ? this.l.D() : this.l.call(null); +}; +g.c = function(a) { + return this.l.c ? this.l.c(a) : this.l.call(null, a); +}; +g.f = function(a, b) { + return this.l.f ? this.l.f(a, b) : this.l.call(null, a, b); +}; +g.h = function(a, b, c) { + return this.l.h ? this.l.h(a, b, c) : this.l.call(null, a, b, c); +}; +g.w = function(a, b, c, d) { + return this.l.w ? this.l.w(a, b, c, d) : this.l.call(null, a, b, c, d); +}; +g.N = function(a, b, c, d, e) { + return this.l.N ? this.l.N(a, b, c, d, e) : this.l.call(null, a, b, c, d, e); +}; +g.za = function(a, b, c, d, e, f) { + return this.l.za ? this.l.za(a, b, c, d, e, f) : this.l.call(null, a, b, c, d, e, f); +}; +g.Wa = function(a, b, c, d, e, f, h) { + return this.l.Wa ? this.l.Wa(a, b, c, d, e, f, h) : this.l.call(null, a, b, c, d, e, f, h); +}; +g.Xa = function(a, b, c, d, e, f, h, k) { + return this.l.Xa ? this.l.Xa(a, b, c, d, e, f, h, k) : this.l.call(null, a, b, c, d, e, f, h, k); +}; +g.Ya = function(a, b, c, d, e, f, h, k, l) { + return this.l.Ya ? this.l.Ya(a, b, c, d, e, f, h, k, l) : this.l.call(null, a, b, c, d, e, f, h, k, l); +}; +g.La = function(a, b, c, d, e, f, h, k, l, m) { + return this.l.La ? this.l.La(a, b, c, d, e, f, h, k, l, m) : this.l.call(null, a, b, c, d, e, f, h, k, l, m); +}; +g.Ma = function(a, b, c, d, e, f, h, k, l, m, p) { + return this.l.Ma ? this.l.Ma(a, b, c, d, e, f, h, k, l, m, p) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p); +}; +g.Na = function(a, b, c, d, e, f, h, k, l, m, p, r) { + return this.l.Na ? this.l.Na(a, b, c, d, e, f, h, k, l, m, p, r) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r); +}; +g.Oa = function(a, b, c, d, e, f, h, k, l, m, p, r, u) { + return this.l.Oa ? this.l.Oa(a, b, c, d, e, f, h, k, l, m, p, r, u) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u); +}; +g.Pa = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x) { + return this.l.Pa ? this.l.Pa(a, b, c, d, e, f, h, k, l, m, p, r, u, x) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x); +}; +g.Qa = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E) { + return this.l.Qa ? this.l.Qa(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E); +}; +g.Ra = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A) { + return this.l.Ra ? this.l.Ra(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A); +}; +g.Sa = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F) { + return this.l.Sa ? this.l.Sa(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F); +}; +g.Ta = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R) { + return this.l.Ta ? this.l.Ta(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R); +}; +g.Ua = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U) { + return this.l.Ua ? this.l.Ua(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U); +}; +g.Va = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da) { + return this.l.Va ? this.l.Va(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da) : this.l.call(null, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da); +}; +g.qe = function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka) { + return Hd.lc ? Hd.lc(this.l, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka) : Hd.call(null, this.l, a, b, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka); +}; +function Id(a, b) { + return ea(a) ? new Gd(a, b) : null == a ? null : kc(a, b); +} +function Jd(a) { + var b = null != a; + return (b ? null != a ? a.m & 131072 || a.ue || (a.m ? 0 : t(hc, a)) : t(hc, a) : b) ? ic(a) : null; +} +var Kd = function Kd(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return Kd.c(arguments[0]); + case 2: + return Kd.f(arguments[0], arguments[1]); + default: + return Kd.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +Kd.c = function(a) { + return a; +}; +Kd.f = function(a, b) { + return null == a ? null : bc(a, b); +}; +Kd.A = function(a, b, c) { + for (;;) { + if (null == a) { + return null; + } + a = Kd.f(a, b); + if (q(c)) { + b = D(c), c = G(c); + } else { + return a; + } + } +}; +Kd.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return Kd.A(b, a, c); +}; +Kd.F = 2; +function Ld(a) { + return null == a || qb(B(a)); +} +function Md(a) { + return null == a ? !1 : null != a ? a.m & 4096 || a.Ff ? !0 : a.m ? !1 : t(ac, a) : t(ac, a); +} +function Nd(a) { + return null != a ? a.m & 16777216 || a.Ef ? !0 : a.m ? !1 : t(rc, a) : t(rc, a); +} +function Od(a) { + return null == a ? !1 : null != a ? a.m & 1024 || a.se ? !0 : a.m ? !1 : t(Vb, a) : t(Vb, a); +} +function Pd(a) { + return null != a ? a.m & 16384 || a.Gf ? !0 : a.m ? !1 : t(ec, a) : t(ec, a); +} +function Qd(a) { + return null != a ? a.C & 512 || a.yf ? !0 : !1 : !1; +} +function Rd(a) { + var b = []; + Ba(a, function(a, b) { + return function(a, c) { + return b.push(c); + }; + }(a, b)); + return b; +} +function Sd(a, b, c, d, e) { + for (;0 !== e;) { + c[d] = a[b], d += 1, --e, b += 1; + } +} +var Td = {}; +function Ud(a) { + return !0 === a; +} +function Vd(a) { + return null == a ? !1 : !1 === a ? !1 : !0; +} +function Wd(a) { + var b = Ed(a); + return b ? b : null != a ? a.m & 1 || a.Bf ? !0 : a.m ? !1 : t(Cb, a) : t(Cb, a); +} +function Xd(a, b) { + return z.h(a, b, Td) === Td ? !1 : !0; +} +function Yd(a, b) { + var c = B(b); + if (c) { + var d = D(c), c = G(c); + return zb ? zb(a, d, c) : Ab.call(null, a, d, c); + } + return a.D ? a.D() : a.call(null); +} +function Zd(a, b, c) { + for (c = B(c);;) { + if (c) { + var d = D(c); + b = a.f ? a.f(b, d) : a.call(null, b, d); + c = G(c); + } else { + return b; + } + } +} +function Ab(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 2: + return $d(arguments[0], arguments[1]); + case 3: + return zb(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function $d(a, b) { + return null != b && (b.m & 524288 || b.we) ? b.fa(null, a) : pb(b) ? nd(b, a) : "string" === typeof b ? nd(b, a) : t(lc, b) ? mc.f(b, a) : Yd(a, b); +} +function zb(a, b, c) { + return null != c && (c.m & 524288 || c.we) ? c.ga(null, a, b) : pb(c) ? od(c, a, b) : "string" === typeof c ? od(c, a, b) : t(lc, c) ? mc.h(c, a, b) : Zd(a, b, c); +} +function ae(a) { + return a; +} +function be(a, b, c, d) { + a = a.c ? a.c(b) : a.call(null, b); + c = zb(a, c, d); + return a.c ? a.c(c) : a.call(null, c); +} +function ce(a) { + a = (a - a % 2) / 2; + return 0 <= a ? Math.floor(a) : Math.ceil(a); +} +function de(a) { + a -= a >> 1 & 1431655765; + a = (a & 858993459) + (a >> 2 & 858993459); + return 16843009 * (a + (a >> 4) & 252645135) >> 24; +} +function ee(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return !0; + case 2: + return nc(arguments[0], arguments[1]); + default: + a: { + for (c = arguments[0], d = arguments[1], b = new C(b.slice(2), 0, null);;) { + if (c === d) { + if (G(b)) { + c = d, d = D(b), b = G(b); + } else { + c = d === D(b); + break a; + } + } else { + c = !1; + break a; + } + } + } + return c; + } +} +function fe(a, b) { + return nc(a, b); +} +var w = function w(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 0: + return w.D(); + case 1: + return w.c(arguments[0]); + default: + return w.A(arguments[0], new C(c.slice(1), 0, null)); + } +}; +w.D = function() { + return ""; +}; +w.c = function(a) { + return null == a ? "" : "" + a; +}; +w.A = function(a, b) { + for (var c = new Ua("" + w(a)), d = b;;) { + if (q(d)) { + c = c.append("" + w(D(d))), d = G(d); + } else { + return c.toString(); + } + } +}; +w.L = function(a) { + var b = D(a); + a = G(a); + return w.A(b, a); +}; +w.F = 1; +function ge(a, b, c) { + return a.substring(b, c); +} +function vd(a, b) { + var c; + if (Nd(b)) { + if (qd(a) && qd(b) && K(a) !== K(b)) { + c = !1; + } else { + a: { + c = B(a); + for (var d = B(b);;) { + if (null == c) { + c = null == d; + break a; + } + if (null != d && H.f(D(c), D(d))) { + c = G(c), d = G(d); + } else { + c = !1; + break a; + } + } + } + } + } else { + c = null; + } + return Vd(c); +} +function he(a, b, c, d, e) { + this.meta = a; + this.first = b; + this.Ha = c; + this.count = d; + this.v = e; + this.m = 65937646; + this.C = 8192; +} +g = he.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, this.count); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new he(this.meta, this.first, this.Ha, this.count, this.v); +}; +g.ma = function() { + return 1 === this.count ? null : this.Ha; +}; +g.Y = function() { + return this.count; +}; +g.ob = function() { + return this.first; +}; +g.pb = function() { + return Pb(this); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return kc(bd, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return this.first; +}; +g.ia = function() { + return 1 === this.count ? bd : this.Ha; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new he(b, this.first, this.Ha, this.count, this.v); +}; +g.W = function(a, b) { + return new he(this.meta, b, this, this.count + 1, null); +}; +he.prototype[ub] = function() { + return dd(this); +}; +function ie(a) { + this.meta = a; + this.m = 65937614; + this.C = 8192; +} +g = ie.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new ie(this.meta); +}; +g.ma = function() { + return null; +}; +g.Y = function() { + return 0; +}; +g.ob = function() { + return null; +}; +g.pb = function() { + throw Error("Can't pop empty list"); +}; +g.U = function() { + return gd; +}; +g.B = function(a, b) { + return (null != b ? b.m & 33554432 || b.Df || (b.m ? 0 : t(sc, b)) : t(sc, b)) || Nd(b) ? null == B(b) : !1; +}; +g.Z = function() { + return this; +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return null; +}; +g.ia = function() { + return bd; +}; +g.X = function() { + return null; +}; +g.P = function(a, b) { + return new ie(b); +}; +g.W = function(a, b) { + return new he(this.meta, b, null, 1, null); +}; +var bd = new ie(null); +ie.prototype[ub] = function() { + return dd(this); +}; +function je(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + a: { + c = 0 < b.length ? new C(b.slice(0), 0, null) : null; + if (c instanceof C && 0 === c.i) { + b = c.j; + } else { + b: { + for (b = [];;) { + if (null != c) { + b.push(c.ba(null)), c = c.ma(null); + } else { + break b; + } + } + } + } + for (var c = b.length, e = bd;;) { + if (0 < c) { + d = c - 1, e = e.W(null, b[c - 1]), c = d; + } else { + break a; + } + } + } + return e; +} +function ke(a, b, c, d) { + this.meta = a; + this.first = b; + this.Ha = c; + this.v = d; + this.m = 65929452; + this.C = 8192; +} +g = ke.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new ke(this.meta, this.first, this.Ha, this.v); +}; +g.ma = function() { + return null == this.Ha ? null : B(this.Ha); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return this.first; +}; +g.ia = function() { + return null == this.Ha ? bd : this.Ha; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new ke(b, this.first, this.Ha, this.v); +}; +g.W = function(a, b) { + return new ke(null, b, this, null); +}; +ke.prototype[ub] = function() { + return dd(this); +}; +function N(a, b) { + var c = null == b; + return (c ? c : null != b && (b.m & 64 || b.na)) ? new ke(null, a, b, null) : new ke(null, a, B(b), null); +} +function T(a, b, c, d) { + this.fc = a; + this.name = b; + this.Ia = c; + this.Bb = d; + this.m = 2153775105; + this.C = 4096; +} +g = T.prototype; +g.toString = function() { + return [w(":"), w(this.Ia)].join(""); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.B = function(a, b) { + return b instanceof T ? this.Ia === b.Ia : !1; +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return z.f(c, this); + case 3: + return z.h(c, this, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return z.f(c, this); + }; + a.h = function(a, c, d) { + return z.h(c, this, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return z.f(a, this); +}; +g.f = function(a, b) { + return z.h(a, this, b); +}; +g.U = function() { + var a = this.Bb; + return null != a ? a : this.Bb = a = Xc(Sc(this.name), Vc(this.fc)) + 2654435769 | 0; +}; +g.S = function(a, b) { + return tc(b, [w(":"), w(this.Ia)].join("")); +}; +function le(a, b) { + return a === b ? !0 : a instanceof T && b instanceof T ? a.Ia === b.Ia : !1; +} +var me = function me(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return me.c(arguments[0]); + case 2: + return me.f(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +me.c = function(a) { + if (a instanceof T) { + return a; + } + if (a instanceof Yc) { + var b; + if (null != a && (a.C & 4096 || a.ve)) { + b = a.fc; + } else { + throw Error([w("Doesn't support namespace: "), w(a)].join("")); + } + return new T(b, ne.c ? ne.c(a) : ne.call(null, a), a.mb, null); + } + return "string" === typeof a ? (b = a.split("/"), 2 === b.length ? new T(b[0], b[1], a, null) : new T(null, b[0], a, null)) : null; +}; +me.f = function(a, b) { + return new T(a, b, [w(q(a) ? [w(a), w("/")].join("") : null), w(b)].join(""), null); +}; +me.F = 2; +function oe(a, b, c, d) { + this.meta = a; + this.Hb = b; + this.s = c; + this.v = d; + this.m = 32374988; + this.C = 1; +} +g = oe.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +function pe(a) { + null != a.Hb && (a.s = a.Hb.D ? a.Hb.D() : a.Hb.call(null), a.Hb = null); + return a.s; +} +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ma = function() { + qc(this); + return null == this.s ? null : G(this.s); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + qc(this); + return null == this.s ? null : D(this.s); +}; +g.ia = function() { + qc(this); + return null != this.s ? $c(this.s) : bd; +}; +g.X = function() { + pe(this); + if (null == this.s) { + return null; + } + for (var a = this.s;;) { + if (a instanceof oe) { + a = pe(a); + } else { + return this.s = a, B(this.s); + } + } +}; +g.P = function(a, b) { + return new oe(b, this.Hb, this.s, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +oe.prototype[ub] = function() { + return dd(this); +}; +function qe(a, b) { + this.H = a; + this.end = b; + this.m = 2; + this.C = 0; +} +qe.prototype.add = function(a) { + this.H[this.end] = a; + return this.end += 1; +}; +qe.prototype.ya = function() { + var a = new re(this.H, 0, this.end); + this.H = null; + return a; +}; +qe.prototype.Y = function() { + return this.end; +}; +function re(a, b, c) { + this.j = a; + this.ca = b; + this.end = c; + this.m = 524306; + this.C = 0; +} +g = re.prototype; +g.Y = function() { + return this.end - this.ca; +}; +g.K = function(a, b) { + return this.j[this.ca + b]; +}; +g.sa = function(a, b, c) { + return 0 <= b && b < this.end - this.ca ? this.j[this.ca + b] : c; +}; +g.gd = function() { + if (this.ca === this.end) { + throw Error("-drop-first of empty chunk"); + } + return new re(this.j, this.ca + 1, this.end); +}; +g.fa = function(a, b) { + return pd(this.j, b, this.j[this.ca], this.ca + 1); +}; +g.ga = function(a, b, c) { + return pd(this.j, b, c, this.ca); +}; +function se(a, b, c, d) { + this.ya = a; + this.Ka = b; + this.meta = c; + this.v = d; + this.m = 31850732; + this.C = 1536; +} +g = se.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ma = function() { + if (1 < Gb(this.ya)) { + return new se(Ec(this.ya), this.Ka, this.meta, null); + } + var a = qc(this.Ka); + return null == a ? null : a; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.ba = function() { + return y.f(this.ya, 0); +}; +g.ia = function() { + return 1 < Gb(this.ya) ? new se(Ec(this.ya), this.Ka, this.meta, null) : null == this.Ka ? bd : this.Ka; +}; +g.X = function() { + return this; +}; +g.Ec = function() { + return this.ya; +}; +g.Fc = function() { + return null == this.Ka ? bd : this.Ka; +}; +g.P = function(a, b) { + return new se(this.ya, this.Ka, b, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +g.Dc = function() { + return null == this.Ka ? null : this.Ka; +}; +se.prototype[ub] = function() { + return dd(this); +}; +function te(a, b) { + return 0 === Gb(a) ? b : new se(a, b, null, null); +} +function ue(a, b) { + a.add(b); +} +function ve(a) { + for (var b = [];;) { + if (B(a)) { + b.push(D(a)), a = G(a); + } else { + return b; + } + } +} +function we(a, b) { + if (qd(b)) { + return K(b); + } + for (var c = 0, d = B(b);;) { + if (null != d && c < a) { + c += 1, d = G(d); + } else { + return c; + } + } +} +var xe = function xe(b) { + return null == b ? null : null == G(b) ? B(D(b)) : N(D(b), xe(G(b))); +}, ye = function ye(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 0: + return ye.D(); + case 1: + return ye.c(arguments[0]); + case 2: + return ye.f(arguments[0], arguments[1]); + default: + return ye.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +ye.D = function() { + return new oe(null, function() { + return null; + }, null, null); +}; +ye.c = function(a) { + return new oe(null, function() { + return a; + }, null, null); +}; +ye.f = function(a, b) { + return new oe(null, function() { + var c = B(a); + return c ? Qd(c) ? te(Fc(c), ye.f(Gc(c), b)) : N(D(c), ye.f($c(c), b)) : b; + }, null, null); +}; +ye.A = function(a, b, c) { + return function e(a, b) { + return new oe(null, function() { + var c = B(a); + return c ? Qd(c) ? te(Fc(c), e(Gc(c), b)) : N(D(c), e($c(c), b)) : q(b) ? e(D(b), G(b)) : null; + }, null, null); + }(ye.f(a, b), c); +}; +ye.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return ye.A(b, a, c); +}; +ye.F = 2; +var ze = function ze(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 0: + return ze.D(); + case 1: + return ze.c(arguments[0]); + case 2: + return ze.f(arguments[0], arguments[1]); + default: + return ze.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +ze.D = function() { + return zc(zd); +}; +ze.c = function(a) { + return a; +}; +ze.f = function(a, b) { + return Ac(a, b); +}; +ze.A = function(a, b, c) { + for (;;) { + if (a = Ac(a, b), q(c)) { + b = D(c), c = G(c); + } else { + return a; + } + } +}; +ze.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return ze.A(b, a, c); +}; +ze.F = 2; +function Ae(a, b, c) { + var d = B(c); + if (0 === b) { + return a.D ? a.D() : a.call(null); + } + c = Ob(d); + var e = Pb(d); + if (1 === b) { + return a.c ? a.c(c) : a.c ? a.c(c) : a.call(null, c); + } + var d = Ob(e), f = Pb(e); + if (2 === b) { + return a.f ? a.f(c, d) : a.f ? a.f(c, d) : a.call(null, c, d); + } + var e = Ob(f), h = Pb(f); + if (3 === b) { + return a.h ? a.h(c, d, e) : a.h ? a.h(c, d, e) : a.call(null, c, d, e); + } + var f = Ob(h), k = Pb(h); + if (4 === b) { + return a.w ? a.w(c, d, e, f) : a.w ? a.w(c, d, e, f) : a.call(null, c, d, e, f); + } + var h = Ob(k), l = Pb(k); + if (5 === b) { + return a.N ? a.N(c, d, e, f, h) : a.N ? a.N(c, d, e, f, h) : a.call(null, c, d, e, f, h); + } + var k = Ob(l), m = Pb(l); + if (6 === b) { + return a.za ? a.za(c, d, e, f, h, k) : a.za ? a.za(c, d, e, f, h, k) : a.call(null, c, d, e, f, h, k); + } + var l = Ob(m), p = Pb(m); + if (7 === b) { + return a.Wa ? a.Wa(c, d, e, f, h, k, l) : a.Wa ? a.Wa(c, d, e, f, h, k, l) : a.call(null, c, d, e, f, h, k, l); + } + var m = Ob(p), r = Pb(p); + if (8 === b) { + return a.Xa ? a.Xa(c, d, e, f, h, k, l, m) : a.Xa ? a.Xa(c, d, e, f, h, k, l, m) : a.call(null, c, d, e, f, h, k, l, m); + } + var p = Ob(r), u = Pb(r); + if (9 === b) { + return a.Ya ? a.Ya(c, d, e, f, h, k, l, m, p) : a.Ya ? a.Ya(c, d, e, f, h, k, l, m, p) : a.call(null, c, d, e, f, h, k, l, m, p); + } + var r = Ob(u), x = Pb(u); + if (10 === b) { + return a.La ? a.La(c, d, e, f, h, k, l, m, p, r) : a.La ? a.La(c, d, e, f, h, k, l, m, p, r) : a.call(null, c, d, e, f, h, k, l, m, p, r); + } + var u = Ob(x), E = Pb(x); + if (11 === b) { + return a.Ma ? a.Ma(c, d, e, f, h, k, l, m, p, r, u) : a.Ma ? a.Ma(c, d, e, f, h, k, l, m, p, r, u) : a.call(null, c, d, e, f, h, k, l, m, p, r, u); + } + var x = Ob(E), A = Pb(E); + if (12 === b) { + return a.Na ? a.Na(c, d, e, f, h, k, l, m, p, r, u, x) : a.Na ? a.Na(c, d, e, f, h, k, l, m, p, r, u, x) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x); + } + var E = Ob(A), F = Pb(A); + if (13 === b) { + return a.Oa ? a.Oa(c, d, e, f, h, k, l, m, p, r, u, x, E) : a.Oa ? a.Oa(c, d, e, f, h, k, l, m, p, r, u, x, E) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E); + } + var A = Ob(F), R = Pb(F); + if (14 === b) { + return a.Pa ? a.Pa(c, d, e, f, h, k, l, m, p, r, u, x, E, A) : a.Pa ? a.Pa(c, d, e, f, h, k, l, m, p, r, u, x, E, A) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A); + } + var F = Ob(R), U = Pb(R); + if (15 === b) { + return a.Qa ? a.Qa(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F) : a.Qa ? a.Qa(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F); + } + var R = Ob(U), da = Pb(U); + if (16 === b) { + return a.Ra ? a.Ra(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R) : a.Ra ? a.Ra(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R); + } + var U = Ob(da), Ka = Pb(da); + if (17 === b) { + return a.Sa ? a.Sa(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U) : a.Sa ? a.Sa(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U); + } + var da = Ob(Ka), wc = Pb(Ka); + if (18 === b) { + return a.Ta ? a.Ta(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da) : a.Ta ? a.Ta(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da); + } + Ka = Ob(wc); + wc = Pb(wc); + if (19 === b) { + return a.Ua ? a.Ua(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka) : a.Ua ? a.Ua(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka); + } + var M = Ob(wc); + Pb(wc); + if (20 === b) { + return a.Va ? a.Va(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka, M) : a.Va ? a.Va(c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka, M) : a.call(null, c, d, e, f, h, k, l, m, p, r, u, x, E, A, F, R, U, da, Ka, M); + } + throw Error("Only up to 20 arguments supported on functions"); +} +function Hd(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 2: + return Be(arguments[0], arguments[1]); + case 3: + return Ee(arguments[0], arguments[1], arguments[2]); + case 4: + return Fe(arguments[0], arguments[1], arguments[2], arguments[3]); + case 5: + return Ge(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4]); + default: + return He(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], new C(b.slice(5), 0, null)); + } +} +function Be(a, b) { + var c = a.F; + if (a.L) { + var d = we(c + 1, b); + return d <= c ? Ae(a, d, b) : a.L(b); + } + return a.apply(a, ve(b)); +} +function Ee(a, b, c) { + b = N(b, c); + c = a.F; + if (a.L) { + var d = we(c + 1, b); + return d <= c ? Ae(a, d, b) : a.L(b); + } + return a.apply(a, ve(b)); +} +function Fe(a, b, c, d) { + b = N(b, N(c, d)); + c = a.F; + return a.L ? (d = we(c + 1, b), d <= c ? Ae(a, d, b) : a.L(b)) : a.apply(a, ve(b)); +} +function Ge(a, b, c, d, e) { + b = N(b, N(c, N(d, e))); + c = a.F; + return a.L ? (d = we(c + 1, b), d <= c ? Ae(a, d, b) : a.L(b)) : a.apply(a, ve(b)); +} +function He(a, b, c, d, e, f) { + b = N(b, N(c, N(d, N(e, xe(f))))); + c = a.F; + return a.L ? (d = we(c + 1, b), d <= c ? Ae(a, d, b) : a.L(b)) : a.apply(a, ve(b)); +} +function Ie(a, b) { + return !H.f(a, b); +} +var Je = function Je() { + "undefined" === typeof $a && ($a = function(b, c) { + this.Pe = b; + this.Ne = c; + this.m = 393216; + this.C = 0; + }, $a.prototype.P = function(b, c) { + return new $a(this.Pe, c); + }, $a.prototype.M = function() { + return this.Ne; + }, $a.prototype.ea = function() { + return !1; + }, $a.prototype.next = function() { + return Error("No such element"); + }, $a.prototype.remove = function() { + return Error("Unsupported operation"); + }, $a.Wb = function() { + return new V(null, 2, 5, W, [Id(Ke, new ib(null, 1, [Le, je(Me, je(zd))], null)), Za.Mf], null); + }, $a.qb = !0, $a.Za = "cljs.core/t_cljs$core9933", $a.Eb = function(b, c) { + return tc(c, "cljs.core/t_cljs$core9933"); + }); + return new $a(Je, Ne); +}; +function Oe(a, b) { + for (;;) { + if (null == B(b)) { + return !0; + } + var c; + c = D(b); + c = a.c ? a.c(c) : a.call(null, c); + if (q(c)) { + c = a; + var d = G(b); + a = c; + b = d; + } else { + return !1; + } + } +} +function Pe(a, b) { + for (;;) { + if (B(b)) { + var c; + c = D(b); + c = a.c ? a.c(c) : a.call(null, c); + if (q(c)) { + return c; + } + c = a; + var d = G(b); + a = c; + b = d; + } else { + return null; + } + } +} +function Qe(a) { + return function() { + function b(b, c) { + return qb(a.f ? a.f(b, c) : a.call(null, b, c)); + } + function c(b) { + return qb(a.c ? a.c(b) : a.call(null, b)); + } + function d() { + return qb(a.D ? a.D() : a.call(null)); + } + var e = null, f = function() { + function b(a, d, e) { + var f = null; + if (2 < arguments.length) { + for (var f = 0, h = Array(arguments.length - 2);f < h.length;) { + h[f] = arguments[f + 2], ++f; + } + f = new C(h, 0); + } + return c.call(this, a, d, f); + } + function c(b, d, e) { + return qb(Fe(a, b, d, e)); + } + b.F = 2; + b.L = function(a) { + var b = D(a); + a = G(a); + var d = D(a); + a = $c(a); + return c(b, d, a); + }; + b.A = c; + return b; + }(), e = function(a, e, l) { + switch(arguments.length) { + case 0: + return d.call(this); + case 1: + return c.call(this, a); + case 2: + return b.call(this, a, e); + default: + var m = null; + if (2 < arguments.length) { + for (var m = 0, p = Array(arguments.length - 2);m < p.length;) { + p[m] = arguments[m + 2], ++m; + } + m = new C(p, 0); + } + return f.A(a, e, m); + } + throw Error("Invalid arity: " + arguments.length); + }; + e.F = 2; + e.L = f.L; + e.D = d; + e.c = c; + e.f = b; + e.A = f.A; + return e; + }(); +} +function Re() { + return function() { + function a(a) { + if (0 < arguments.length) { + for (var c = 0, d = Array(arguments.length - 0);c < d.length;) { + d[c] = arguments[c + 0], ++c; + } + } + return !1; + } + a.F = 0; + a.L = function(a) { + B(a); + return !1; + }; + a.A = function() { + return !1; + }; + return a; + }(); +} +function Se(a, b, c, d) { + this.state = a; + this.meta = b; + this.wf = c; + this.Pb = d; + this.C = 16386; + this.m = 6455296; +} +g = Se.prototype; +g.equiv = function(a) { + return this.B(null, a); +}; +g.B = function(a, b) { + return this === b; +}; +g.Cb = function() { + return this.state; +}; +g.M = function() { + return this.meta; +}; +g.md = function(a, b, c) { + a = B(this.Pb); + for (var d = null, e = 0, f = 0;;) { + if (f < e) { + var h = d.K(null, f), k = P(h, 0, null), h = P(h, 1, null); + h.w ? h.w(k, this, b, c) : h.call(null, k, this, b, c); + f += 1; + } else { + if (a = B(a)) { + Qd(a) ? (d = Fc(a), a = Gc(a), k = d, e = K(d), d = k) : (d = D(a), k = P(d, 0, null), h = P(d, 1, null), h.w ? h.w(k, this, b, c) : h.call(null, k, this, b, c), a = G(a), d = null, e = 0), f = 0; + } else { + return null; + } + } + } +}; +g.ld = function(a, b, c) { + this.Pb = S.h(this.Pb, b, c); + return this; +}; +g.nd = function(a, b) { + return this.Pb = Dd.f(this.Pb, b); +}; +g.U = function() { + return fa(this); +}; +function Te(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return Ue(arguments[0]); + default: + return c = arguments[0], b = new C(b.slice(1), 0, null), d = null != b && (b.m & 64 || b.na) ? Be(Ve, b) : b, b = z.f(d, lb), d = z.f(d, We), new Se(c, b, d, null); + } +} +function Ue(a) { + return new Se(a, null, null, null); +} +function Xe(a, b) { + if (a instanceof Se) { + var c = a.wf; + if (null != c && !q(c.c ? c.c(b) : c.call(null, b))) { + throw Error("Validator rejected reference state"); + } + c = a.state; + a.state = b; + null != a.Pb && vc(a, c, b); + return b; + } + return Jc(a, b); +} +var Ye = function Ye(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return Ye.f(arguments[0], arguments[1]); + case 3: + return Ye.h(arguments[0], arguments[1], arguments[2]); + case 4: + return Ye.w(arguments[0], arguments[1], arguments[2], arguments[3]); + default: + return Ye.A(arguments[0], arguments[1], arguments[2], arguments[3], new C(c.slice(4), 0, null)); + } +}; +Ye.f = function(a, b) { + var c; + a instanceof Se ? (c = a.state, c = b.c ? b.c(c) : b.call(null, c), c = Xe(a, c)) : c = Kc.f(a, b); + return c; +}; +Ye.h = function(a, b, c) { + if (a instanceof Se) { + var d = a.state; + b = b.f ? b.f(d, c) : b.call(null, d, c); + a = Xe(a, b); + } else { + a = Kc.h(a, b, c); + } + return a; +}; +Ye.w = function(a, b, c, d) { + if (a instanceof Se) { + var e = a.state; + b = b.h ? b.h(e, c, d) : b.call(null, e, c, d); + a = Xe(a, b); + } else { + a = Kc.w(a, b, c, d); + } + return a; +}; +Ye.A = function(a, b, c, d, e) { + return a instanceof Se ? Xe(a, Ge(b, a.state, c, d, e)) : Kc.N(a, b, c, d, e); +}; +Ye.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + var d = G(c), c = D(d), e = G(d), d = D(e), e = G(e); + return Ye.A(b, a, c, d, e); +}; +Ye.F = 4; +var X = function X(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return X.c(arguments[0]); + case 2: + return X.f(arguments[0], arguments[1]); + case 3: + return X.h(arguments[0], arguments[1], arguments[2]); + case 4: + return X.w(arguments[0], arguments[1], arguments[2], arguments[3]); + default: + return X.A(arguments[0], arguments[1], arguments[2], arguments[3], new C(c.slice(4), 0, null)); + } +}; +X.c = function(a) { + return function(b) { + return function() { + function c(c, d) { + var e = a.c ? a.c(d) : a.call(null, d); + return b.f ? b.f(c, e) : b.call(null, c, e); + } + function d(a) { + return b.c ? b.c(a) : b.call(null, a); + } + function e() { + return b.D ? b.D() : b.call(null); + } + var f = null, h = function() { + function c(a, b, e) { + var f = null; + if (2 < arguments.length) { + for (var f = 0, h = Array(arguments.length - 2);f < h.length;) { + h[f] = arguments[f + 2], ++f; + } + f = new C(h, 0); + } + return d.call(this, a, b, f); + } + function d(c, e, f) { + e = Ee(a, e, f); + return b.f ? b.f(c, e) : b.call(null, c, e); + } + c.F = 2; + c.L = function(a) { + var b = D(a); + a = G(a); + var c = D(a); + a = $c(a); + return d(b, c, a); + }; + c.A = d; + return c; + }(), f = function(a, b, f) { + switch(arguments.length) { + case 0: + return e.call(this); + case 1: + return d.call(this, a); + case 2: + return c.call(this, a, b); + default: + var p = null; + if (2 < arguments.length) { + for (var p = 0, r = Array(arguments.length - 2);p < r.length;) { + r[p] = arguments[p + 2], ++p; + } + p = new C(r, 0); + } + return h.A(a, b, p); + } + throw Error("Invalid arity: " + arguments.length); + }; + f.F = 2; + f.L = h.L; + f.D = e; + f.c = d; + f.f = c; + f.A = h.A; + return f; + }(); + }; +}; +X.f = function(a, b) { + return new oe(null, function() { + var c = B(b); + if (c) { + if (Qd(c)) { + for (var d = Fc(c), e = K(d), f = new qe(Array(e), 0), h = 0;;) { + if (h < e) { + ue(f, function() { + var b = y.f(d, h); + return a.c ? a.c(b) : a.call(null, b); + }()), h += 1; + } else { + break; + } + } + return te(f.ya(), X.f(a, Gc(c))); + } + return N(function() { + var b = D(c); + return a.c ? a.c(b) : a.call(null, b); + }(), X.f(a, $c(c))); + } + return null; + }, null, null); +}; +X.h = function(a, b, c) { + return new oe(null, function() { + var d = B(b), e = B(c); + if (d && e) { + var f = N, h; + h = D(d); + var k = D(e); + h = a.f ? a.f(h, k) : a.call(null, h, k); + d = f(h, X.h(a, $c(d), $c(e))); + } else { + d = null; + } + return d; + }, null, null); +}; +X.w = function(a, b, c, d) { + return new oe(null, function() { + var e = B(b), f = B(c), h = B(d); + if (e && f && h) { + var k = N, l; + l = D(e); + var m = D(f), p = D(h); + l = a.h ? a.h(l, m, p) : a.call(null, l, m, p); + e = k(l, X.w(a, $c(e), $c(f), $c(h))); + } else { + e = null; + } + return e; + }, null, null); +}; +X.A = function(a, b, c, d, e) { + var f = function k(a) { + return new oe(null, function() { + var b = X.f(B, a); + return Oe(ae, b) ? N(X.f(D, b), k(X.f($c, b))) : null; + }, null, null); + }; + return X.f(function() { + return function(b) { + return Be(a, b); + }; + }(f), f(xd.A(e, d, O([c, b], 0)))); +}; +X.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + var d = G(c), c = D(d), e = G(d), d = D(e), e = G(e); + return X.A(b, a, c, d, e); +}; +X.F = 4; +function Ze(a) { + return new oe(null, function(b) { + return function() { + return b(1, a); + }; + }(function(a, c) { + for (;;) { + var d = B(c); + if (0 < a && d) { + var e = a - 1, d = $c(d); + a = e; + c = d; + } else { + return d; + } + } + }), null, null); +} +function $e(a) { + return new oe(null, function() { + return N(a, $e(a)); + }, null, null); +} +var af = function af(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return af.f(arguments[0], arguments[1]); + default: + return af.A(arguments[0], arguments[1], new C(c.slice(2), 0, null)); + } +}; +af.f = function(a, b) { + return new oe(null, function() { + var c = B(a), d = B(b); + return c && d ? N(D(c), N(D(d), af.f($c(c), $c(d)))) : null; + }, null, null); +}; +af.A = function(a, b, c) { + return new oe(null, function() { + var d = X.f(B, xd.A(c, b, O([a], 0))); + return Oe(ae, d) ? ye.f(X.f(D, d), Be(af, X.f($c, d))) : null; + }, null, null); +}; +af.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + c = G(c); + return af.A(b, a, c); +}; +af.F = 2; +function bf(a, b) { + return new oe(null, function() { + var c = B(b); + if (c) { + if (Qd(c)) { + for (var d = Fc(c), e = K(d), f = new qe(Array(e), 0), h = 0;;) { + if (h < e) { + var k; + k = y.f(d, h); + k = a.c ? a.c(k) : a.call(null, k); + q(k) && (k = y.f(d, h), f.add(k)); + h += 1; + } else { + break; + } + } + return te(f.ya(), bf(a, Gc(c))); + } + d = D(c); + c = $c(c); + return q(a.c ? a.c(d) : a.call(null, d)) ? N(d, bf(a, c)) : bf(a, c); + } + return null; + }, null, null); +} +function cf(a, b) { + return bf(Qe(a), b); +} +function df(a, b) { + return null != a ? null != a && (a.C & 4 || a.me) ? Id(Bc(zb(Ac, zc(a), b)), Jd(a)) : zb(Lb, a, b) : zb(xd, bd, b); +} +function ef(a, b) { + return zb(z, a, b); +} +function ff(a, b, c) { + var d = Td; + for (b = B(b);;) { + if (null != b) { + a = z.h(a, D(b), d); + if (d === a) { + return c; + } + b = G(b); + } else { + return a; + } + } +} +var gf = function gf(b, c, d) { + var e = B(c); + c = D(e); + return (e = G(e)) ? S.h(b, c, gf(z.f(b, c), e, d)) : S.h(b, c, d); +}, hf = function hf(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 3: + return hf.h(arguments[0], arguments[1], arguments[2]); + case 4: + return hf.w(arguments[0], arguments[1], arguments[2], arguments[3]); + case 5: + return hf.N(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4]); + case 6: + return hf.za(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5]); + default: + return hf.A(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], new C(c.slice(6), 0, null)); + } +}; +hf.h = function(a, b, c) { + b = B(b); + var d = D(b); + return (b = G(b)) ? S.h(a, d, hf.h(z.f(a, d), b, c)) : S.h(a, d, function() { + var b = z.f(a, d); + return c.c ? c.c(b) : c.call(null, b); + }()); +}; +hf.w = function(a, b, c, d) { + b = B(b); + var e = D(b); + return (b = G(b)) ? S.h(a, e, hf.w(z.f(a, e), b, c, d)) : S.h(a, e, function() { + var b = z.f(a, e); + return c.f ? c.f(b, d) : c.call(null, b, d); + }()); +}; +hf.N = function(a, b, c, d, e) { + b = B(b); + var f = D(b); + return (b = G(b)) ? S.h(a, f, hf.N(z.f(a, f), b, c, d, e)) : S.h(a, f, function() { + var b = z.f(a, f); + return c.h ? c.h(b, d, e) : c.call(null, b, d, e); + }()); +}; +hf.za = function(a, b, c, d, e, f) { + b = B(b); + var h = D(b); + return (b = G(b)) ? S.h(a, h, hf.za(z.f(a, h), b, c, d, e, f)) : S.h(a, h, function() { + var b = z.f(a, h); + return c.w ? c.w(b, d, e, f) : c.call(null, b, d, e, f); + }()); +}; +hf.A = function(a, b, c, d, e, f, h) { + var k = B(b); + b = D(k); + return (k = G(k)) ? S.h(a, b, He(hf, z.f(a, b), k, c, d, O([e, f, h], 0))) : S.h(a, b, He(c, z.f(a, b), d, e, f, O([h], 0))); +}; +hf.L = function(a) { + var b = D(a), c = G(a); + a = D(c); + var d = G(c), c = D(d), e = G(d), d = D(e), f = G(e), e = D(f), h = G(f), f = D(h), h = G(h); + return hf.A(b, a, c, d, e, f, h); +}; +hf.F = 6; +function jf(a, b) { + this.T = a; + this.j = b; +} +function kf(a) { + return new jf(a, [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]); +} +function lf(a) { + return new jf(a.T, vb(a.j)); +} +function mf(a) { + a = a.o; + return 32 > a ? 0 : a - 1 >>> 5 << 5; +} +function nf(a, b, c) { + for (;;) { + if (0 === b) { + return c; + } + var d = kf(a); + d.j[0] = c; + c = d; + b -= 5; + } +} +var of = function of(b, c, d, e) { + var f = lf(d), h = b.o - 1 >>> c & 31; + 5 === c ? f.j[h] = e : (d = d.j[h], b = null != d ? of(b, c - 5, d, e) : nf(null, c - 5, e), f.j[h] = b); + return f; +}; +function pf(a, b) { + throw Error([w("No item "), w(a), w(" in vector of length "), w(b)].join("")); +} +function qf(a, b) { + if (b >= mf(a)) { + return a.I; + } + for (var c = a.root, d = a.shift;;) { + if (0 < d) { + var e = d - 5, c = c.j[b >>> d & 31], d = e + } else { + return c.j; + } + } +} +function rf(a, b) { + return 0 <= b && b < a.o ? qf(a, b) : pf(b, a.o); +} +var sf = function sf(b, c, d, e, f) { + var h = lf(d); + if (0 === c) { + h.j[e & 31] = f; + } else { + var k = e >>> c & 31; + b = sf(b, c - 5, d.j[k], e, f); + h.j[k] = b; + } + return h; +}, tf = function tf(b, c, d) { + var e = b.o - 2 >>> c & 31; + if (5 < c) { + b = tf(b, c - 5, d.j[e]); + if (null == b && 0 === e) { + return null; + } + d = lf(d); + d.j[e] = b; + return d; + } + if (0 === e) { + return null; + } + d = lf(d); + d.j[e] = null; + return d; +}; +function uf(a, b, c, d, e, f) { + this.i = a; + this.base = b; + this.j = c; + this.wa = d; + this.start = e; + this.end = f; +} +uf.prototype.ea = function() { + return this.i < this.end; +}; +uf.prototype.next = function() { + 32 === this.i - this.base && (this.j = qf(this.wa, this.i), this.base += 32); + var a = this.j[this.i & 31]; + this.i += 1; + return a; +}; +function V(a, b, c, d, e, f) { + this.meta = a; + this.o = b; + this.shift = c; + this.root = d; + this.I = e; + this.v = f; + this.m = 167668511; + this.C = 8196; +} +g = V.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return "number" === typeof b ? y.h(this, b, c) : c; +}; +g.K = function(a, b) { + return rf(this, b)[b & 31]; +}; +g.sa = function(a, b, c) { + return 0 <= b && b < this.o ? qf(this, b)[b & 31] : c; +}; +g.Ic = function(a, b, c) { + if (0 <= b && b < this.o) { + return mf(this) <= b ? (a = vb(this.I), a[b & 31] = c, new V(this.meta, this.o, this.shift, this.root, a, null)) : new V(this.meta, this.o, this.shift, sf(this, this.shift, this.root, b, c), this.I, null); + } + if (b === this.o) { + return Lb(this, c); + } + throw Error([w("Index "), w(b), w(" out of bounds [0,"), w(this.o), w("]")].join("")); +}; +g.Da = function() { + var a = this.o; + return new uf(0, 0, 0 < K(this) ? qf(this, 0) : null, this, 0, a); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new V(this.meta, this.o, this.shift, this.root, this.I, this.v); +}; +g.Y = function() { + return this.o; +}; +g.Gc = function() { + return y.f(this, 0); +}; +g.Hc = function() { + return y.f(this, 1); +}; +g.ob = function() { + return 0 < this.o ? y.f(this, this.o - 1) : null; +}; +g.pb = function() { + if (0 === this.o) { + throw Error("Can't pop empty vector"); + } + if (1 === this.o) { + return kc(zd, this.meta); + } + if (1 < this.o - mf(this)) { + return new V(this.meta, this.o - 1, this.shift, this.root, this.I.slice(0, -1), null); + } + var a = qf(this, this.o - 2), b = tf(this, this.shift, this.root), b = null == b ? W : b, c = this.o - 1; + return 5 < this.shift && null == b.j[1] ? new V(this.meta, c, this.shift - 5, b.j[0], a, null) : new V(this.meta, c, this.shift, b, a, null); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + if (b instanceof V) { + if (this.o === K(b)) { + for (var c = Lc(this), d = Lc(b);;) { + if (q(c.ea())) { + var e = c.next(), f = d.next(); + if (!H.f(e, f)) { + return !1; + } + } else { + return !0; + } + } + } else { + return !1; + } + } else { + return vd(this, b); + } +}; +g.Db = function() { + return new vf(this.o, this.shift, wf.c ? wf.c(this.root) : wf.call(null, this.root), xf.c ? xf.c(this.I) : xf.call(null, this.I)); +}; +g.Z = function() { + return Id(zd, this.meta); +}; +g.fa = function(a, b) { + return ld(this, b); +}; +g.ga = function(a, b, c) { + a = 0; + for (var d = c;;) { + if (a < this.o) { + var e = qf(this, a); + c = e.length; + a: { + for (var f = 0;;) { + if (f < c) { + var h = e[f], d = b.f ? b.f(d, h) : b.call(null, d, h), f = f + 1 + } else { + e = d; + break a; + } + } + } + a += c; + d = e; + } else { + return d; + } + } +}; +g.nb = function(a, b, c) { + if ("number" === typeof b) { + return fc(this, b, c); + } + throw Error("Vector's key for assoc must be a number."); +}; +g.X = function() { + if (0 === this.o) { + return null; + } + if (32 >= this.o) { + return new C(this.I, 0, null); + } + var a; + a: { + a = this.root; + for (var b = this.shift;;) { + if (0 < b) { + b -= 5, a = a.j[0]; + } else { + a = a.j; + break a; + } + } + } + return yf ? yf(this, a, 0, 0) : zf.call(null, this, a, 0, 0); +}; +g.P = function(a, b) { + return new V(b, this.o, this.shift, this.root, this.I, this.v); +}; +g.W = function(a, b) { + if (32 > this.o - mf(this)) { + for (var c = this.I.length, d = Array(c + 1), e = 0;;) { + if (e < c) { + d[e] = this.I[e], e += 1; + } else { + break; + } + } + d[c] = b; + return new V(this.meta, this.o + 1, this.shift, this.root, d, null); + } + c = (d = this.o >>> 5 > 1 << this.shift) ? this.shift + 5 : this.shift; + d ? (d = kf(null), d.j[0] = this.root, e = nf(null, this.shift, new jf(null, this.I)), d.j[1] = e) : d = of(this, this.shift, this.root, new jf(null, this.I)); + return new V(this.meta, this.o + 1, c, d, [b], null); +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.K(null, c); + case 3: + return this.sa(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.K(null, c); + }; + a.h = function(a, c, d) { + return this.sa(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.K(null, a); +}; +g.f = function(a, b) { + return this.sa(null, a, b); +}; +var W = new jf(null, [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]), zd = new V(null, 0, 5, W, [], gd); +V.prototype[ub] = function() { + return dd(this); +}; +function Af(a) { + if (pb(a)) { + a: { + var b = a.length; + if (32 > b) { + a = new V(null, b, 5, W, a, null); + } else { + for (var c = 32, d = (new V(null, 32, 5, W, a.slice(0, 32), null)).Db(null);;) { + if (c < b) { + var e = c + 1, d = ze.f(d, a[c]), c = e + } else { + a = Bc(d); + break a; + } + } + } + } + } else { + a = Bc(zb(Ac, zc(zd), a)); + } + return a; +} +function Bf(a, b, c, d, e, f) { + this.ta = a; + this.node = b; + this.i = c; + this.ca = d; + this.meta = e; + this.v = f; + this.m = 32375020; + this.C = 1536; +} +g = Bf.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.ma = function() { + if (this.ca + 1 < this.node.length) { + var a; + a = this.ta; + var b = this.node, c = this.i, d = this.ca + 1; + a = yf ? yf(a, b, c, d) : zf.call(null, a, b, c, d); + return null == a ? null : a; + } + return Hc(this); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(zd, this.meta); +}; +g.fa = function(a, b) { + var c; + c = this.ta; + var d = this.i + this.ca, e = K(this.ta); + c = Cf ? Cf(c, d, e) : Df.call(null, c, d, e); + return ld(c, b); +}; +g.ga = function(a, b, c) { + a = this.ta; + var d = this.i + this.ca, e = K(this.ta); + a = Cf ? Cf(a, d, e) : Df.call(null, a, d, e); + return md(a, b, c); +}; +g.ba = function() { + return this.node[this.ca]; +}; +g.ia = function() { + if (this.ca + 1 < this.node.length) { + var a; + a = this.ta; + var b = this.node, c = this.i, d = this.ca + 1; + a = yf ? yf(a, b, c, d) : zf.call(null, a, b, c, d); + return null == a ? bd : a; + } + return Gc(this); +}; +g.X = function() { + return this; +}; +g.Ec = function() { + var a = this.node; + return new re(a, this.ca, a.length); +}; +g.Fc = function() { + var a = this.i + this.node.length; + if (a < Gb(this.ta)) { + var b = this.ta, c = qf(this.ta, a); + return yf ? yf(b, c, a, 0) : zf.call(null, b, c, a, 0); + } + return bd; +}; +g.P = function(a, b) { + return Ef ? Ef(this.ta, this.node, this.i, this.ca, b) : zf.call(null, this.ta, this.node, this.i, this.ca, b); +}; +g.W = function(a, b) { + return N(b, this); +}; +g.Dc = function() { + var a = this.i + this.node.length; + if (a < Gb(this.ta)) { + var b = this.ta, c = qf(this.ta, a); + return yf ? yf(b, c, a, 0) : zf.call(null, b, c, a, 0); + } + return null; +}; +Bf.prototype[ub] = function() { + return dd(this); +}; +function zf(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 3: + return b = arguments[0], c = arguments[1], d = arguments[2], new Bf(b, rf(b, c), c, d, null, null); + case 4: + return yf(arguments[0], arguments[1], arguments[2], arguments[3]); + case 5: + return Ef(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function yf(a, b, c, d) { + return new Bf(a, b, c, d, null, null); +} +function Ef(a, b, c, d, e) { + return new Bf(a, b, c, d, e, null); +} +function Ff(a, b, c, d, e) { + this.meta = a; + this.wa = b; + this.start = c; + this.end = d; + this.v = e; + this.m = 167666463; + this.C = 8192; +} +g = Ff.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return "number" === typeof b ? y.h(this, b, c) : c; +}; +g.K = function(a, b) { + return 0 > b || this.end <= this.start + b ? pf(b, this.end - this.start) : y.f(this.wa, this.start + b); +}; +g.sa = function(a, b, c) { + return 0 > b || this.end <= this.start + b ? c : y.h(this.wa, this.start + b, c); +}; +g.Ic = function(a, b, c) { + var d = this.start + b; + a = this.meta; + c = S.h(this.wa, d, c); + b = this.start; + var e = this.end, d = d + 1, d = e > d ? e : d; + return Gf.N ? Gf.N(a, c, b, d, null) : Gf.call(null, a, c, b, d, null); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new Ff(this.meta, this.wa, this.start, this.end, this.v); +}; +g.Y = function() { + return this.end - this.start; +}; +g.ob = function() { + return y.f(this.wa, this.end - 1); +}; +g.pb = function() { + if (this.start === this.end) { + throw Error("Can't pop empty vector"); + } + var a = this.meta, b = this.wa, c = this.start, d = this.end - 1; + return Gf.N ? Gf.N(a, b, c, d, null) : Gf.call(null, a, b, c, d, null); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(zd, this.meta); +}; +g.fa = function(a, b) { + return ld(this, b); +}; +g.ga = function(a, b, c) { + return md(this, b, c); +}; +g.nb = function(a, b, c) { + if ("number" === typeof b) { + return fc(this, b, c); + } + throw Error("Subvec's key for assoc must be a number."); +}; +g.X = function() { + var a = this; + return function(b) { + return function d(e) { + return e === a.end ? null : N(y.f(a.wa, e), new oe(null, function() { + return function() { + return d(e + 1); + }; + }(b), null, null)); + }; + }(this)(a.start); +}; +g.P = function(a, b) { + return Gf.N ? Gf.N(b, this.wa, this.start, this.end, this.v) : Gf.call(null, b, this.wa, this.start, this.end, this.v); +}; +g.W = function(a, b) { + var c = this.meta, d = fc(this.wa, this.end, b), e = this.start, f = this.end + 1; + return Gf.N ? Gf.N(c, d, e, f, null) : Gf.call(null, c, d, e, f, null); +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.K(null, c); + case 3: + return this.sa(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.K(null, c); + }; + a.h = function(a, c, d) { + return this.sa(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.K(null, a); +}; +g.f = function(a, b) { + return this.sa(null, a, b); +}; +Ff.prototype[ub] = function() { + return dd(this); +}; +function Gf(a, b, c, d, e) { + for (;;) { + if (b instanceof Ff) { + c = b.start + c, d = b.start + d, b = b.wa; + } else { + var f = K(b); + if (0 > c || 0 > d || c > f || d > f) { + throw Error("Index out of bounds"); + } + return new Ff(a, b, c, d, e); + } + } +} +function Df(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 2: + return b = arguments[0], Cf(b, arguments[1], K(b)); + case 3: + return Cf(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function Cf(a, b, c) { + return Gf(null, a, b, c, null); +} +function Hf(a, b) { + return a === b.T ? b : new jf(a, vb(b.j)); +} +function wf(a) { + return new jf({}, vb(a.j)); +} +function xf(a) { + var b = [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; + Sd(a, 0, b, 0, a.length); + return b; +} +var If = function If(b, c, d, e) { + d = Hf(b.root.T, d); + var f = b.o - 1 >>> c & 31; + if (5 === c) { + b = e; + } else { + var h = d.j[f]; + b = null != h ? If(b, c - 5, h, e) : nf(b.root.T, c - 5, e); + } + d.j[f] = b; + return d; +}; +function vf(a, b, c, d) { + this.o = a; + this.shift = b; + this.root = c; + this.I = d; + this.C = 88; + this.m = 275; +} +g = vf.prototype; +g.Tb = function(a, b) { + if (this.root.T) { + if (32 > this.o - mf(this)) { + this.I[this.o & 31] = b; + } else { + var c = new jf(this.root.T, this.I), d = [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; + d[0] = b; + this.I = d; + if (this.o >>> 5 > 1 << this.shift) { + var d = [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], e = this.shift + 5; + d[0] = this.root; + d[1] = nf(this.root.T, this.shift, c); + this.root = new jf(this.root.T, d); + this.shift = e; + } else { + this.root = If(this, this.shift, this.root, c); + } + } + this.o += 1; + return this; + } + throw Error("conj! after persistent!"); +}; +g.Ub = function() { + if (this.root.T) { + this.root.T = null; + var a = this.o - mf(this), b = Array(a); + Sd(this.I, 0, b, 0, a); + return new V(null, this.o, this.shift, this.root, b, null); + } + throw Error("persistent! called twice"); +}; +g.Sb = function(a, b, c) { + if ("number" === typeof b) { + return Dc(this, b, c); + } + throw Error("TransientVector's key for assoc! must be a number."); +}; +g.kd = function(a, b, c) { + var d = this; + if (d.root.T) { + if (0 <= b && b < d.o) { + return mf(this) <= b ? d.I[b & 31] = c : (a = function() { + return function f(a, k) { + var l = Hf(d.root.T, k); + if (0 === a) { + l.j[b & 31] = c; + } else { + var m = b >>> a & 31, p = f(a - 5, l.j[m]); + l.j[m] = p; + } + return l; + }; + }(this).call(null, d.shift, d.root), d.root = a), this; + } + if (b === d.o) { + return Ac(this, c); + } + throw Error([w("Index "), w(b), w(" out of bounds for TransientVector of length"), w(d.o)].join("")); + } + throw Error("assoc! after persistent!"); +}; +g.Y = function() { + if (this.root.T) { + return this.o; + } + throw Error("count after persistent!"); +}; +g.K = function(a, b) { + if (this.root.T) { + return rf(this, b)[b & 31]; + } + throw Error("nth after persistent!"); +}; +g.sa = function(a, b, c) { + return 0 <= b && b < this.o ? y.f(this, b) : c; +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return "number" === typeof b ? y.h(this, b, c) : c; +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +function Jf(a, b) { + this.Ib = a; + this.gc = b; +} +Jf.prototype.ea = function() { + var a = null != this.Ib && B(this.Ib); + return a ? a : (a = null != this.gc) ? this.gc.ea() : a; +}; +Jf.prototype.next = function() { + if (null != this.Ib) { + var a = D(this.Ib); + this.Ib = G(this.Ib); + return a; + } + if (null != this.gc && this.gc.ea()) { + return this.gc.next(); + } + throw Error("No such element"); +}; +Jf.prototype.remove = function() { + return Error("Unsupported operation"); +}; +function Lf(a, b, c, d) { + this.meta = a; + this.oa = b; + this.Ca = c; + this.v = d; + this.m = 31850572; + this.C = 0; +} +g = Lf.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.ba = function() { + return D(this.oa); +}; +g.ia = function() { + var a = G(this.oa); + return a ? new Lf(this.meta, a, this.Ca, null) : null == this.Ca ? Hb(this) : new Lf(this.meta, this.Ca, null, null); +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new Lf(b, this.oa, this.Ca, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +Lf.prototype[ub] = function() { + return dd(this); +}; +function Mf(a, b, c, d, e) { + this.meta = a; + this.count = b; + this.oa = c; + this.Ca = d; + this.v = e; + this.m = 31858766; + this.C = 8192; +} +g = Mf.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, this.count.c ? this.count.c(this) : this.count.call(null, this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.Da = function() { + return new Jf(this.oa, Lc(this.Ca)); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new Mf(this.meta, this.count, this.oa, this.Ca, this.v); +}; +g.Y = function() { + return this.count; +}; +g.ob = function() { + return D(this.oa); +}; +g.pb = function() { + if (q(this.oa)) { + var a = G(this.oa); + return a ? new Mf(this.meta, this.count - 1, a, this.Ca, null) : new Mf(this.meta, this.count - 1, B(this.Ca), zd, null); + } + return this; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(Nf, this.meta); +}; +g.ba = function() { + return D(this.oa); +}; +g.ia = function() { + return $c(B(this)); +}; +g.X = function() { + var a = B(this.Ca), b = this.oa; + return q(q(b) ? b : a) ? new Lf(null, this.oa, B(a), null) : null; +}; +g.P = function(a, b) { + return new Mf(b, this.count, this.oa, this.Ca, this.v); +}; +g.W = function(a, b) { + var c; + q(this.oa) ? (c = this.Ca, c = new Mf(this.meta, this.count + 1, this.oa, xd.f(q(c) ? c : zd, b), null)) : c = new Mf(this.meta, this.count + 1, xd.f(this.oa, b), zd, null); + return c; +}; +var Nf = new Mf(null, 0, null, zd, gd); +Mf.prototype[ub] = function() { + return dd(this); +}; +function Of() { + this.m = 2097152; + this.C = 0; +} +Of.prototype.equiv = function(a) { + return this.B(null, a); +}; +Of.prototype.B = function() { + return !1; +}; +var Pf = new Of; +function Qf(a, b) { + return Vd(Od(b) ? K(a) === K(b) ? Oe(function(a) { + return H.f(z.h(b, D(a), Pf), D(G(a))); + }, a) : null : null); +} +function Rf(a) { + this.s = a; +} +Rf.prototype.next = function() { + if (null != this.s) { + var a = D(this.s), b = P(a, 0, null), a = P(a, 1, null); + this.s = G(this.s); + return {value:[b, a], done:!1}; + } + return {value:null, done:!0}; +}; +function Sf(a) { + this.s = a; +} +Sf.prototype.next = function() { + if (null != this.s) { + var a = D(this.s); + this.s = G(this.s); + return {value:[a, a], done:!1}; + } + return {value:null, done:!0}; +}; +function Tf(a, b) { + var c; + if (b instanceof T) { + a: { + c = a.length; + for (var d = b.Ia, e = 0;;) { + if (c <= e) { + c = -1; + break a; + } + if (a[e] instanceof T && d === a[e].Ia) { + c = e; + break a; + } + e += 2; + } + } + } else { + if (ca(b) || "number" === typeof b) { + a: { + for (c = a.length, d = 0;;) { + if (c <= d) { + c = -1; + break a; + } + if (b === a[d]) { + c = d; + break a; + } + d += 2; + } + } + } else { + if (b instanceof Yc) { + a: { + for (c = a.length, d = b.mb, e = 0;;) { + if (c <= e) { + c = -1; + break a; + } + if (a[e] instanceof Yc && d === a[e].mb) { + c = e; + break a; + } + e += 2; + } + } + } else { + if (null == b) { + a: { + for (c = a.length, d = 0;;) { + if (c <= d) { + c = -1; + break a; + } + if (null == a[d]) { + c = d; + break a; + } + d += 2; + } + } + } else { + a: { + for (c = a.length, d = 0;;) { + if (c <= d) { + c = -1; + break a; + } + if (H.f(b, a[d])) { + c = d; + break a; + } + d += 2; + } + } + } + } + } + } + return c; +} +function Uf(a, b, c) { + this.j = a; + this.i = b; + this.la = c; + this.m = 32374990; + this.C = 0; +} +g = Uf.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.la; +}; +g.ma = function() { + return this.i < this.j.length - 2 ? new Uf(this.j, this.i + 2, this.la) : null; +}; +g.Y = function() { + return (this.j.length - this.i) / 2; +}; +g.U = function() { + return fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.la); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return new V(null, 2, 5, W, [this.j[this.i], this.j[this.i + 1]], null); +}; +g.ia = function() { + return this.i < this.j.length - 2 ? new Uf(this.j, this.i + 2, this.la) : bd; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new Uf(this.j, this.i, b); +}; +g.W = function(a, b) { + return N(b, this); +}; +Uf.prototype[ub] = function() { + return dd(this); +}; +function Vf(a, b, c) { + this.j = a; + this.i = b; + this.o = c; +} +Vf.prototype.ea = function() { + return this.i < this.o; +}; +Vf.prototype.next = function() { + var a = new V(null, 2, 5, W, [this.j[this.i], this.j[this.i + 1]], null); + this.i += 2; + return a; +}; +function ib(a, b, c, d) { + this.meta = a; + this.o = b; + this.j = c; + this.v = d; + this.m = 16647951; + this.C = 8196; +} +g = ib.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.keys = function() { + return dd(Wf.c ? Wf.c(this) : Wf.call(null, this)); +}; +g.entries = function() { + return new Rf(B(B(this))); +}; +g.values = function() { + return dd(Xf.c ? Xf.c(this) : Xf.call(null, this)); +}; +g.has = function(a) { + return Xd(this, a); +}; +g.get = function(a, b) { + return this.J(null, a, b); +}; +g.forEach = function(a) { + for (var b = B(this), c = null, d = 0, e = 0;;) { + if (e < d) { + var f = c.K(null, e), h = P(f, 0, null), f = P(f, 1, null); + a.f ? a.f(f, h) : a.call(null, f, h); + e += 1; + } else { + if (b = B(b)) { + Qd(b) ? (c = Fc(b), b = Gc(b), h = c, d = K(c), c = h) : (c = D(b), h = P(c, 0, null), f = P(c, 1, null), a.f ? a.f(f, h) : a.call(null, f, h), b = G(b), c = null, d = 0), e = 0; + } else { + return null; + } + } + } +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + a = Tf(this.j, b); + return -1 === a ? c : this.j[a + 1]; +}; +g.Da = function() { + return new Vf(this.j, 0, 2 * this.o); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new ib(this.meta, this.o, this.j, this.v); +}; +g.Y = function() { + return this.o; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = hd(this); +}; +g.B = function(a, b) { + if (null != b && (b.m & 1024 || b.se)) { + var c = this.j.length; + if (this.o === b.Y(null)) { + for (var d = 0;;) { + if (d < c) { + var e = b.J(null, this.j[d], Td); + if (e !== Td) { + if (H.f(this.j[d + 1], e)) { + d += 2; + } else { + return !1; + } + } else { + return !1; + } + } else { + return !0; + } + } + } else { + return !1; + } + } else { + return Qf(this, b); + } +}; +g.Db = function() { + return new Yf({}, this.j.length, vb(this.j)); +}; +g.Z = function() { + return kc(Ne, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.mc = function(a, b) { + if (0 <= Tf(this.j, b)) { + var c = this.j.length, d = c - 2; + if (0 === d) { + return Hb(this); + } + for (var d = Array(d), e = 0, f = 0;;) { + if (e >= c) { + return new ib(this.meta, this.o - 1, d, null); + } + H.f(b, this.j[e]) || (d[f] = this.j[e], d[f + 1] = this.j[e + 1], f += 2); + e += 2; + } + } else { + return this; + } +}; +g.nb = function(a, b, c) { + a = Tf(this.j, b); + if (-1 === a) { + if (this.o < Zf) { + a = this.j; + for (var d = a.length, e = Array(d + 2), f = 0;;) { + if (f < d) { + e[f] = a[f], f += 1; + } else { + break; + } + } + e[d] = b; + e[d + 1] = c; + return new ib(this.meta, this.o + 1, e, null); + } + return kc(Ub(df($f, this), b, c), this.meta); + } + if (c === this.j[a + 1]) { + return this; + } + b = vb(this.j); + b[a + 1] = c; + return new ib(this.meta, this.o, b, null); +}; +g.Rb = function(a, b) { + return -1 !== Tf(this.j, b); +}; +g.X = function() { + var a = this.j; + return 0 <= a.length - 2 ? new Uf(a, 0, null) : null; +}; +g.P = function(a, b) { + return new ib(b, this.o, this.j, this.v); +}; +g.W = function(a, b) { + if (Pd(b)) { + return Ub(this, y.f(b, 0), y.f(b, 1)); + } + for (var c = this, d = B(b);;) { + if (null == d) { + return c; + } + var e = D(d); + if (Pd(e)) { + c = Ub(c, y.f(e, 0), y.f(e, 1)), d = G(d); + } else { + throw Error("conj on a map takes map entries or seqables of map entries"); + } + } +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +var Ne = new ib(null, 0, [], id), Zf = 8; +function ag(a, b) { + var c; + if (b) { + c = a; + } else { + c = []; + for (var d = 0;;) { + if (d < a.length) { + var e = a[d], f = a[d + 1]; + -1 === Tf(c, e) && (c.push(e), c.push(f)); + d += 2; + } else { + break; + } + } + } + return new ib(null, c.length / 2, c, null); +} +ib.prototype[ub] = function() { + return dd(this); +}; +function Yf(a, b, c) { + this.Fb = a; + this.ub = b; + this.j = c; + this.m = 258; + this.C = 56; +} +g = Yf.prototype; +g.Y = function() { + if (q(this.Fb)) { + return ce(this.ub); + } + throw Error("count after persistent!"); +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + if (q(this.Fb)) { + return a = Tf(this.j, b), -1 === a ? c : this.j[a + 1]; + } + throw Error("lookup after persistent!"); +}; +g.Tb = function(a, b) { + if (q(this.Fb)) { + if (null != b ? b.m & 2048 || b.te || (b.m ? 0 : t(Xb, b)) : t(Xb, b)) { + return Cc(this, bg.c ? bg.c(b) : bg.call(null, b), cg.c ? cg.c(b) : cg.call(null, b)); + } + for (var c = B(b), d = this;;) { + var e = D(c); + if (q(e)) { + c = G(c), d = Cc(d, bg.c ? bg.c(e) : bg.call(null, e), cg.c ? cg.c(e) : cg.call(null, e)); + } else { + return d; + } + } + } else { + throw Error("conj! after persistent!"); + } +}; +g.Ub = function() { + if (q(this.Fb)) { + return this.Fb = !1, new ib(null, ce(this.ub), this.j, null); + } + throw Error("persistent! called twice"); +}; +g.Sb = function(a, b, c) { + if (q(this.Fb)) { + a = Tf(this.j, b); + if (-1 === a) { + if (this.ub + 2 <= 2 * Zf) { + return this.ub += 2, this.j.push(b), this.j.push(c), this; + } + a = dg.f ? dg.f(this.ub, this.j) : dg.call(null, this.ub, this.j); + return Cc(a, b, c); + } + c !== this.j[a + 1] && (this.j[a + 1] = c); + return this; + } + throw Error("assoc! after persistent!"); +}; +function dg(a, b) { + for (var c = zc($f), d = 0;;) { + if (d < a) { + c = Cc(c, b[d], b[d + 1]), d += 2; + } else { + return c; + } + } +} +function eg() { + this.ka = !1; +} +function fg(a, b) { + return a === b ? !0 : le(a, b) ? !0 : H.f(a, b); +} +function gg(a, b, c) { + a = vb(a); + a[b] = c; + return a; +} +function hg(a, b) { + var c = Array(a.length - 2); + Sd(a, 0, c, 0, 2 * b); + Sd(a, 2 * (b + 1), c, 2 * b, c.length - 2 * b); + return c; +} +function ig(a, b, c, d) { + a = a.rb(b); + a.j[c] = d; + return a; +} +function jg(a, b, c, d) { + this.j = a; + this.i = b; + this.ec = c; + this.Ga = d; +} +jg.prototype.advance = function() { + for (var a = this.j.length;;) { + if (this.i < a) { + var b = this.j[this.i], c = this.j[this.i + 1]; + null != b ? b = this.ec = new V(null, 2, 5, W, [b, c], null) : null != c ? (b = Lc(c), b = b.ea() ? this.Ga = b : !1) : b = !1; + this.i += 2; + if (b) { + return !0; + } + } else { + return !1; + } + } +}; +jg.prototype.ea = function() { + var a = null != this.ec; + return a ? a : (a = null != this.Ga) ? a : this.advance(); +}; +jg.prototype.next = function() { + if (null != this.ec) { + var a = this.ec; + this.ec = null; + return a; + } + if (null != this.Ga) { + return a = this.Ga.next(), this.Ga.ea() || (this.Ga = null), a; + } + if (this.advance()) { + return this.next(); + } + throw Error("No such element"); +}; +jg.prototype.remove = function() { + return Error("Unsupported operation"); +}; +function kg(a, b, c) { + this.T = a; + this.V = b; + this.j = c; +} +g = kg.prototype; +g.rb = function(a) { + if (a === this.T) { + return this; + } + var b = de(this.V), c = Array(0 > b ? 4 : 2 * (b + 1)); + Sd(this.j, 0, c, 0, 2 * b); + return new kg(a, this.V, c); +}; +g.Zb = function() { + return lg ? lg(this.j) : mg.call(null, this.j); +}; +g.jb = function(a, b, c, d) { + var e = 1 << (b >>> a & 31); + if (0 === (this.V & e)) { + return d; + } + var f = de(this.V & e - 1), e = this.j[2 * f], f = this.j[2 * f + 1]; + return null == e ? f.jb(a + 5, b, c, d) : fg(c, e) ? f : d; +}; +g.Fa = function(a, b, c, d, e, f) { + var h = 1 << (c >>> b & 31), k = de(this.V & h - 1); + if (0 === (this.V & h)) { + var l = de(this.V); + if (2 * l < this.j.length) { + a = this.rb(a); + b = a.j; + f.ka = !0; + a: { + for (c = 2 * (l - k), f = 2 * k + (c - 1), l = 2 * (k + 1) + (c - 1);;) { + if (0 === c) { + break a; + } + b[l] = b[f]; + --l; + --c; + --f; + } + } + b[2 * k] = d; + b[2 * k + 1] = e; + a.V |= h; + return a; + } + if (16 <= l) { + k = [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; + k[c >>> b & 31] = ng.Fa(a, b + 5, c, d, e, f); + for (e = d = 0;;) { + if (32 > d) { + 0 !== (this.V >>> d & 1) && (k[d] = null != this.j[e] ? ng.Fa(a, b + 5, Wc(this.j[e]), this.j[e], this.j[e + 1], f) : this.j[e + 1], e += 2), d += 1; + } else { + break; + } + } + return new og(a, l + 1, k); + } + b = Array(2 * (l + 4)); + Sd(this.j, 0, b, 0, 2 * k); + b[2 * k] = d; + b[2 * k + 1] = e; + Sd(this.j, 2 * k, b, 2 * (k + 1), 2 * (l - k)); + f.ka = !0; + a = this.rb(a); + a.j = b; + a.V |= h; + return a; + } + l = this.j[2 * k]; + h = this.j[2 * k + 1]; + if (null == l) { + return l = h.Fa(a, b + 5, c, d, e, f), l === h ? this : ig(this, a, 2 * k + 1, l); + } + if (fg(d, l)) { + return e === h ? this : ig(this, a, 2 * k + 1, e); + } + f.ka = !0; + f = b + 5; + d = pg ? pg(a, f, l, h, c, d, e) : qg.call(null, a, f, l, h, c, d, e); + e = 2 * k; + k = 2 * k + 1; + a = this.rb(a); + a.j[e] = null; + a.j[k] = d; + return a; +}; +g.Ea = function(a, b, c, d, e) { + var f = 1 << (b >>> a & 31), h = de(this.V & f - 1); + if (0 === (this.V & f)) { + var k = de(this.V); + if (16 <= k) { + h = [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null]; + h[b >>> a & 31] = ng.Ea(a + 5, b, c, d, e); + for (d = c = 0;;) { + if (32 > c) { + 0 !== (this.V >>> c & 1) && (h[c] = null != this.j[d] ? ng.Ea(a + 5, Wc(this.j[d]), this.j[d], this.j[d + 1], e) : this.j[d + 1], d += 2), c += 1; + } else { + break; + } + } + return new og(null, k + 1, h); + } + a = Array(2 * (k + 1)); + Sd(this.j, 0, a, 0, 2 * h); + a[2 * h] = c; + a[2 * h + 1] = d; + Sd(this.j, 2 * h, a, 2 * (h + 1), 2 * (k - h)); + e.ka = !0; + return new kg(null, this.V | f, a); + } + var l = this.j[2 * h], f = this.j[2 * h + 1]; + if (null == l) { + return k = f.Ea(a + 5, b, c, d, e), k === f ? this : new kg(null, this.V, gg(this.j, 2 * h + 1, k)); + } + if (fg(c, l)) { + return d === f ? this : new kg(null, this.V, gg(this.j, 2 * h + 1, d)); + } + e.ka = !0; + e = this.V; + k = this.j; + a += 5; + a = rg ? rg(a, l, f, b, c, d) : qg.call(null, a, l, f, b, c, d); + c = 2 * h; + h = 2 * h + 1; + d = vb(k); + d[c] = null; + d[h] = a; + return new kg(null, e, d); +}; +g.$b = function(a, b, c) { + var d = 1 << (b >>> a & 31); + if (0 === (this.V & d)) { + return this; + } + var e = de(this.V & d - 1), f = this.j[2 * e], h = this.j[2 * e + 1]; + return null == f ? (a = h.$b(a + 5, b, c), a === h ? this : null != a ? new kg(null, this.V, gg(this.j, 2 * e + 1, a)) : this.V === d ? null : new kg(null, this.V ^ d, hg(this.j, e))) : fg(c, f) ? new kg(null, this.V ^ d, hg(this.j, e)) : this; +}; +g.Da = function() { + return new jg(this.j, 0, null, null); +}; +var ng = new kg(null, 0, []); +function sg(a, b, c) { + this.j = a; + this.i = b; + this.Ga = c; +} +sg.prototype.ea = function() { + for (var a = this.j.length;;) { + if (null != this.Ga && this.Ga.ea()) { + return !0; + } + if (this.i < a) { + var b = this.j[this.i]; + this.i += 1; + null != b && (this.Ga = Lc(b)); + } else { + return !1; + } + } +}; +sg.prototype.next = function() { + if (this.ea()) { + return this.Ga.next(); + } + throw Error("No such element"); +}; +sg.prototype.remove = function() { + return Error("Unsupported operation"); +}; +function og(a, b, c) { + this.T = a; + this.o = b; + this.j = c; +} +g = og.prototype; +g.rb = function(a) { + return a === this.T ? this : new og(a, this.o, vb(this.j)); +}; +g.Zb = function() { + return tg ? tg(this.j) : ug.call(null, this.j); +}; +g.jb = function(a, b, c, d) { + var e = this.j[b >>> a & 31]; + return null != e ? e.jb(a + 5, b, c, d) : d; +}; +g.Fa = function(a, b, c, d, e, f) { + var h = c >>> b & 31, k = this.j[h]; + if (null == k) { + return a = ig(this, a, h, ng.Fa(a, b + 5, c, d, e, f)), a.o += 1, a; + } + b = k.Fa(a, b + 5, c, d, e, f); + return b === k ? this : ig(this, a, h, b); +}; +g.Ea = function(a, b, c, d, e) { + var f = b >>> a & 31, h = this.j[f]; + if (null == h) { + return new og(null, this.o + 1, gg(this.j, f, ng.Ea(a + 5, b, c, d, e))); + } + a = h.Ea(a + 5, b, c, d, e); + return a === h ? this : new og(null, this.o, gg(this.j, f, a)); +}; +g.$b = function(a, b, c) { + var d = b >>> a & 31, e = this.j[d]; + if (null != e) { + a = e.$b(a + 5, b, c); + if (a === e) { + d = this; + } else { + if (null == a) { + if (8 >= this.o) { + a: { + e = this.j; + a = e.length; + b = Array(2 * (this.o - 1)); + c = 0; + for (var f = 1, h = 0;;) { + if (c < a) { + c !== d && null != e[c] && (b[f] = e[c], f += 2, h |= 1 << c), c += 1; + } else { + d = new kg(null, h, b); + break a; + } + } + } + } else { + d = new og(null, this.o - 1, gg(this.j, d, a)); + } + } else { + d = new og(null, this.o, gg(this.j, d, a)); + } + } + return d; + } + return this; +}; +g.Da = function() { + return new sg(this.j, 0, null); +}; +function vg(a, b, c) { + b *= 2; + for (var d = 0;;) { + if (d < b) { + if (fg(c, a[d])) { + return d; + } + d += 2; + } else { + return -1; + } + } +} +function wg(a, b, c, d) { + this.T = a; + this.$a = b; + this.o = c; + this.j = d; +} +g = wg.prototype; +g.rb = function(a) { + if (a === this.T) { + return this; + } + var b = Array(2 * (this.o + 1)); + Sd(this.j, 0, b, 0, 2 * this.o); + return new wg(a, this.$a, this.o, b); +}; +g.Zb = function() { + return lg ? lg(this.j) : mg.call(null, this.j); +}; +g.jb = function(a, b, c, d) { + a = vg(this.j, this.o, c); + return 0 > a ? d : fg(c, this.j[a]) ? this.j[a + 1] : d; +}; +g.Fa = function(a, b, c, d, e, f) { + if (c === this.$a) { + b = vg(this.j, this.o, d); + if (-1 === b) { + if (this.j.length > 2 * this.o) { + return b = 2 * this.o, c = 2 * this.o + 1, a = this.rb(a), a.j[b] = d, a.j[c] = e, f.ka = !0, a.o += 1, a; + } + c = this.j.length; + b = Array(c + 2); + Sd(this.j, 0, b, 0, c); + b[c] = d; + b[c + 1] = e; + f.ka = !0; + d = this.o + 1; + a === this.T ? (this.j = b, this.o = d, a = this) : a = new wg(this.T, this.$a, d, b); + return a; + } + return this.j[b + 1] === e ? this : ig(this, a, b + 1, e); + } + return (new kg(a, 1 << (this.$a >>> b & 31), [null, this, null, null])).Fa(a, b, c, d, e, f); +}; +g.Ea = function(a, b, c, d, e) { + return b === this.$a ? (a = vg(this.j, this.o, c), -1 === a ? (a = 2 * this.o, b = Array(a + 2), Sd(this.j, 0, b, 0, a), b[a] = c, b[a + 1] = d, e.ka = !0, new wg(null, this.$a, this.o + 1, b)) : H.f(this.j[a], d) ? this : new wg(null, this.$a, this.o, gg(this.j, a + 1, d))) : (new kg(null, 1 << (this.$a >>> a & 31), [null, this])).Ea(a, b, c, d, e); +}; +g.$b = function(a, b, c) { + a = vg(this.j, this.o, c); + return -1 === a ? this : 1 === this.o ? null : new wg(null, this.$a, this.o - 1, hg(this.j, ce(a))); +}; +g.Da = function() { + return new jg(this.j, 0, null, null); +}; +function qg(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 6: + return rg(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5]); + case 7: + return pg(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function rg(a, b, c, d, e, f) { + var h = Wc(b); + if (h === d) { + return new wg(null, h, 2, [b, c, e, f]); + } + var k = new eg; + return ng.Ea(a, h, b, c, k).Ea(a, d, e, f, k); +} +function pg(a, b, c, d, e, f, h) { + var k = Wc(c); + if (k === e) { + return new wg(null, k, 2, [c, d, f, h]); + } + var l = new eg; + return ng.Fa(a, b, k, c, d, l).Fa(a, b, e, f, h, l); +} +function xg(a, b, c, d, e) { + this.meta = a; + this.kb = b; + this.i = c; + this.s = d; + this.v = e; + this.m = 32374860; + this.C = 0; +} +g = xg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return null == this.s ? new V(null, 2, 5, W, [this.kb[this.i], this.kb[this.i + 1]], null) : D(this.s); +}; +g.ia = function() { + var a = this, b = null == a.s ? function() { + var b = a.kb, d = a.i + 2; + return yg ? yg(b, d, null) : mg.call(null, b, d, null); + }() : function() { + var b = a.kb, d = a.i, e = G(a.s); + return yg ? yg(b, d, e) : mg.call(null, b, d, e); + }(); + return null != b ? b : bd; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new xg(b, this.kb, this.i, this.s, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +xg.prototype[ub] = function() { + return dd(this); +}; +function mg(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return lg(arguments[0]); + case 3: + return yg(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function lg(a) { + return yg(a, 0, null); +} +function yg(a, b, c) { + if (null == c) { + for (c = a.length;;) { + if (b < c) { + if (null != a[b]) { + return new xg(null, a, b, null, null); + } + var d = a[b + 1]; + if (q(d) && (d = d.Zb(), q(d))) { + return new xg(null, a, b + 2, d, null); + } + b += 2; + } else { + return null; + } + } + } else { + return new xg(null, a, b, c, null); + } +} +function zg(a, b, c, d, e) { + this.meta = a; + this.kb = b; + this.i = c; + this.s = d; + this.v = e; + this.m = 32374860; + this.C = 0; +} +g = zg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.meta; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return D(this.s); +}; +g.ia = function() { + var a; + a = this.kb; + var b = this.i, c = G(this.s); + a = Ag ? Ag(null, a, b, c) : ug.call(null, null, a, b, c); + return null != a ? a : bd; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new zg(b, this.kb, this.i, this.s, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +zg.prototype[ub] = function() { + return dd(this); +}; +function ug(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return tg(arguments[0]); + case 4: + return Ag(arguments[0], arguments[1], arguments[2], arguments[3]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function tg(a) { + return Ag(null, a, 0, null); +} +function Ag(a, b, c, d) { + if (null == d) { + for (d = b.length;;) { + if (c < d) { + var e = b[c]; + if (q(e) && (e = e.Zb(), q(e))) { + return new zg(a, b, c + 1, e, null); + } + c += 1; + } else { + return null; + } + } + } else { + return new zg(a, b, c, d, null); + } +} +function Bg(a, b, c) { + this.ja = a; + this.Zd = b; + this.ad = c; +} +Bg.prototype.ea = function() { + return this.ad && this.Zd.ea(); +}; +Bg.prototype.next = function() { + if (this.ad) { + return this.Zd.next(); + } + this.ad = !0; + return this.ja; +}; +Bg.prototype.remove = function() { + return Error("Unsupported operation"); +}; +function Cg(a, b, c, d, e, f) { + this.meta = a; + this.o = b; + this.root = c; + this.ha = d; + this.ja = e; + this.v = f; + this.m = 16123663; + this.C = 8196; +} +g = Cg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.keys = function() { + return dd(Wf.c ? Wf.c(this) : Wf.call(null, this)); +}; +g.entries = function() { + return new Rf(B(B(this))); +}; +g.values = function() { + return dd(Xf.c ? Xf.c(this) : Xf.call(null, this)); +}; +g.has = function(a) { + return Xd(this, a); +}; +g.get = function(a, b) { + return this.J(null, a, b); +}; +g.forEach = function(a) { + for (var b = B(this), c = null, d = 0, e = 0;;) { + if (e < d) { + var f = c.K(null, e), h = P(f, 0, null), f = P(f, 1, null); + a.f ? a.f(f, h) : a.call(null, f, h); + e += 1; + } else { + if (b = B(b)) { + Qd(b) ? (c = Fc(b), b = Gc(b), h = c, d = K(c), c = h) : (c = D(b), h = P(c, 0, null), f = P(c, 1, null), a.f ? a.f(f, h) : a.call(null, f, h), b = G(b), c = null, d = 0), e = 0; + } else { + return null; + } + } + } +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return null == b ? this.ha ? this.ja : c : null == this.root ? c : this.root.jb(0, Wc(b), b, c); +}; +g.Da = function() { + var a = this.root ? Lc(this.root) : Je; + return this.ha ? new Bg(this.ja, a, !1) : a; +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new Cg(this.meta, this.o, this.root, this.ha, this.ja, this.v); +}; +g.Y = function() { + return this.o; +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = hd(this); +}; +g.B = function(a, b) { + return Qf(this, b); +}; +g.Db = function() { + return new Dg({}, this.root, this.o, this.ha, this.ja); +}; +g.Z = function() { + return kc($f, this.meta); +}; +g.mc = function(a, b) { + if (null == b) { + return this.ha ? new Cg(this.meta, this.o - 1, this.root, !1, null, null) : this; + } + if (null == this.root) { + return this; + } + var c = this.root.$b(0, Wc(b), b); + return c === this.root ? this : new Cg(this.meta, this.o - 1, c, this.ha, this.ja, null); +}; +g.nb = function(a, b, c) { + if (null == b) { + return this.ha && c === this.ja ? this : new Cg(this.meta, this.ha ? this.o : this.o + 1, this.root, !0, c, null); + } + a = new eg; + b = (null == this.root ? ng : this.root).Ea(0, Wc(b), b, c, a); + return b === this.root ? this : new Cg(this.meta, a.ka ? this.o + 1 : this.o, b, this.ha, this.ja, null); +}; +g.Rb = function(a, b) { + return null == b ? this.ha : null == this.root ? !1 : this.root.jb(0, Wc(b), b, Td) !== Td; +}; +g.X = function() { + if (0 < this.o) { + var a = null != this.root ? this.root.Zb() : null; + return this.ha ? N(new V(null, 2, 5, W, [null, this.ja], null), a) : a; + } + return null; +}; +g.P = function(a, b) { + return new Cg(b, this.o, this.root, this.ha, this.ja, this.v); +}; +g.W = function(a, b) { + if (Pd(b)) { + return Ub(this, y.f(b, 0), y.f(b, 1)); + } + for (var c = this, d = B(b);;) { + if (null == d) { + return c; + } + var e = D(d); + if (Pd(e)) { + c = Ub(c, y.f(e, 0), y.f(e, 1)), d = G(d); + } else { + throw Error("conj on a map takes map entries or seqables of map entries"); + } + } +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +var $f = new Cg(null, 0, null, !1, null, id); +function Cd(a, b) { + for (var c = a.length, d = 0, e = zc($f);;) { + if (d < c) { + var f = d + 1, e = e.Sb(null, a[d], b[d]), d = f + } else { + return Bc(e); + } + } +} +Cg.prototype[ub] = function() { + return dd(this); +}; +function Dg(a, b, c, d, e) { + this.T = a; + this.root = b; + this.count = c; + this.ha = d; + this.ja = e; + this.m = 258; + this.C = 56; +} +function Eg(a, b, c) { + if (a.T) { + if (null == b) { + a.ja !== c && (a.ja = c), a.ha || (a.count += 1, a.ha = !0); + } else { + var d = new eg; + b = (null == a.root ? ng : a.root).Fa(a.T, 0, Wc(b), b, c, d); + b !== a.root && (a.root = b); + d.ka && (a.count += 1); + } + return a; + } + throw Error("assoc! after persistent!"); +} +g = Dg.prototype; +g.Y = function() { + if (this.T) { + return this.count; + } + throw Error("count after persistent!"); +}; +g.O = function(a, b) { + return null == b ? this.ha ? this.ja : null : null == this.root ? null : this.root.jb(0, Wc(b), b); +}; +g.J = function(a, b, c) { + return null == b ? this.ha ? this.ja : c : null == this.root ? c : this.root.jb(0, Wc(b), b, c); +}; +g.Tb = function(a, b) { + var c; + a: { + if (this.T) { + if (null != b ? b.m & 2048 || b.te || (b.m ? 0 : t(Xb, b)) : t(Xb, b)) { + c = Eg(this, bg.c ? bg.c(b) : bg.call(null, b), cg.c ? cg.c(b) : cg.call(null, b)); + } else { + c = B(b); + for (var d = this;;) { + var e = D(c); + if (q(e)) { + c = G(c), d = Eg(d, bg.c ? bg.c(e) : bg.call(null, e), cg.c ? cg.c(e) : cg.call(null, e)); + } else { + c = d; + break a; + } + } + } + } else { + throw Error("conj! after persistent"); + } + } + return c; +}; +g.Ub = function() { + var a; + if (this.T) { + this.T = null, a = new Cg(null, this.count, this.root, this.ha, this.ja, null); + } else { + throw Error("persistent! called twice"); + } + return a; +}; +g.Sb = function(a, b, c) { + return Eg(this, b, c); +}; +var Ve = function Ve(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + return Ve.A(0 < c.length ? new C(c.slice(0), 0, null) : null); +}; +Ve.A = function(a) { + for (var b = B(a), c = zc($f);;) { + if (b) { + a = G(G(b)); + var d = D(b), b = D(G(b)), c = Cc(c, d, b), b = a; + } else { + return Bc(c); + } + } +}; +Ve.F = 0; +Ve.L = function(a) { + return Ve.A(B(a)); +}; +function Fg(a, b) { + this.G = a; + this.la = b; + this.m = 32374988; + this.C = 0; +} +g = Fg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.la; +}; +g.ma = function() { + var a = (null != this.G ? this.G.m & 128 || this.G.nc || (this.G.m ? 0 : t(Qb, this.G)) : t(Qb, this.G)) ? this.G.ma(null) : G(this.G); + return null == a ? null : new Fg(a, this.la); +}; +g.U = function() { + return fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.la); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return this.G.ba(null).Gc(); +}; +g.ia = function() { + var a = (null != this.G ? this.G.m & 128 || this.G.nc || (this.G.m ? 0 : t(Qb, this.G)) : t(Qb, this.G)) ? this.G.ma(null) : G(this.G); + return null != a ? new Fg(a, this.la) : bd; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new Fg(this.G, b); +}; +g.W = function(a, b) { + return N(b, this); +}; +Fg.prototype[ub] = function() { + return dd(this); +}; +function Wf(a) { + return (a = B(a)) ? new Fg(a, null) : null; +} +function bg(a) { + return Yb(a); +} +function Gg(a, b) { + this.G = a; + this.la = b; + this.m = 32374988; + this.C = 0; +} +g = Gg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.M = function() { + return this.la; +}; +g.ma = function() { + var a = (null != this.G ? this.G.m & 128 || this.G.nc || (this.G.m ? 0 : t(Qb, this.G)) : t(Qb, this.G)) ? this.G.ma(null) : G(this.G); + return null == a ? null : new Gg(a, this.la); +}; +g.U = function() { + return fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.la); +}; +g.fa = function(a, b) { + return Yd(b, this); +}; +g.ga = function(a, b, c) { + return Zd(b, c, this); +}; +g.ba = function() { + return this.G.ba(null).Hc(); +}; +g.ia = function() { + var a = (null != this.G ? this.G.m & 128 || this.G.nc || (this.G.m ? 0 : t(Qb, this.G)) : t(Qb, this.G)) ? this.G.ma(null) : G(this.G); + return null != a ? new Gg(a, this.la) : bd; +}; +g.X = function() { + return this; +}; +g.P = function(a, b) { + return new Gg(this.G, b); +}; +g.W = function(a, b) { + return N(b, this); +}; +Gg.prototype[ub] = function() { + return dd(this); +}; +function Xf(a) { + return (a = B(a)) ? new Gg(a, null) : null; +} +function cg(a) { + return Zb(a); +} +var Hg = function Hg(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + return Hg.A(0 < c.length ? new C(c.slice(0), 0, null) : null); +}; +Hg.A = function(a) { + return q(Pe(ae, a)) ? $d(function(a, c) { + return xd.f(q(a) ? a : Ne, c); + }, a) : null; +}; +Hg.F = 0; +Hg.L = function(a) { + return Hg.A(B(a)); +}; +function Ig(a) { + this.Qc = a; +} +Ig.prototype.ea = function() { + return this.Qc.ea(); +}; +Ig.prototype.next = function() { + if (this.Qc.ea()) { + return this.Qc.next().I[0]; + } + throw Error("No such element"); +}; +Ig.prototype.remove = function() { + return Error("Unsupported operation"); +}; +function Jg(a, b, c) { + this.meta = a; + this.cb = b; + this.v = c; + this.m = 15077647; + this.C = 8196; +} +g = Jg.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.keys = function() { + return dd(B(this)); +}; +g.entries = function() { + return new Sf(B(B(this))); +}; +g.values = function() { + return dd(B(this)); +}; +g.has = function(a) { + return Xd(this, a); +}; +g.forEach = function(a) { + for (var b = B(this), c = null, d = 0, e = 0;;) { + if (e < d) { + var f = c.K(null, e), h = P(f, 0, null), f = P(f, 1, null); + a.f ? a.f(f, h) : a.call(null, f, h); + e += 1; + } else { + if (b = B(b)) { + Qd(b) ? (c = Fc(b), b = Gc(b), h = c, d = K(c), c = h) : (c = D(b), h = P(c, 0, null), f = P(c, 1, null), a.f ? a.f(f, h) : a.call(null, f, h), b = G(b), c = null, d = 0), e = 0; + } else { + return null; + } + } + } +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return Tb(this.cb, b) ? b : c; +}; +g.Da = function() { + return new Ig(Lc(this.cb)); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new Jg(this.meta, this.cb, this.v); +}; +g.Y = function() { + return Gb(this.cb); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = hd(this); +}; +g.B = function(a, b) { + return Md(b) && K(this) === K(b) && Oe(function(a) { + return function(b) { + return Xd(a, b); + }; + }(this), b); +}; +g.Db = function() { + return new Kg(zc(this.cb)); +}; +g.Z = function() { + return Id(Lg, this.meta); +}; +g.jd = function(a, b) { + return new Jg(this.meta, Wb(this.cb, b), null); +}; +g.X = function() { + return Wf(this.cb); +}; +g.P = function(a, b) { + return new Jg(b, this.cb, this.v); +}; +g.W = function(a, b) { + return new Jg(this.meta, S.h(this.cb, b, null), null); +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +var Lg = new Jg(null, Ne, id); +Jg.prototype[ub] = function() { + return dd(this); +}; +function Kg(a) { + this.fb = a; + this.C = 136; + this.m = 259; +} +g = Kg.prototype; +g.Tb = function(a, b) { + this.fb = Cc(this.fb, b, null); + return this; +}; +g.Ub = function() { + return new Jg(null, Bc(this.fb), null); +}; +g.Y = function() { + return K(this.fb); +}; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + return Sb.h(this.fb, b, Td) === Td ? c : b; +}; +g.call = function() { + function a(a, b, c) { + return Sb.h(this.fb, b, Td) === Td ? c : b; + } + function b(a, b) { + return Sb.h(this.fb, b, Td) === Td ? null : b; + } + var c = null, c = function(c, e, f) { + switch(arguments.length) { + case 2: + return b.call(this, 0, e); + case 3: + return a.call(this, 0, e, f); + } + throw Error("Invalid arity: " + arguments.length); + }; + c.f = b; + c.h = a; + return c; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return Sb.h(this.fb, a, Td) === Td ? null : a; +}; +g.f = function(a, b) { + return Sb.h(this.fb, a, Td) === Td ? b : a; +}; +function ne(a) { + if (null != a && (a.C & 4096 || a.ve)) { + return a.name; + } + if ("string" === typeof a) { + return a; + } + throw Error([w("Doesn't support name: "), w(a)].join("")); +} +function Mg(a, b) { + for (var c = zc(Ne), d = B(a), e = B(b);;) { + if (d && e) { + var f = D(d), h = D(e), c = Cc(c, f, h), d = G(d), e = G(e) + } else { + return Bc(c); + } + } +} +function Ng(a, b, c) { + this.i = a; + this.end = b; + this.step = c; +} +Ng.prototype.ea = function() { + return 0 < this.step ? this.i < this.end : this.i > this.end; +}; +Ng.prototype.next = function() { + var a = this.i; + this.i += this.step; + return a; +}; +function Og(a, b, c, d, e) { + this.meta = a; + this.start = b; + this.end = c; + this.step = d; + this.v = e; + this.m = 32375006; + this.C = 8192; +} +g = Og.prototype; +g.toString = function() { + return Nc(this); +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.indexOf = function() { + var a = null, a = function(a, c) { + switch(arguments.length) { + case 1: + return J(this, a, 0); + case 2: + return J(this, a, c); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.c = function(a) { + return J(this, a, 0); + }; + a.f = function(a, c) { + return J(this, a, c); + }; + return a; +}(); +g.lastIndexOf = function() { + function a(a) { + return L(this, a, K(this)); + } + var b = null, b = function(b, d) { + switch(arguments.length) { + case 1: + return a.call(this, b); + case 2: + return L(this, b, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + b.c = a; + b.f = function(a, b) { + return L(this, a, b); + }; + return b; +}(); +g.K = function(a, b) { + if (b < Gb(this)) { + return this.start + b * this.step; + } + if (this.start > this.end && 0 === this.step) { + return this.start; + } + throw Error("Index out of bounds"); +}; +g.sa = function(a, b, c) { + return b < Gb(this) ? this.start + b * this.step : this.start > this.end && 0 === this.step ? this.start : c; +}; +g.Da = function() { + return new Ng(this.start, this.end, this.step); +}; +g.M = function() { + return this.meta; +}; +g.ra = function() { + return new Og(this.meta, this.start, this.end, this.step, this.v); +}; +g.ma = function() { + return 0 < this.step ? this.start + this.step < this.end ? new Og(this.meta, this.start + this.step, this.end, this.step, null) : null : this.start + this.step > this.end ? new Og(this.meta, this.start + this.step, this.end, this.step, null) : null; +}; +g.Y = function() { + return qb(qc(this)) ? 0 : Math.ceil((this.end - this.start) / this.step); +}; +g.U = function() { + var a = this.v; + return null != a ? a : this.v = a = fd(this); +}; +g.B = function(a, b) { + return vd(this, b); +}; +g.Z = function() { + return Id(bd, this.meta); +}; +g.fa = function(a, b) { + return ld(this, b); +}; +g.ga = function(a, b, c) { + for (a = this.start;;) { + if (0 < this.step ? a < this.end : a > this.end) { + c = b.f ? b.f(c, a) : b.call(null, c, a), a += this.step; + } else { + return c; + } + } +}; +g.ba = function() { + return null == qc(this) ? null : this.start; +}; +g.ia = function() { + return null != qc(this) ? new Og(this.meta, this.start + this.step, this.end, this.step, null) : bd; +}; +g.X = function() { + return 0 < this.step ? this.start < this.end ? this : null : 0 > this.step ? this.start > this.end ? this : null : this.start === this.end ? null : this; +}; +g.P = function(a, b) { + return new Og(b, this.start, this.end, this.step, this.v); +}; +g.W = function(a, b) { + return N(b, this); +}; +Og.prototype[ub] = function() { + return dd(this); +}; +function Pg(a, b) { + if ("string" === typeof b) { + var c = a.exec(b); + return H.f(D(c), b) ? 1 === K(c) ? D(c) : Af(c) : null; + } + throw new TypeError("re-matches must match against a string."); +} +function Qg(a) { + if (a instanceof RegExp) { + return a; + } + var b; + var c = /^\(\?([idmsux]*)\)/; + if ("string" === typeof a) { + c = c.exec(a), b = null == c ? null : 1 === K(c) ? D(c) : Af(c); + } else { + throw new TypeError("re-find must match against a string."); + } + c = P(b, 0, null); + b = P(b, 1, null); + c = K(c); + return new RegExp(a.substring(c), q(b) ? b : ""); +} +function Rg(a, b, c, d, e, f, h) { + var k = eb; + eb = null == eb ? null : eb - 1; + try { + if (null != eb && 0 > eb) { + return tc(a, "#"); + } + tc(a, c); + if (0 === nb.c(f)) { + B(h) && tc(a, function() { + var a = Sg.c(f); + return q(a) ? a : "..."; + }()); + } else { + if (B(h)) { + var l = D(h); + b.h ? b.h(l, a, f) : b.call(null, l, a, f); + } + for (var m = G(h), p = nb.c(f) - 1;;) { + if (!m || null != p && 0 === p) { + B(m) && 0 === p && (tc(a, d), tc(a, function() { + var a = Sg.c(f); + return q(a) ? a : "..."; + }())); + break; + } else { + tc(a, d); + var r = D(m); + c = a; + h = f; + b.h ? b.h(r, c, h) : b.call(null, r, c, h); + var u = G(m); + c = p - 1; + m = u; + p = c; + } + } + } + return tc(a, e); + } finally { + eb = k; + } +} +function Tg(a, b) { + for (var c = B(b), d = null, e = 0, f = 0;;) { + if (f < e) { + var h = d.K(null, f); + tc(a, h); + f += 1; + } else { + if (c = B(c)) { + d = c, Qd(d) ? (c = Fc(d), e = Gc(d), d = c, h = K(c), c = e, e = h) : (h = D(d), tc(a, h), c = G(d), d = null, e = 0), f = 0; + } else { + return null; + } + } + } +} +var Ug = {'"':'\\"', "\\":"\\\\", "\b":"\\b", "\f":"\\f", "\n":"\\n", "\r":"\\r", "\t":"\\t"}; +function Vg(a) { + return [w('"'), w(a.replace(RegExp('[\\\\"\b\f\n\r\t]', "g"), function(a) { + return Ug[a]; + })), w('"')].join(""); +} +function Wg(a, b) { + var c = Vd(z.f(a, lb)); + return c ? (c = null != b ? b.m & 131072 || b.ue ? !0 : !1 : !1) ? null != Jd(b) : c : c; +} +function Xg(a, b, c) { + if (null == a) { + return tc(b, "nil"); + } + if (Wg(c, a)) { + tc(b, "^"); + var d = Jd(a); + Yg.h ? Yg.h(d, b, c) : Yg.call(null, d, b, c); + tc(b, " "); + } + if (a.qb) { + return a.Eb(a, b, c); + } + if (null != a && (a.m & 2147483648 || a.$)) { + return a.S(null, b, c); + } + if (!0 === a || !1 === a || "number" === typeof a) { + return tc(b, "" + w(a)); + } + if (null != a && a.constructor === Object) { + return tc(b, "#js "), d = X.f(function(b) { + return new V(null, 2, 5, W, [me.c(b), a[b]], null); + }, Rd(a)), Zg.w ? Zg.w(d, Yg, b, c) : Zg.call(null, d, Yg, b, c); + } + if (pb(a)) { + return Rg(b, Yg, "#js [", " ", "]", c, a); + } + if (ca(a)) { + return q(kb.c(c)) ? tc(b, Vg(a)) : tc(b, a); + } + if (ea(a)) { + var e = a.name; + c = q(function() { + var a = null == e; + return a ? a : oa(e); + }()) ? "Function" : e; + return Tg(b, O(["#object[", c, ' "', "" + w(a), '"]'], 0)); + } + if (a instanceof Date) { + return c = function(a, b) { + for (var c = "" + w(a);;) { + if (K(c) < b) { + c = [w("0"), w(c)].join(""); + } else { + return c; + } + } + }, Tg(b, O(['#inst "', "" + w(a.getUTCFullYear()), "-", c(a.getUTCMonth() + 1, 2), "-", c(a.getUTCDate(), 2), "T", c(a.getUTCHours(), 2), ":", c(a.getUTCMinutes(), 2), ":", c(a.getUTCSeconds(), 2), ".", c(a.getUTCMilliseconds(), 3), "-", '00:00"'], 0)); + } + if (a instanceof RegExp) { + return Tg(b, O(['#"', a.source, '"'], 0)); + } + if (q(a.constructor.Za)) { + return Tg(b, O(["#object[", a.constructor.Za.replace(RegExp("/", "g"), "."), "]"], 0)); + } + e = a.constructor.name; + c = q(function() { + var a = null == e; + return a ? a : oa(e); + }()) ? "Object" : e; + return Tg(b, O(["#object[", c, " ", "" + w(a), "]"], 0)); +} +function Yg(a, b, c) { + var d = $g.c(c); + return q(d) ? (c = S.h(c, ah, Xg), d.h ? d.h(a, b, c) : d.call(null, a, b, c)) : Xg(a, b, c); +} +function bh(a) { + var b = hb(); + if (Ld(a)) { + b = ""; + } else { + var c = w, d = new Ua; + a: { + var e = new Mc(d); + Yg(D(a), e, b); + a = B(G(a)); + for (var f = null, h = 0, k = 0;;) { + if (k < h) { + var l = f.K(null, k); + tc(e, " "); + Yg(l, e, b); + k += 1; + } else { + if (a = B(a)) { + f = a, Qd(f) ? (a = Fc(f), h = Gc(f), f = a, l = K(a), a = h, h = l) : (l = D(f), tc(e, " "), Yg(l, e, b), a = G(f), f = null, h = 0), k = 0; + } else { + break a; + } + } + } + } + b = "" + c(d); + } + return b; +} +function Zg(a, b, c, d) { + return Rg(c, function(a, c, d) { + var k = Yb(a); + b.h ? b.h(k, c, d) : b.call(null, k, c, d); + tc(c, " "); + a = Zb(a); + return b.h ? b.h(a, c, d) : b.call(null, a, c, d); + }, "{", ", ", "}", d, B(a)); +} +C.prototype.$ = !0; +C.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +oe.prototype.$ = !0; +oe.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +xg.prototype.$ = !0; +xg.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Uf.prototype.$ = !0; +Uf.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Bf.prototype.$ = !0; +Bf.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +ke.prototype.$ = !0; +ke.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Cg.prototype.$ = !0; +Cg.prototype.S = function(a, b, c) { + return Zg(this, Yg, b, c); +}; +zg.prototype.$ = !0; +zg.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Ff.prototype.$ = !0; +Ff.prototype.S = function(a, b, c) { + return Rg(b, Yg, "[", " ", "]", c, this); +}; +Jg.prototype.$ = !0; +Jg.prototype.S = function(a, b, c) { + return Rg(b, Yg, "#{", " ", "}", c, this); +}; +se.prototype.$ = !0; +se.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Se.prototype.$ = !0; +Se.prototype.S = function(a, b, c) { + tc(b, "#object [cljs.core.Atom "); + Yg(new ib(null, 1, [ch, this.state], null), b, c); + return tc(b, "]"); +}; +Gg.prototype.$ = !0; +Gg.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +V.prototype.$ = !0; +V.prototype.S = function(a, b, c) { + return Rg(b, Yg, "[", " ", "]", c, this); +}; +Lf.prototype.$ = !0; +Lf.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +ie.prototype.$ = !0; +ie.prototype.S = function(a, b) { + return tc(b, "()"); +}; +Mf.prototype.$ = !0; +Mf.prototype.S = function(a, b, c) { + return Rg(b, Yg, "#queue [", " ", "]", c, B(this)); +}; +ib.prototype.$ = !0; +ib.prototype.S = function(a, b, c) { + return Zg(this, Yg, b, c); +}; +Og.prototype.$ = !0; +Og.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +Fg.prototype.$ = !0; +Fg.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +he.prototype.$ = !0; +he.prototype.S = function(a, b, c) { + return Rg(b, Yg, "(", " ", ")", c, this); +}; +function dh(a, b, c) { + xc(a, b, c); +} +var eh = null; +function fh() { +} +var gh = function gh(b) { + if (null != b && null != b.oe) { + return b.oe(b); + } + var c = gh[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = gh._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IEncodeJS.-clj-\x3ejs", b); +}; +function hh(a) { + return (null != a ? a.ne || (a.R ? 0 : t(fh, a)) : t(fh, a)) ? gh(a) : "string" === typeof a || "number" === typeof a || a instanceof T || a instanceof Yc ? ih.c ? ih.c(a) : ih.call(null, a) : bh(O([a], 0)); +} +var ih = function ih(b) { + if (null == b) { + return null; + } + if (null != b ? b.ne || (b.R ? 0 : t(fh, b)) : t(fh, b)) { + return gh(b); + } + if (b instanceof T) { + return ne(b); + } + if (b instanceof Yc) { + return "" + w(b); + } + if (Od(b)) { + var c = {}; + b = B(b); + for (var d = null, e = 0, f = 0;;) { + if (f < e) { + var h = d.K(null, f), k = P(h, 0, null), h = P(h, 1, null); + c[hh(k)] = ih(h); + f += 1; + } else { + if (b = B(b)) { + Qd(b) ? (e = Fc(b), b = Gc(b), d = e, e = K(e)) : (e = D(b), d = P(e, 0, null), e = P(e, 1, null), c[hh(d)] = ih(e), b = G(b), d = null, e = 0), f = 0; + } else { + break; + } + } + } + return c; + } + if (null == b ? 0 : null != b ? b.m & 8 || b.zf || (b.m ? 0 : t(Ib, b)) : t(Ib, b)) { + c = []; + b = B(X.f(ih, b)); + d = null; + for (f = e = 0;;) { + if (f < e) { + k = d.K(null, f), c.push(k), f += 1; + } else { + if (b = B(b)) { + d = b, Qd(d) ? (b = Fc(d), f = Gc(d), d = b, e = K(b), b = f) : (b = D(d), c.push(b), b = G(d), d = null, e = 0), f = 0; + } else { + break; + } + } + } + return c; + } + return b; +}; +function jh(a, b) { + this.jc = a; + this.v = b; + this.m = 2153775104; + this.C = 2048; +} +g = jh.prototype; +g.toString = function() { + return this.jc; +}; +g.equiv = function(a) { + return this.B(null, a); +}; +g.B = function(a, b) { + return b instanceof jh && this.jc === b.jc; +}; +g.S = function(a, b) { + return tc(b, [w('#uuid "'), w(this.jc), w('"')].join("")); +}; +g.U = function() { + null == this.v && (this.v = Wc(this.jc)); + return this.v; +}; +var kh = new T(null, "old-state", "old-state", 1039580704), lh = new T(null, "path", "path", -188191168), mh = new T(null, "state-map", "state-map", -1313872128), nh = new T(null, "new-value", "new-value", 1087038368), oh = new T(null, "descriptor", "descriptor", 76122018), ph = new Yc(null, "todo-item", "todo-item", 579606723, null), qh = new T("om.core", "not-found", "om.core/not-found", 1869894275), rh = new Yc(null, "p__14436", "p__14436", -1046387005, null), sh = new Yc(null, "meta14482", "meta14482", +2105235203, null), th = new T(null, "componentDidUpdate", "componentDidUpdate", -1983477981), uh = new T(null, "todos", "todos", 630308868), vh = new T(null, "fn", "fn", -1175266204), wh = new T(null, "showing", "showing", 798009604), xh = new T(null, "new-state", "new-state", -490349212), yh = new Yc(null, "owner", "owner", 1247919588, null), zh = new T(null, "instrument", "instrument", -960698844), lb = new T(null, "meta", "meta", 1499536964), Ah = new T(null, "react-key", "react-key", 1337881348), +Bh = new Yc(null, "map__14479", "map__14479", -1186641819, null), Ch = new T("om.core", "id", "om.core/id", 299074693), Dh = new Yc(null, "blockable", "blockable", -28395259, null), mb = new T(null, "dup", "dup", 556298533), Eh = new T(null, "key", "key", -1516042587), Fh = new T(null, "skip-render-root", "skip-render-root", -5219643), Gh = new T(null, "private", "private", -558947994), Hh = new T(null, "isOmComponent", "isOmComponent", -2070015162), We = new T(null, "validator", "validator", -1966190681), +Ih = new T(null, "default", "default", -1987822328), Jh = new T(null, "finally-block", "finally-block", 832982472), Lh = new T(null, "create", "create", -1301499256), Mh = new T(null, "adapt", "adapt", -1817022327), Nh = new T(null, "as", "as", 1148689641), Oh = new T(null, "completed", "completed", -486056503), Ph = new T(null, "edit", "edit", -1641834166), Qh = new T(null, "comm", "comm", -1689770614), Rh = new Yc(null, "todos", "todos", -2024126901, null), Sh = new T(null, "old-value", "old-value", +862546795), Th = new T(null, "destroy", "destroy", -843660405), Uh = new T(null, "edit-text", "edit-text", -616821813), ch = new T(null, "val", "val", 128701612), Vh = new T("om.core", "pass", "om.core/pass", -1453289268), Wh = new T(null, "recur", "recur", -437573268), Xh = new T(null, "init-state", "init-state", 1450863212), Yh = new T(null, "catch-block", "catch-block", 1175212748), Zh = new T(null, "delete", "delete", -1768633620), $h = new T(null, "state", "state", -1988618099), ah = new T(null, +"fallback-impl", "fallback-impl", -1501286995), ai = new T(null, "pending-state", "pending-state", 1525896973), jb = new T(null, "flush-on-newline", "flush-on-newline", -151457939), bi = new T(null, "save", "save", 1850079149), ci = new T(null, "componentWillUnmount", "componentWillUnmount", 1573788814), di = new T(null, "componentWillReceiveProps", "componentWillReceiveProps", 559988974), ei = new T(null, "all", "all", 892129742), fi = new T(null, "ignore", "ignore", -1631542033), gi = new T(null, +"title", "title", 636505583), hi = new T(null, "shouldComponentUpdate", "shouldComponentUpdate", 1795750960), kb = new T(null, "readably", "readably", 1129599760), ii = new Yc(null, "box", "box", -1123515375, null), Sg = new T(null, "more-marker", "more-marker", -14717935), ji = new T(null, "key-fn", "key-fn", -636154479), ki = new T(null, "editing", "editing", 1365491601), li = new T(null, "render", "render", -1408033454), mi = new T(null, "filter", "filter", -948537934), ni = new T(null, "keys", +"keys", 1068423698), oi = new T(null, "previous-state", "previous-state", 1888227923), pi = new Yc(null, "val", "val", 1769233139, null), nb = new T(null, "print-length", "print-length", 1931866356), qi = new T(null, "hidden", "hidden", -312506092), ri = new T(null, "componentWillUpdate", "componentWillUpdate", 657390932), si = new T(null, "active", "active", 1895962068), ti = new T(null, "id", "id", -1388402092), ui = new T(null, "getInitialState", "getInitialState", 1541760916), vi = new T(null, +"catch-exception", "catch-exception", -1997306795), wi = new T(null, "opts", "opts", 155075701), xi = new Yc(null, "/", "/", -1371932971, null), yi = new T(null, "prev", "prev", -1597069226), zi = new T(null, "continue-block", "continue-block", -1852047850), Ai = new T(null, "needs-focus", "needs-focus", 710899286), Bi = new T("om.core", "index", "om.core/index", -1724175434), Ci = new T(null, "shared", "shared", -384145993), Di = new T(null, "raf", "raf", -1295410152), Ei = new T(null, "componentDidMount", +"componentDidMount", 955710936), Fi = new T(null, "cancel", "cancel", -1964088360), Gi = new T("om.core", "invalid", "om.core/invalid", 1948827993), Hi = new T(null, "tag", "tag", -1290361223), Ii = new T(null, "target", "target", 253001721), Ji = new T(null, "getDisplayName", "getDisplayName", 1324429466), Me = new Yc(null, "quote", "quote", 1377916282, null), Le = new T(null, "arglists", "arglists", 1661989754), Ke = new Yc(null, "nil-iter", "nil-iter", 1101030523, null), $g = new T(null, "alt-impl", +"alt-impl", 670969595), Ki = new Yc(null, "fn-handler", "fn-handler", 648785851, null), Li = new Yc(null, "app", "app", 1079569820, null), Mi = new Yc(null, "deref", "deref", 1494944732, null), Ni = new Yc(null, "todo-app", "todo-app", -778031523, null), Oi = new T(null, "componentWillMount", "componentWillMount", -285327619), Pi = new Yc(null, "todo", "todo", 594088957, null), Qi = new T("om.core", "defer", "om.core/defer", -1038866178), Ri = new T(null, "render-state", "render-state", 2053902270), +Si = new T(null, "tx-listen", "tx-listen", 119130367), Ti = new T(null, "clear", "clear", 1877104959), Ui = new Yc(null, "f", "f", 43394975, null); +function Vi() { +} +Vi.Ee = function() { + return Vi.yd ? Vi.yd : Vi.yd = new Vi; +}; +Vi.prototype.Oe = 0; +function Wi() { + return ":" + (Vi.Ee().Oe++).toString(36); +} +;var Xi = function Xi(b) { + if (null != b && null != b.ud) { + return b.ud(); + } + var c = Xi[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Xi._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("PushbackReader.read-char", b); +}, Yi = function Yi(b, c) { + if (null != b && null != b.vd) { + return b.vd(0, c); + } + var d = Yi[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Yi._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("PushbackReader.unread", b); +}; +function Zi(a, b, c) { + this.s = a; + this.buffer = b; + this.Nc = c; +} +Zi.prototype.ud = function() { + return 0 === this.buffer.length ? (this.Nc += 1, this.s[this.Nc]) : this.buffer.pop(); +}; +Zi.prototype.vd = function(a, b) { + return this.buffer.push(b); +}; +function $i(a) { + var b = !/[^\t\n\r ]/.test(a); + return q(b) ? b : "," === a; +} +function aj(a) { + throw Error(Be(w, a)); +} +function bj(a, b) { + for (var c = new Ua(b), d = Xi(a);;) { + var e; + if (!(e = null == d || $i(d))) { + e = d; + var f = "#" !== e; + e = f ? (f = "'" !== e) ? (f = ":" !== e) ? cj.c ? cj.c(e) : cj.call(null, e) : f : f : f; + } + if (e) { + return Yi(a, d), c.toString(); + } + c.append(d); + d = Xi(a); + } +} +function dj(a) { + for (;;) { + var b = Xi(a); + if ("\n" === b || "\r" === b || null == b) { + return a; + } + } +} +var ej = Qg("^([-+]?)(?:(0)|([1-9][0-9]*)|0[xX]([0-9A-Fa-f]+)|0([0-7]+)|([1-9][0-9]?)[rR]([0-9A-Za-z]+))(N)?$"), fj = Qg("^([-+]?[0-9]+)/([0-9]+)$"), gj = Qg("^([-+]?[0-9]+(\\.[0-9]*)?([eE][-+]?[0-9]+)?)(M)?$"), hj = Qg("^[:]?([^0-9/].*/)?([^0-9/][^/]*)$"); +function ij(a, b) { + var c = a.exec(b); + return null != c && c[0] === b ? 1 === c.length ? c[0] : c : null; +} +var jj = Qg("^[0-9A-Fa-f]{2}$"), kj = Qg("^[0-9A-Fa-f]{4}$"); +function lj(a, b, c) { + return q(Pg(a, c)) ? c : aj(O(["Unexpected unicode escape \\", b, c], 0)); +} +function mj(a) { + var b = Xi(a), c = "t" === b ? "\t" : "r" === b ? "\r" : "n" === b ? "\n" : "\\" === b ? "\\" : '"' === b ? '"' : "b" === b ? "\b" : "f" === b ? "\f" : null; + q(c) ? b = c : "x" === b ? (a = (new Ua(Xi(a), Xi(a))).toString(), b = String.fromCharCode(parseInt(lj(jj, b, a), 16))) : "u" === b ? (a = (new Ua(Xi(a), Xi(a), Xi(a), Xi(a))).toString(), b = String.fromCharCode(parseInt(lj(kj, b, a), 16))) : b = /[^0-9]/.test(b) ? aj(O(["Unexpected unicode escape \\", b], 0)) : String.fromCharCode(b); + return b; +} +function nj(a, b) { + for (var c = [];;) { + var d; + a: { + d = b; + for (var e = $i, f = Xi(d);;) { + if (q(e.c ? e.c(f) : e.call(null, f))) { + f = Xi(d); + } else { + d = f; + break a; + } + } + } + q(d) || aj(O(["EOF while reading"], 0)); + if (a === d) { + return c; + } + e = cj.c ? cj.c(d) : cj.call(null, d); + q(e) ? d = e.f ? e.f(b, d) : e.call(null, b, d) : (Yi(b, d), d = oj.w ? oj.w(b, !0, null, !0) : oj.call(null, b, !0, null)); + d !== b && c.push(d); + } +} +function pj(a, b) { + return aj(O(["Reader for ", b, " not implemented yet"], 0)); +} +function qj(a, b) { + var c = Xi(a), d = rj.c ? rj.c(c) : rj.call(null, c); + if (q(d)) { + return d.f ? d.f(a, b) : d.call(null, a, b); + } + d = sj.f ? sj.f(a, c) : sj.call(null, a, c); + return q(d) ? d : aj(O(["No dispatch macro for ", c], 0)); +} +function tj(a, b) { + return aj(O(["Unmatched delimiter ", b], 0)); +} +function uj(a) { + a = nj(")", a); + for (var b = a.length, c = bd;;) { + if (0 < b) { + var d = b - 1, c = c.W(null, a[b - 1]), b = d + } else { + return c; + } + } +} +function vj(a) { + return Af(nj("]", a)); +} +function wj(a) { + a = nj("}", a); + var b = a.length; + if ("number" !== typeof b || isNaN(b) || Infinity === b || parseFloat(b) !== parseInt(b, 10)) { + throw Error([w("Argument must be an integer: "), w(b)].join("")); + } + 0 !== (b & 1) && aj(O(["Map literal must contain an even number of forms"], 0)); + if (b <= 2 * Zf) { + a = ag(a, !0); + } else { + a: { + for (var b = a.length, c = 0, d = zc($f);;) { + if (c < b) { + var e = c + 2, d = Cc(d, a[c], a[c + 1]), c = e + } else { + a = Bc(d); + break a; + } + } + } + } + return a; +} +function xj(a) { + for (var b = new Ua, c = Xi(a);;) { + if (null == c) { + return aj(O(["EOF while reading"], 0)); + } + if ("\\" === c) { + b.append(mj(a)); + } else { + if ('"' === c) { + return b.toString(); + } + b.append(c); + } + c = Xi(a); + } +} +function yj(a) { + for (var b = new Ua, c = Xi(a);;) { + if (null == c) { + return aj(O(["EOF while reading"], 0)); + } + if ("\\" === c) { + b.append(c); + var d = Xi(a); + if (null == d) { + return aj(O(["EOF while reading"], 0)); + } + var e = function() { + var a = b; + a.append(d); + return a; + }(), f = Xi(a); + } else { + if ('"' === c) { + return b.toString(); + } + e = function() { + var a = b; + a.append(c); + return a; + }(); + f = Xi(a); + } + b = e; + c = f; + } +} +function zj(a, b) { + var c = bj(a, b), d = -1 != c.indexOf("/"); + q(q(d) ? 1 !== c.length : d) ? c = Zc.f(ge(c, 0, c.indexOf("/")), ge(c, c.indexOf("/") + 1, c.length)) : (d = Zc.c(c), c = "nil" === c ? null : "true" === c ? !0 : "false" === c ? !1 : "/" === c ? xi : d); + return c; +} +function Aj(a, b) { + var c = bj(a, b), d = c.substring(1); + return 1 === d.length ? d : "tab" === d ? "\t" : "return" === d ? "\r" : "newline" === d ? "\n" : "space" === d ? " " : "backspace" === d ? "\b" : "formfeed" === d ? "\f" : "u" === d.charAt(0) ? String.fromCharCode(parseInt(d.substring(1), 16)) : "o" === d.charAt(0) ? pj(0, c) : aj(O(["Unknown character literal: ", c], 0)); +} +function Bj(a) { + a = bj(a, Xi(a)); + var b = ij(hj, a); + a = b[0]; + var c = b[1], b = b[2]; + return void 0 !== c && ":/" === c.substring(c.length - 2, c.length) || ":" === b[b.length - 1] || -1 !== a.indexOf("::", 1) ? aj(O(["Invalid token: ", a], 0)) : null != c && 0 < c.length ? me.f(c.substring(0, c.indexOf("/")), b) : me.c(a); +} +function Cj(a) { + return function(b) { + b = oj.w ? oj.w(b, !0, null, !0) : oj.call(null, b, !0, null); + b = Lb(bd, b); + return Lb(b, a); + }; +} +function Dj() { + return function() { + return aj(O(["Unreadable form"], 0)); + }; +} +function Ej(a) { + var b; + b = oj.w ? oj.w(a, !0, null, !0) : oj.call(null, a, !0, null); + b = b instanceof Yc ? new ib(null, 1, [Hi, b], null) : "string" === typeof b ? new ib(null, 1, [Hi, b], null) : b instanceof T ? ag([b, !0], !1) : b; + Od(b) || aj(O(["Metadata must be Symbol,Keyword,String or Map"], 0)); + a = oj.w ? oj.w(a, !0, null, !0) : oj.call(null, a, !0, null); + return (null != a ? a.m & 262144 || a.Hf || (a.m ? 0 : t(jc, a)) : t(jc, a)) ? Id(a, Hg.A(O([Jd(a), b], 0))) : aj(O(["Metadata can only be applied to IWithMetas"], 0)); +} +function Fj(a) { + a: { + a = nj("}", a); + var b = a.length; + if (b <= Zf) { + for (var c = 0, d = zc(Ne);;) { + if (c < b) { + var e = c + 1, d = Cc(d, a[c], null), c = e + } else { + a = new Jg(null, Bc(d), null); + break a; + } + } + } else { + for (c = 0, d = zc(Lg);;) { + if (c < b) { + e = c + 1, d = Ac(d, a[c]), c = e; + } else { + a = Bc(d); + break a; + } + } + } + } + return a; +} +function Gj(a) { + return Qg(yj(a)); +} +function Hj(a) { + oj.w ? oj.w(a, !0, null, !0) : oj.call(null, a, !0, null); + return a; +} +function cj(a) { + return '"' === a ? xj : ":" === a ? Bj : ";" === a ? dj : "'" === a ? Cj(Me) : "@" === a ? Cj(Mi) : "^" === a ? Ej : "`" === a ? pj : "~" === a ? pj : "(" === a ? uj : ")" === a ? tj : "[" === a ? vj : "]" === a ? tj : "{" === a ? wj : "}" === a ? tj : "\\" === a ? Aj : "#" === a ? qj : null; +} +function rj(a) { + return "{" === a ? Fj : "\x3c" === a ? Dj() : '"' === a ? Gj : "!" === a ? dj : "_" === a ? Hj : null; +} +function oj(a, b, c) { + for (;;) { + var d = Xi(a); + if (null == d) { + return q(b) ? aj(O(["EOF while reading"], 0)) : c; + } + if (!$i(d)) { + if (";" === d) { + a = dj.f ? dj.f(a, d) : dj.call(null, a); + } else { + var e = cj(d); + if (q(e)) { + e = e.f ? e.f(a, d) : e.call(null, a, d); + } else { + var e = a, f = void 0; + !(f = !/[^0-9]/.test(d)) && (f = void 0, f = "+" === d || "-" === d) && (f = Xi(e), Yi(e, f), f = !/[^0-9]/.test(f)); + if (f) { + a: { + for (e = a, d = new Ua(d), f = Xi(e);;) { + var h; + h = null == f; + h || (h = (h = $i(f)) ? h : cj.c ? cj.c(f) : cj.call(null, f)); + if (q(h)) { + Yi(e, f); + d = e = d.toString(); + f = void 0; + q(ij(ej, d)) ? (d = ij(ej, d), f = d[2], null != (H.f(f, "") ? null : f) ? f = 0 : (f = q(d[3]) ? [d[3], 10] : q(d[4]) ? [d[4], 16] : q(d[5]) ? [d[5], 8] : q(d[6]) ? [d[7], parseInt(d[6], 10)] : [null, null], h = f[0], null == h ? f = null : (f = parseInt(h, f[1]), f = "-" === d[1] ? -f : f))) : (f = void 0, q(ij(fj, d)) ? (d = ij(fj, d), f = parseInt(d[1], 10) / parseInt(d[2], 10)) : f = q(ij(gj, d)) ? parseFloat(d) : null); + d = f; + e = q(d) ? d : aj(O(["Invalid number format [", e, "]"], 0)); + break a; + } + d.append(f); + f = Xi(e); + } + } + } else { + e = zj(a, d); + } + } + if (e !== a) { + return e; + } + } + } + } +} +var Ij = function(a, b) { + return function(c, d) { + return z.f(q(d) ? b : a, c); + }; +}(new V(null, 13, 5, W, [null, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], null), new V(null, 13, 5, W, [null, 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], null)), Jj = /(\d\d\d\d)(?:-(\d\d)(?:-(\d\d)(?:[T](\d\d)(?::(\d\d)(?::(\d\d)(?:[.](\d+))?)?)?)?)?)?(?:[Z]|([-+])(\d\d):(\d\d))?/; +function Kj(a) { + a = parseInt(a, 10); + return qb(isNaN(a)) ? a : null; +} +function Lj(a, b, c, d) { + a <= b && b <= c || aj(O([[w(d), w(" Failed: "), w(a), w("\x3c\x3d"), w(b), w("\x3c\x3d"), w(c)].join("")], 0)); + return b; +} +function Mj(a) { + var b = Pg(Jj, a); + P(b, 0, null); + var c = P(b, 1, null), d = P(b, 2, null), e = P(b, 3, null), f = P(b, 4, null), h = P(b, 5, null), k = P(b, 6, null), l = P(b, 7, null), m = P(b, 8, null), p = P(b, 9, null), r = P(b, 10, null); + if (qb(b)) { + return aj(O([[w("Unrecognized date/time syntax: "), w(a)].join("")], 0)); + } + var u = Kj(c), x = function() { + var a = Kj(d); + return q(a) ? a : 1; + }(); + a = function() { + var a = Kj(e); + return q(a) ? a : 1; + }(); + var b = function() { + var a = Kj(f); + return q(a) ? a : 0; + }(), c = function() { + var a = Kj(h); + return q(a) ? a : 0; + }(), E = function() { + var a = Kj(k); + return q(a) ? a : 0; + }(), A = function() { + var a; + a: { + if (H.f(3, K(l))) { + a = l; + } else { + if (3 < K(l)) { + a = l.substring(0, 3); + } else { + for (a = new Ua(l);;) { + if (3 > a.hb.length) { + a = a.append("0"); + } else { + a = a.toString(); + break a; + } + } + } + } + } + a = Kj(a); + return q(a) ? a : 0; + }(), m = (H.f(m, "-") ? -1 : 1) * (60 * function() { + var a = Kj(p); + return q(a) ? a : 0; + }() + function() { + var a = Kj(r); + return q(a) ? a : 0; + }()); + return new V(null, 8, 5, W, [u, Lj(1, x, 12, "timestamp month field must be in range 1..12"), Lj(1, a, function() { + var a; + a = 0 === (u % 4 + 4) % 4; + q(a) && (a = qb(0 === (u % 100 + 100) % 100), a = q(a) ? a : 0 === (u % 400 + 400) % 400); + return Ij.f ? Ij.f(x, a) : Ij.call(null, x, a); + }(), "timestamp day field must be in range 1..last day in month"), Lj(0, b, 23, "timestamp hour field must be in range 0..23"), Lj(0, c, 59, "timestamp minute field must be in range 0..59"), Lj(0, E, H.f(c, 59) ? 60 : 59, "timestamp second field must be in range 0..60"), Lj(0, A, 999, "timestamp millisecond field must be in range 0..999"), m], null); +} +var Nj, Oj = new ib(null, 4, ["inst", function(a) { + var b; + if ("string" === typeof a) { + if (b = Mj(a), q(b)) { + a = P(b, 0, null); + var c = P(b, 1, null), d = P(b, 2, null), e = P(b, 3, null), f = P(b, 4, null), h = P(b, 5, null), k = P(b, 6, null); + b = P(b, 7, null); + b = new Date(Date.UTC(a, c - 1, d, e, f, h, k) - 6E4 * b); + } else { + b = aj(O([[w("Unrecognized date/time syntax: "), w(a)].join("")], 0)); + } + } else { + b = aj(O(["Instance literal expects a string for its timestamp."], 0)); + } + return b; +}, "uuid", function(a) { + return "string" === typeof a ? new jh(a, null) : aj(O(["UUID literal expects a string as its representation."], 0)); +}, "queue", function(a) { + return Pd(a) ? df(Nf, a) : aj(O(["Queue literal expects a vector for its elements."], 0)); +}, "js", function(a) { + if (Pd(a)) { + var b = []; + a = B(a); + for (var c = null, d = 0, e = 0;;) { + if (e < d) { + var f = c.K(null, e); + b.push(f); + e += 1; + } else { + if (a = B(a)) { + c = a, Qd(c) ? (a = Fc(c), e = Gc(c), c = a, d = K(a), a = e) : (a = D(c), b.push(a), a = G(c), c = null, d = 0), e = 0; + } else { + break; + } + } + } + return b; + } + if (Od(a)) { + b = {}; + a = B(a); + c = null; + for (e = d = 0;;) { + if (e < d) { + var h = c.K(null, e), f = P(h, 0, null), h = P(h, 1, null); + b[ne(f)] = h; + e += 1; + } else { + if (a = B(a)) { + Qd(a) ? (d = Fc(a), a = Gc(a), c = d, d = K(d)) : (d = D(a), c = P(d, 0, null), d = P(d, 1, null), b[ne(c)] = d, a = G(a), c = null, d = 0), e = 0; + } else { + break; + } + } + } + return b; + } + return aj(O([[w("JS literal expects a vector or map containing "), w("only string or unqualified keyword keys")].join("")], 0)); +}], null); +Nj = Ue ? Ue(Oj) : Te.call(null, Oj); +var Pj = Ue ? Ue(null) : Te.call(null, null); +function sj(a, b) { + var c = zj(a, b), d = z.f(I.c ? I.c(Nj) : I.call(null, Nj), "" + w(c)), e = I.c ? I.c(Pj) : I.call(null, Pj); + return q(d) ? (c = oj(a, !0, null), d.c ? d.c(c) : d.call(null, c)) : q(e) ? (d = oj(a, !0, null), e.f ? e.f(c, d) : e.call(null, c, d)) : aj(O(["Could not find tag parser for ", "" + w(c), " in ", bh(O([Wf(I.c ? I.c(Nj) : I.call(null, Nj))], 0))], 0)); +} +;function Qj(a) { + return q(a) ? {display:"none"} : {}; +} +;var Rj = function Rj(b) { + if (null == b ? 0 : null != b ? b.m & 64 || b.na || (b.m ? 0 : t(Nb, b)) : t(Nb, b)) { + var c = zd, d = X.c(Rj); + b = null != c && (c.C & 4 || c.me) ? Id(Bc(be(d, ze, zc(c), b)), Jd(c)) : be(d, xd, c, b); + } + return b; +}; +function Sj(a, b) { + return React.DOM.a.apply(null, xb(N(a, X.f(Rj, b)))); +} +function Tj(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + return Uj(arguments[0], 1 < b.length ? new C(b.slice(1), 0, null) : null); +} +function Uj(a, b) { + return React.DOM.button.apply(null, xb(N(a, X.f(Rj, b)))); +} +function Vj(a, b) { + return React.DOM.div.apply(null, xb(N(a, X.f(Rj, b)))); +} +function Wj() { + var a = O(["todos"], 0); + return React.DOM.h1.apply(null, xb(N(null, X.f(Rj, a)))); +} +function Xj(a, b) { + return React.DOM.label.apply(null, xb(N(a, X.f(Rj, b)))); +} +function Yj(a, b) { + return React.DOM.li.apply(null, xb(N(a, X.f(Rj, b)))); +} +function Zj(a) { + return React.DOM.p.apply(null, xb(N(null, X.f(Rj, a)))); +} +function ak(a, b) { + return React.DOM.section.apply(null, xb(N(a, X.f(Rj, b)))); +} +var bk = function bk(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + return bk.A(arguments[0], 1 < c.length ? new C(c.slice(1), 0, null) : null); +}; +bk.A = function(a, b) { + return React.DOM.ul.apply(null, xb(N(a, X.f(Rj, b)))); +}; +bk.F = 1; +bk.L = function(a) { + var b = D(a); + a = G(a); + return bk.A(b, a); +}; +function ck(a, b) { + var c = function() { + return React.createClass({getDisplayName:function() { + return b; + }, getInitialState:function() { + return {value:this.props.value}; + }, onChange:function(a) { + var b = this.props.onChange; + if (null == b) { + return null; + } + b.c ? b.c(a) : b.call(null, a); + return this.setState({value:a.target.value}); + }, componentWillReceiveProps:function(a) { + return this.setState({value:a.value}); + }, render:function() { + var b = {}; + Fa(b, this.props, {value:this.state.value, onChange:this.onChange, children:this.props.children}); + return a.c ? a.c(b) : a.call(null, b); + }}); + }(); + return React.createFactory(c); +} +var dk = ck(React.DOM.input, "input"); +ck(React.DOM.textarea, "textarea"); +ck(React.DOM.option, "option"); +ck(React.DOM.select, "select"); +function ek(a, b) { + return ReactDOM.render(a, b); +} +;var fk, gk = function gk(b, c, d) { + if (null != b && null != b.Kc) { + return b.Kc(0, c, d); + } + var e = gk[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = gk._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("WritePort.put!", b); +}, hk = function hk(b) { + if (null != b && null != b.oc) { + return b.oc(); + } + var c = hk[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = hk._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("Channel.close!", b); +}, ik = function ik(b) { + if (null != b && null != b.rd) { + return !0; + } + var c = ik[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = ik._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("Handler.active?", b); +}, jk = function jk(b) { + if (null != b && null != b.sd) { + return b.Aa; + } + var c = jk[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = jk._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("Handler.commit", b); +}, lk = function lk(b, c) { + if (null != b && null != b.qd) { + return b.qd(0, c); + } + var d = lk[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = lk._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("Buffer.add!*", b); +}, mk = function mk(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return mk.c(arguments[0]); + case 2: + return mk.f(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +mk.c = function(a) { + return a; +}; +mk.f = function(a, b) { + if (null == b) { + throw Error("Assert failed: (not (nil? itm))"); + } + return lk(a, b); +}; +mk.F = 2; +function nk(a, b, c, d, e) { + for (var f = 0;;) { + if (f < e) { + c[d + f] = a[b + f], f += 1; + } else { + break; + } + } +} +function ok(a, b, c, d) { + this.head = a; + this.I = b; + this.length = c; + this.j = d; +} +ok.prototype.pop = function() { + if (0 === this.length) { + return null; + } + var a = this.j[this.I]; + this.j[this.I] = null; + this.I = (this.I + 1) % this.j.length; + --this.length; + return a; +}; +ok.prototype.unshift = function(a) { + this.j[this.head] = a; + this.head = (this.head + 1) % this.j.length; + this.length += 1; + return null; +}; +function pk(a, b) { + a.length + 1 === a.j.length && a.resize(); + a.unshift(b); +} +ok.prototype.resize = function() { + var a = Array(2 * this.j.length); + return this.I < this.head ? (nk(this.j, this.I, a, 0, this.length), this.I = 0, this.head = this.length, this.j = a) : this.I > this.head ? (nk(this.j, this.I, a, 0, this.j.length - this.I), nk(this.j, 0, a, this.j.length - this.I, this.head), this.I = 0, this.head = this.length, this.j = a) : this.I === this.head ? (this.head = this.I = 0, this.j = a) : null; +}; +function qk(a, b) { + for (var c = a.length, d = 0;;) { + if (d < c) { + var e = a.pop(); + (b.c ? b.c(e) : b.call(null, e)) && a.unshift(e); + d += 1; + } else { + break; + } + } +} +function rk(a) { + if (!(0 < a)) { + throw Error([w("Assert failed: "), w("Can't create a ring buffer of size 0"), w("\n"), w("(\x3e n 0)")].join("")); + } + return new ok(0, 0, 0, Array(a)); +} +function sk(a, b) { + this.H = a; + this.n = b; + this.m = 2; + this.C = 0; +} +function tk(a) { + return a.H.length === a.n; +} +sk.prototype.qd = function(a, b) { + pk(this.H, b); + return this; +}; +sk.prototype.Y = function() { + return this.H.length; +}; +if ("undefined" === typeof uk) { + var uk = {} +} +;var vk; +a: { + var wk = aa.navigator; + if (wk) { + var xk = wk.userAgent; + if (xk) { + vk = xk; + break a; + } + } + vk = ""; +} +function Z(a) { + return -1 != vk.indexOf(a); +} +;function yk() { + return (Z("Chrome") || Z("CriOS")) && !Z("Edge"); +} +;var zk; +function Ak() { + var a = aa.MessageChannel; + "undefined" === typeof a && "undefined" !== typeof window && window.postMessage && window.addEventListener && !Z("Presto") && (a = function() { + var a = document.createElement("IFRAME"); + a.style.display = "none"; + a.src = ""; + document.documentElement.appendChild(a); + var b = a.contentWindow, a = b.document; + a.open(); + a.write(""); + a.close(); + var c = "callImmediate" + Math.random(), d = "file:" == b.location.protocol ? "*" : b.location.protocol + "//" + b.location.host, a = ka(function(a) { + if (("*" == d || a.origin == d) && a.data == c) { + this.port1.onmessage(); + } + }, this); + b.addEventListener("message", a, !1); + this.port1 = {}; + this.port2 = {postMessage:function() { + b.postMessage(c, d); + }}; + }); + if ("undefined" !== typeof a && !Z("Trident") && !Z("MSIE")) { + var b = new a, c = {}, d = c; + b.port1.onmessage = function() { + if (void 0 !== c.next) { + c = c.next; + var a = c.fd; + c.fd = null; + a(); + } + }; + return function(a) { + d.next = {fd:a}; + d = d.next; + b.port2.postMessage(0); + }; + } + return "undefined" !== typeof document && "onreadystatechange" in document.createElement("SCRIPT") ? function(a) { + var b = document.createElement("SCRIPT"); + b.onreadystatechange = function() { + b.onreadystatechange = null; + b.parentNode.removeChild(b); + b = null; + a(); + a = null; + }; + document.documentElement.appendChild(b); + } : function(a) { + aa.setTimeout(a, 0); + }; +} +;var Bk = rk(32), Ck = !1, Dk = !1; +function Ek() { + Ck = !0; + Dk = !1; + for (var a = 0;;) { + var b = Bk.pop(); + if (null != b && (b.D ? b.D() : b.call(null), 1024 > a)) { + a += 1; + continue; + } + break; + } + Ck = !1; + return 0 < Bk.length ? Fk.D ? Fk.D() : Fk.call(null) : null; +} +function Fk() { + var a = Dk; + if (q(q(a) ? Ck : a)) { + return null; + } + Dk = !0; + !ea(aa.setImmediate) || aa.Window && aa.Window.prototype && !Z("Edge") && aa.Window.prototype.setImmediate == aa.setImmediate ? (zk || (zk = Ak()), zk(Ek)) : aa.setImmediate(Ek); +} +function Gk(a) { + pk(Bk, a); + Fk(); +} +;var Hk, Ik = function Ik(b) { + "undefined" === typeof Hk && (Hk = function(b, d, e) { + this.he = b; + this.ka = d; + this.Ie = e; + this.m = 425984; + this.C = 0; + }, Hk.prototype.P = function(b, d) { + return new Hk(this.he, this.ka, d); + }, Hk.prototype.M = function() { + return this.Ie; + }, Hk.prototype.Cb = function() { + return this.ka; + }, Hk.Wb = function() { + return new V(null, 3, 5, W, [Id(ii, new ib(null, 1, [Le, je(Me, je(new V(null, 1, 5, W, [pi], null)))], null)), pi, Za.If], null); + }, Hk.qb = !0, Hk.Za = "cljs.core.async.impl.channels/t_cljs$core$async$impl$channels11899", Hk.Eb = function(b, d) { + return tc(d, "cljs.core.async.impl.channels/t_cljs$core$async$impl$channels11899"); + }); + return new Hk(Ik, b, Ne); +}; +function Jk(a, b) { + this.Ja = a; + this.ka = b; +} +function Kk(a) { + return ik(a.Ja); +} +var Lk = function Lk(b) { + if (null != b && null != b.pd) { + return b.pd(); + } + var c = Lk[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Lk._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("MMC.abort", b); +}; +function Mk(a, b, c, d, e, f, h) { + this.Ab = a; + this.qc = b; + this.lb = c; + this.pc = d; + this.H = e; + this.closed = f; + this.xa = h; +} +Mk.prototype.pd = function() { + for (;;) { + var a = this.lb.pop(); + if (null != a) { + var b = a.Ja; + Gk(function(a) { + return function() { + return a.c ? a.c(!0) : a.call(null, !0); + }; + }(b.Aa, b, a.ka, a, this)); + } + break; + } + qk(this.lb, Re()); + return hk(this); +}; +Mk.prototype.Kc = function(a, b, c) { + var d = this; + if (null == b) { + throw Error([w("Assert failed: "), w("Can't put nil in on a channel"), w("\n"), w("(not (nil? val))")].join("")); + } + if (a = d.closed) { + return Ik(!a); + } + if (q(function() { + var a = d.H; + return q(a) ? qb(tk(d.H)) : a; + }())) { + for (c = kd(d.xa.f ? d.xa.f(d.H, b) : d.xa.call(null, d.H, b));;) { + if (0 < d.Ab.length && 0 < K(d.H)) { + var e = d.Ab.pop(), f = e.Aa, h = d.H.H.pop(); + Gk(function(a, b) { + return function() { + return a.c ? a.c(b) : a.call(null, b); + }; + }(f, h, e, c, a, this)); + } + break; + } + c && Lk(this); + return Ik(!0); + } + e = function() { + for (;;) { + var a = d.Ab.pop(); + if (q(a)) { + if (q(!0)) { + return a; + } + } else { + return null; + } + } + }(); + if (q(e)) { + return c = jk(e), Gk(function(a) { + return function() { + return a.c ? a.c(b) : a.call(null, b); + }; + }(c, e, a, this)), Ik(!0); + } + 64 < d.pc ? (d.pc = 0, qk(d.lb, Kk)) : d.pc += 1; + if (q(c.Jc(null))) { + if (!(1024 > d.lb.length)) { + throw Error([w("Assert failed: "), w([w("No more than "), w(1024), w(" pending puts are allowed on a single channel."), w(" Consider using a windowed buffer.")].join("")), w("\n"), w("(\x3c (.-length puts) impl/MAX-QUEUE-SIZE)")].join("")); + } + pk(d.lb, new Jk(c, b)); + } + return null; +}; +function Nk(a, b) { + if (null != a.H && 0 < K(a.H)) { + for (var c = b.Aa, d = Ik(a.H.H.pop());;) { + if (!q(tk(a.H))) { + var e = a.lb.pop(); + if (null != e) { + var f = e.Ja, h = e.ka; + Gk(function(a) { + return function() { + return a.c ? a.c(!0) : a.call(null, !0); + }; + }(f.Aa, f, h, e, c, d, a)); + kd(a.xa.f ? a.xa.f(a.H, h) : a.xa.call(null, a.H, h)) && Lk(a); + continue; + } + } + break; + } + return d; + } + c = function() { + for (;;) { + var b = a.lb.pop(); + if (q(b)) { + if (ik(b.Ja)) { + return b; + } + } else { + return null; + } + } + }(); + if (q(c)) { + return d = jk(c.Ja), Gk(function(a) { + return function() { + return a.c ? a.c(!0) : a.call(null, !0); + }; + }(d, c, a)), Ik(c.ka); + } + if (q(a.closed)) { + return q(a.H) && (a.xa.c ? a.xa.c(a.H) : a.xa.call(null, a.H)), q(q(!0) ? b.Aa : !0) ? (c = function() { + var b = a.H; + return q(b) ? 0 < K(a.H) : b; + }(), c = q(c) ? a.H.H.pop() : null, Ik(c)) : null; + } + 64 < a.qc ? (a.qc = 0, qk(a.Ab, ik)) : a.qc += 1; + if (q(b.Jc(null))) { + if (!(1024 > a.Ab.length)) { + throw Error([w("Assert failed: "), w([w("No more than "), w(1024), w(" pending takes are allowed on a single channel.")].join("")), w("\n"), w("(\x3c (.-length takes) impl/MAX-QUEUE-SIZE)")].join("")); + } + pk(a.Ab, b); + } + return null; +} +Mk.prototype.oc = function() { + var a = this; + if (!a.closed) { + for (a.closed = !0, q(function() { + var b = a.H; + return q(b) ? 0 === a.lb.length : b; + }()) && (a.xa.c ? a.xa.c(a.H) : a.xa.call(null, a.H));;) { + var b = a.Ab.pop(); + if (null == b) { + break; + } else { + var c = b.Aa, d = q(function() { + var b = a.H; + return q(b) ? 0 < K(a.H) : b; + }()) ? a.H.H.pop() : null; + Gk(function(a, b) { + return function() { + return a.c ? a.c(b) : a.call(null, b); + }; + }(c, d, b, this)); + } + } + } + return null; +}; +function Ok(a) { + console.log(a); + return null; +} +function Pk(a, b) { + var c = (q(null) ? null : Ok).call(null, b); + return null == c ? a : mk.f(a, c); +} +function Qk(a) { + return new Mk(rk(32), 0, rk(32), 0, a, !1, function() { + return function(a) { + return function() { + function c(c, d) { + try { + return a.f ? a.f(c, d) : a.call(null, c, d); + } catch (e) { + return Pk(c, e); + } + } + function d(c) { + try { + return a.c ? a.c(c) : a.call(null, c); + } catch (d) { + return Pk(c, d); + } + } + var e = null, e = function(a, b) { + switch(arguments.length) { + case 1: + return d.call(this, a); + case 2: + return c.call(this, a, b); + } + throw Error("Invalid arity: " + arguments.length); + }; + e.c = d; + e.f = c; + return e; + }(); + }(q(null) ? null.c ? null.c(mk) : null.call(null, mk) : mk); + }()); +} +;var Rk, Sk = function Sk(b) { + "undefined" === typeof Rk && (Rk = function(b, d, e) { + this.De = b; + this.Aa = d; + this.Ke = e; + this.m = 393216; + this.C = 0; + }, Rk.prototype.P = function(b, d) { + return new Rk(this.De, this.Aa, d); + }, Rk.prototype.M = function() { + return this.Ke; + }, Rk.prototype.rd = function() { + return !0; + }, Rk.prototype.Jc = function() { + return !0; + }, Rk.prototype.sd = function() { + return this.Aa; + }, Rk.Wb = function() { + return new V(null, 3, 5, W, [Id(Ki, new ib(null, 2, [Gh, !0, Le, je(Me, je(new V(null, 1, 5, W, [Ui], null)))], null)), Ui, Za.Jf], null); + }, Rk.qb = !0, Rk.Za = "cljs.core.async.impl.ioc-helpers/t_cljs$core$async$impl$ioc_helpers15030", Rk.Eb = function(b, d) { + return tc(d, "cljs.core.async.impl.ioc-helpers/t_cljs$core$async$impl$ioc_helpers15030"); + }); + return new Rk(Sk, b, Ne); +}; +function Tk(a) { + try { + return a[0].call(null, a); + } catch (b) { + throw b instanceof Object && a[6].oc(), b; + } +} +function Uk(a, b) { + var c = Nk(b, Sk(function(b) { + a[2] = b; + a[1] = 7; + return Tk(a); + })); + return q(c) ? (a[2] = I.c ? I.c(c) : I.call(null, c), a[1] = 7, Wh) : null; +} +function Vk(a, b) { + var c = a[6]; + null != b && c.Kc(0, b, Sk(function() { + return function() { + return null; + }; + }(c))); + c.oc(); + return c; +} +function Wk(a) { + for (;;) { + var b = a[4], c = Yh.c(b), d = vi.c(b), e = a[5]; + if (q(function() { + var a = e; + return q(a) ? qb(b) : a; + }())) { + throw e; + } + if (q(function() { + var a = e; + return q(a) ? (a = c, q(a) ? H.f(Ih, d) || e instanceof d : a) : a; + }())) { + a[1] = c; + a[2] = e; + a[5] = null; + a[4] = S.A(b, Yh, null, O([vi, null], 0)); + break; + } + if (q(function() { + var a = e; + return q(a) ? qb(c) && qb(Jh.c(b)) : a; + }())) { + a[4] = yi.c(b); + } else { + if (q(function() { + var a = e; + return q(a) ? (a = qb(c)) ? Jh.c(b) : a : a; + }())) { + a[1] = Jh.c(b); + a[4] = S.h(b, Jh, null); + break; + } + if (q(function() { + var a = qb(e); + return a ? Jh.c(b) : a; + }())) { + a[1] = Jh.c(b); + a[4] = S.h(b, Jh, null); + break; + } + if (qb(e) && qb(Jh.c(b))) { + a[1] = zi.c(b); + a[4] = yi.c(b); + break; + } + throw Error("No matching clause"); + } + } +} +;for (var Xk = Array(1), Yk = 0;;) { + if (Yk < Xk.length) { + Xk[Yk] = null, Yk += 1; + } else { + break; + } +} +;function Zk(a) { + a = H.f(a, 0) ? null : a; + if (q(null) && !q(a)) { + throw Error([w("Assert failed: "), w("buffer must be supplied when transducer is"), w("\n"), w("buf-or-n")].join("")); + } + a = "number" === typeof a ? new sk(rk(a), a) : a; + return Qk(a); +} +var $k = function(a) { + "undefined" === typeof fk && (fk = function(a, c, d) { + this.Aa = a; + this.ed = c; + this.Le = d; + this.m = 393216; + this.C = 0; + }, fk.prototype.P = function(a, c) { + return new fk(this.Aa, this.ed, c); + }, fk.prototype.M = function() { + return this.Le; + }, fk.prototype.rd = function() { + return !0; + }, fk.prototype.Jc = function() { + return this.ed; + }, fk.prototype.sd = function() { + return this.Aa; + }, fk.Wb = function() { + return new V(null, 3, 5, W, [Ui, Dh, Za.Kf], null); + }, fk.qb = !0, fk.Za = "cljs.core.async/t_cljs$core$async15186", fk.Eb = function(a, c) { + return tc(c, "cljs.core.async/t_cljs$core$async15186"); + }); + return new fk(a, !0, Ne); +}(function() { + return null; +}); +function al(a, b) { + var c = gk(a, b, $k); + return q(c) ? I.c ? I.c(c) : I.call(null, c) : !0; +} +;function bl() { + return Z("iPhone") && !Z("iPod") && !Z("iPad"); +} +;var cl = Z("Opera"), dl = Z("Trident") || Z("MSIE"), el = Z("Edge"), fl = Z("Gecko") && !(-1 != vk.toLowerCase().indexOf("webkit") && !Z("Edge")) && !(Z("Trident") || Z("MSIE")) && !Z("Edge"), gl = -1 != vk.toLowerCase().indexOf("webkit") && !Z("Edge"); +gl && Z("Mobile"); +Z("Macintosh"); +Z("Windows"); +Z("Linux") || Z("CrOS"); +var hl = aa.navigator || null; +hl && (hl.appVersion || "").indexOf("X11"); +Z("Android"); +bl(); +Z("iPad"); +Z("iPod"); +function il() { + var a = aa.document; + return a ? a.documentMode : void 0; +} +var jl; +a: { + var kl = "", ll = function() { + var a = vk; + if (fl) { + return /rv\:([^\);]+)(\)|;)/.exec(a); + } + if (el) { + return /Edge\/([\d\.]+)/.exec(a); + } + if (dl) { + return /\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(a); + } + if (gl) { + return /WebKit\/(\S+)/.exec(a); + } + if (cl) { + return /(?:Version)[ \/]?(\S+)/.exec(a); + } + }(); + ll && (kl = ll ? ll[1] : ""); + if (dl) { + var ml = il(); + if (null != ml && ml > parseFloat(kl)) { + jl = String(ml); + break a; + } + } + jl = kl; +} +var nl = {}; +function ol(a) { + var b; + if (!(b = nl[a])) { + b = 0; + for (var c = qa(String(jl)).split("."), d = qa(String(a)).split("."), e = Math.max(c.length, d.length), f = 0;0 == b && f < e;f++) { + var h = c[f] || "", k = d[f] || "", l = RegExp("(\\d*)(\\D*)", "g"), m = RegExp("(\\d*)(\\D*)", "g"); + do { + var p = l.exec(h) || ["", "", ""], r = m.exec(k) || ["", "", ""]; + if (0 == p[0].length && 0 == r[0].length) { + break; + } + b = Aa(0 == p[1].length ? 0 : parseInt(p[1], 10), 0 == r[1].length ? 0 : parseInt(r[1], 10)) || Aa(0 == p[2].length, 0 == r[2].length) || Aa(p[2], r[2]); + } while (0 == b); + } + b = nl[a] = 0 <= b; + } + return b; +} +var pl = aa.document, ql = pl && dl ? il() || ("CSS1Compat" == pl.compatMode ? parseInt(jl, 10) : 5) : void 0; +!fl && !dl || dl && 9 <= Number(ql) || fl && ol("1.9.1"); +dl && ol("9"); +var rl = {area:!0, base:!0, br:!0, col:!0, command:!0, embed:!0, hr:!0, img:!0, input:!0, keygen:!0, link:!0, meta:!0, param:!0, source:!0, track:!0, wbr:!0}; +function sl() { + this.Ac = ""; + this.ee = tl; +} +sl.prototype.tb = !0; +sl.prototype.ib = function() { + return this.Ac; +}; +sl.prototype.toString = function() { + return "Const{" + this.Ac + "}"; +}; +function ul(a) { + return a instanceof sl && a.constructor === sl && a.ee === tl ? a.Ac : "type_error:Const"; +} +var tl = {}; +function vl(a) { + var b = new sl; + b.Ac = a; + return b; +} +;function wl() { + this.Zc = ""; + this.ce = xl; +} +wl.prototype.tb = !0; +var xl = {}; +wl.prototype.ib = function() { + return this.Zc; +}; +wl.prototype.uc = function(a) { + this.Zc = a; + return this; +}; +var yl = (new wl).uc(""), zl = /^([-,."'%_!# a-zA-Z0-9]+|(?:rgb|hsl)a?\([0-9.%, ]+\))$/; +function Al() { + this.xb = ""; + this.de = Bl; +} +Al.prototype.tb = !0; +Al.prototype.ib = function() { + return this.xb; +}; +Al.prototype.Pc = !0; +Al.prototype.Xb = function() { + return 1; +}; +var Cl = /^(?:(?:https?|mailto|ftp):|[^&:/?#]*(?:[/?#]|$))/i, Bl = {}; +function Dl(a) { + var b = new Al; + b.xb = a; + return b; +} +Dl("about:blank"); +function El() { + this.$c = ""; + this.fe = Fl; +} +El.prototype.tb = !0; +El.prototype.ib = function() { + return this.$c; +}; +El.prototype.Pc = !0; +El.prototype.Xb = function() { + return 1; +}; +function Gl(a) { + if (a instanceof El && a.constructor === El && a.fe === Fl) { + return a.$c; + } + n(a); + return "type_error:TrustedResourceUrl"; +} +var Fl = {}; +function Hl(a) { + var b = new El; + b.$c = a; + return b; +} +;function Il() { + this.xb = ""; + this.be = Jl; + this.wd = null; +} +Il.prototype.Pc = !0; +Il.prototype.Xb = function() { + return this.wd; +}; +Il.prototype.tb = !0; +Il.prototype.ib = function() { + return this.xb; +}; +function Kl(a) { + if (a instanceof Il && a.constructor === Il && a.be === Jl) { + return a.xb; + } + n(a); + return "type_error:SafeHtml"; +} +var Ll = /^[a-zA-Z0-9-]+$/, Ml = {action:!0, cite:!0, data:!0, formaction:!0, href:!0, manifest:!0, poster:!0, src:!0}, Nl = {APPLET:!0, BASE:!0, EMBED:!0, IFRAME:!0, LINK:!0, MATH:!0, META:!0, OBJECT:!0, SCRIPT:!0, STYLE:!0, SVG:!0, TEMPLATE:!0}; +function Ol(a, b, c) { + if (!Ll.test(a)) { + throw Error("Invalid tag name \x3c" + a + "\x3e."); + } + if (a.toUpperCase() in Nl) { + throw Error("Tag name \x3c" + a + "\x3e is not allowed for SafeHtml."); + } + return Pl(a, b, c); +} +function Ql(a) { + function b(a) { + if (ba(a)) { + Wa(a, b); + } else { + if (!(a instanceof Il)) { + var f = null; + a.Pc && (f = a.Xb()); + a = Rl(ra(a.tb ? a.ib() : String(a)), f); + } + d += Kl(a); + a = a.Xb(); + 0 == c ? c = a : 0 != a && c != a && (c = null); + } + } + var c = 0, d = ""; + Wa(arguments, b); + return Rl(d, c); +} +var Jl = {}; +function Rl(a, b) { + return (new Il).uc(a, b); +} +Il.prototype.uc = function(a, b) { + this.xb = a; + this.wd = b; + return this; +}; +function Pl(a, b, c) { + var d = null, e, f = ""; + if (b) { + for (e in b) { + if (!Ll.test(e)) { + throw Error('Invalid attribute name "' + e + '".'); + } + var h = b[e]; + if (null != h) { + var k, l = a; + k = e; + if (h instanceof sl) { + h = ul(h); + } else { + if ("style" == k.toLowerCase()) { + l = typeof h; + if (("object" != l || null == h) && "function" != l) { + throw Error('The "style" attribute requires goog.html.SafeStyle or map of style properties, ' + typeof h + " given: " + h); + } + if (!(h instanceof wl)) { + var l = "", m = void 0; + for (m in h) { + if (!/^[-_a-zA-Z0-9]+$/.test(m)) { + throw Error("Name allows only [-_a-zA-Z0-9], got: " + m); + } + var p = h[m]; + if (null != p) { + if (p instanceof sl) { + p = ul(p); + } else { + if (zl.test(p)) { + for (var r = !0, u = !0, x = 0;x < p.length;x++) { + var E = p.charAt(x); + "'" == E && u ? r = !r : '"' == E && r && (u = !u); + } + r && u || (p = "zClosurez"); + } else { + p = "zClosurez"; + } + } + l += m + ":" + p + ";"; + } + } + h = l ? (new wl).uc(l) : yl; + } + l = void 0; + h instanceof wl && h.constructor === wl && h.ce === xl ? l = h.Zc : (n(h), l = "type_error:SafeStyle"); + h = l; + } else { + if (/^on/i.test(k)) { + throw Error('Attribute "' + k + '" requires goog.string.Const value, "' + h + '" given.'); + } + if (k.toLowerCase() in Ml) { + if (h instanceof El) { + h = Gl(h); + } else { + if (h instanceof Al) { + h instanceof Al && h.constructor === Al && h.de === Bl ? h = h.xb : (n(h), h = "type_error:SafeUrl"); + } else { + if (ca(h)) { + h instanceof Al || (h = h.tb ? h.ib() : String(h), Cl.test(h) || (h = "about:invalid#zClosurez"), h = Dl(h)), h = h.ib(); + } else { + throw Error('Attribute "' + k + '" on tag "' + l + '" requires goog.html.SafeUrl, goog.string.Const, or string, value "' + h + '" given.'); + } + } + } + } + } + } + h.tb && (h = h.ib()); + k = k + '\x3d"' + ra(String(h)) + '"'; + f += " " + k; + } + } + } + e = "\x3c" + a + f; + null != c ? ba(c) || (c = [c]) : c = []; + !0 === rl[a.toLowerCase()] ? e += "\x3e" : (d = Ql(c), e += "\x3e" + Kl(d) + "\x3c/" + a + "\x3e", d = d.Xb()); + (a = b && b.dir) && (d = /^(ltr|rtl|auto)$/i.test(a) ? 0 : null); + return Rl(e, d); +} +Rl("\x3c!DOCTYPE html\x3e", 0); +Rl("", 0); +Rl("\x3cbr\x3e", 0); +function Sl(a) { + var b = document; + return ca(a) ? b.getElementById(a) : a; +} +function Tl(a) { + return a.contentDocument || a.contentWindow.document; +} +;Z("Firefox"); +bl() || Z("iPod"); +Z("iPad"); +!Z("Android") || yk() || Z("Firefox") || Z("Opera") || Z("Silk"); +yk(); +!Z("Safari") || yk() || Z("Coast") || Z("Opera") || Z("Edge") || Z("Silk") || Z("Android") || bl() || Z("iPad") || Z("iPod"); +var Ul = !dl; +var Vl = null, Wl = null, Xl = null, Yl = null, Zl = null; +function $l() { +} +var am = function am(b) { + if (null != b && null != b.Ve) { + return b.Ve(b); + } + var c = am[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = am._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IDisplayName.display-name", b); +}; +function bm() { +} +var cm = function cm(b) { + if (null != b && null != b.Hd) { + return b.Hd(); + } + var c = cm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = cm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IInitState.init-state", b); +}; +function dm() { +} +var em = function em(b, c, d) { + if (null != b && null != b.cf) { + return b.cf(b, c, d); + } + var e = em[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = em._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IShouldUpdate.should-update", b); +}; +function fm() { +} +var gm = function gm(b) { + if (null != b && null != b.Vd) { + return b.Vd(b); + } + var c = gm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = gm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IWillMount.will-mount", b); +}; +function hm() { +} +var im = function im(b) { + if (null != b && null != b.Ue) { + return b.Ue(b); + } + var c = im[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = im._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IDidMount.did-mount", b); +}; +function jm() { +} +var km = function km(b) { + if (null != b && null != b.hf) { + return b.hf(b); + } + var c = km[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = km._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IWillUnmount.will-unmount", b); +}; +function lm() { +} +var mm = function mm(b, c, d) { + if (null != b && null != b.Xd) { + return b.Xd(b, c, d); + } + var e = mm[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = mm._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IWillUpdate.will-update", b); +}; +function nm() { +} +var om = function om(b, c, d) { + if (null != b && null != b.Uc) { + return b.Uc(b, c, d); + } + var e = om[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = om._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IDidUpdate.did-update", b); +}; +function pm() { +} +var qm = function qm(b, c) { + if (null != b && null != b.ff) { + return b.ff(b, c); + } + var d = qm[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = qm._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IWillReceiveProps.will-receive-props", b); +}; +function rm() { +} +var sm = function sm(b) { + if (null != b && null != b.$e) { + return b.$e(b); + } + var c = sm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = sm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IRender.render", b); +}; +function tm() { +} +var um = function um(b, c, d) { + if (null != b && null != b.bf) { + return b.bf(b, c, d); + } + var e = um[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = um._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IRenderProps.render-props", b); +}; +function vm() { +} +var wm = function wm(b, c) { + if (null != b && null != b.Wc) { + return b.Wc(b, c); + } + var d = wm[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = wm._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IRenderState.render-state", b); +}; +function xm() { +} +function ym() { +} +var zm = function zm(b, c, d, e, f) { + if (null != b && null != b.Ye) { + return b.Ye(b, c, d, e, f); + } + var h = zm[n(null == b ? null : b)]; + if (null != h) { + return h.N ? h.N(b, c, d, e, f) : h.call(null, b, c, d, e, f); + } + h = zm._; + if (null != h) { + return h.N ? h.N(b, c, d, e, f) : h.call(null, b, c, d, e, f); + } + throw v("IOmSwap.-om-swap!", b); +}, Am = function Am(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return Am.c(arguments[0]); + case 2: + return Am.f(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Am.c = function(a) { + if (null != a && null != a.Ed) { + return a.Ed(a); + } + var b = Am[n(null == a ? null : a)]; + if (null != b) { + return b.c ? b.c(a) : b.call(null, a); + } + b = Am._; + if (null != b) { + return b.c ? b.c(a) : b.call(null, a); + } + throw v("IGetState.-get-state", a); +}; +Am.f = function(a, b) { + if (null != a && null != a.Fd) { + return a.Fd(a, b); + } + var c = Am[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = Am._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("IGetState.-get-state", a); +}; +Am.F = 2; +var Bm = function Bm(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 1: + return Bm.c(arguments[0]); + case 2: + return Bm.f(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Bm.c = function(a) { + if (null != a && null != a.Cd) { + return a.Cd(a); + } + var b = Bm[n(null == a ? null : a)]; + if (null != b) { + return b.c ? b.c(a) : b.call(null, a); + } + b = Bm._; + if (null != b) { + return b.c ? b.c(a) : b.call(null, a); + } + throw v("IGetRenderState.-get-render-state", a); +}; +Bm.f = function(a, b) { + if (null != a && null != a.Dd) { + return a.Dd(a, b); + } + var c = Bm[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = Bm._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("IGetRenderState.-get-render-state", a); +}; +Bm.F = 2; +var Cm = function Cm(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 3: + return Cm.h(arguments[0], arguments[1], arguments[2]); + case 4: + return Cm.w(arguments[0], arguments[1], arguments[2], arguments[3]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Cm.h = function(a, b, c) { + if (null != a && null != a.Rd) { + return a.Rd(a, b, c); + } + var d = Cm[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = Cm._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("ISetState.-set-state!", a); +}; +Cm.w = function(a, b, c, d) { + if (null != a && null != a.Sd) { + return a.Sd(a, b, c, d); + } + var e = Cm[n(null == a ? null : a)]; + if (null != e) { + return e.w ? e.w(a, b, c, d) : e.call(null, a, b, c, d); + } + e = Cm._; + if (null != e) { + return e.w ? e.w(a, b, c, d) : e.call(null, a, b, c, d); + } + throw v("ISetState.-set-state!", a); +}; +Cm.F = 4; +var Dm = function Dm(b) { + if (null != b && null != b.Md) { + return b.Md(b); + } + var c = Dm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Dm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IRenderQueue.-get-queue", b); +}, Em = function Em(b, c) { + if (null != b && null != b.Nd) { + return b.Nd(b, c); + } + var d = Em[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Em._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IRenderQueue.-queue-render!", b); +}, Fm = function Fm(b) { + if (null != b && null != b.Ld) { + return b.Ld(b); + } + var c = Fm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Fm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IRenderQueue.-empty-queue!", b); +}, Gm = function Gm(b) { + if (null != b && null != b.Td) { + return b.value; + } + var c = Gm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Gm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("IValue.-value", b); +}; +Gm._ = function(a) { + return a; +}; +function Hm() { +} +var Im = function Im(b) { + if (null != b && null != b.vc) { + return b.vc(b); + } + var c = Im[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Im._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ICursor.-path", b); +}, Jm = function Jm(b) { + if (null != b && null != b.wc) { + return b.wc(b); + } + var c = Jm[n(null == b ? null : b)]; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + c = Jm._; + if (null != c) { + return c.c ? c.c(b) : c.call(null, b); + } + throw v("ICursor.-state", b); +}; +function Km() { +} +var Lm = function Lm(b) { + for (var c = [], d = arguments.length, e = 0;;) { + if (e < d) { + c.push(arguments[e]), e += 1; + } else { + break; + } + } + switch(c.length) { + case 2: + return Lm.f(arguments[0], arguments[1]); + case 3: + return Lm.h(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(c.length)].join(""));; + } +}; +Lm.f = function(a, b) { + if (null != a && null != a.df) { + return a.df(a, b); + } + var c = Lm[n(null == a ? null : a)]; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + c = Lm._; + if (null != c) { + return c.f ? c.f(a, b) : c.call(null, a, b); + } + throw v("IToCursor.-to-cursor", a); +}; +Lm.h = function(a, b, c) { + if (null != a && null != a.ef) { + return a.ef(a, b, c); + } + var d = Lm[n(null == a ? null : a)]; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + d = Lm._; + if (null != d) { + return d.h ? d.h(a, b, c) : d.call(null, a, b, c); + } + throw v("IToCursor.-to-cursor", a); +}; +Lm.F = 3; +var Mm = function Mm(b, c, d, e) { + if (null != b && null != b.Se) { + return b.Se(b, c, d, e); + } + var f = Mm[n(null == b ? null : b)]; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + f = Mm._; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + throw v("ICursorDerive.-derive", b); +}; +Mm._ = function(a, b, c, d) { + return Nm ? Nm(b, c, d) : Om.call(null, b, c, d); +}; +function Pm(a) { + return Jm(a); +} +function Qm() { +} +var Rm = function Rm(b, c, d, e) { + if (null != b && null != b.xc) { + return b.xc(b, c, d, e); + } + var f = Rm[n(null == b ? null : b)]; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + f = Rm._; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + throw v("ITransact.-transact!", b); +}; +function Sm() { +} +var Tm = function Tm(b, c, d) { + if (null != b && null != b.Id) { + return b.Id(b, c, d); + } + var e = Tm[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Tm._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("INotify.-listen!", b); +}, Um = function Um(b, c) { + if (null != b && null != b.Kd) { + return b.Kd(b, c); + } + var d = Um[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Um._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("INotify.-unlisten!", b); +}, Vm = function Vm(b, c, d) { + if (null != b && null != b.Jd) { + return b.Jd(b, c, d); + } + var e = Vm[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Vm._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("INotify.-notify!", b); +}, Xm = function Xm(b, c, d, e) { + if (null != b && null != b.Qd) { + return b.Qd(b, c, d, e); + } + var f = Xm[n(null == b ? null : b)]; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + f = Xm._; + if (null != f) { + return f.w ? f.w(b, c, d, e) : f.call(null, b, c, d, e); + } + throw v("IRootProperties.-set-property!", b); +}, Ym = function Ym(b, c) { + if (null != b && null != b.Pd) { + return b.Pd(b, c); + } + var d = Ym[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = Ym._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IRootProperties.-remove-properties!", b); +}, Zm = function Zm(b, c, d) { + if (null != b && null != b.Od) { + return b.Od(b, c, d); + } + var e = Zm[n(null == b ? null : b)]; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + e = Zm._; + if (null != e) { + return e.h ? e.h(b, c, d) : e.call(null, b, c, d); + } + throw v("IRootProperties.-get-property", b); +}, $m = function $m(b, c) { + if (null != b && null != b.Bd) { + return b.Bd(b, c); + } + var d = $m[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = $m._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IAdapt.-adapt", b); +}; +$m._ = function(a, b) { + return b; +}; +var an = function an(b, c) { + if (null != b && null != b.Xe) { + return b.Xe(b, c); + } + var d = an[n(null == b ? null : b)]; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + d = an._; + if (null != d) { + return d.f ? d.f(b, c) : d.call(null, b, c); + } + throw v("IOmRef.-remove-dep!", b); +}; +function bn(a, b, c, d, e) { + var f = I.c ? I.c(a) : I.call(null, a), h = df(Im(b), c); + c = (null != a ? a.Rf || (a.R ? 0 : t(ym, a)) : t(ym, a)) ? zm(a, b, c, d, e) : Ld(h) ? Ye.f(a, d) : Ye.w(a, hf, h, d); + if (H.f(c, Qi)) { + return null; + } + a = new ib(null, 5, [lh, h, Sh, ef(f, h), nh, ef(I.c ? I.c(a) : I.call(null, a), h), kh, f, xh, I.c ? I.c(a) : I.call(null, a)], null); + return null != e ? (e = S.h(a, Hi, e), cn.f ? cn.f(b, e) : cn.call(null, b, e)) : cn.f ? cn.f(b, a) : cn.call(null, b, a); +} +function dn(a) { + return null != a ? a.Sc ? !0 : a.R ? !1 : t(Hm, a) : t(Hm, a); +} +function en(a) { + return a.isOmComponent; +} +function fn(a) { + var b = a.props.children; + return Wd(b) ? a.props.children = b.c ? b.c(a) : b.call(null, a) : b; +} +function gn(a) { + if (!q(en(a))) { + throw Error("Assert failed: (component? x)"); + } + return a.props.__om_cursor; +} +function hn(a) { + if (!q(en(a))) { + throw Error("Assert failed: (component? owner)"); + } + return Am.c(a); +} +function jn(a, b) { + if (!q(en(a))) { + throw Error("Assert failed: (component? owner)"); + } + var c = Nd(b) ? b : new V(null, 1, 5, W, [b], null); + return Am.f(a, c); +} +function kn() { + var a = Vl; + return null == a ? null : a.props.__om_shared; +} +function ln(a) { + a = a.state; + var b = a.__om_pending_state; + return q(b) ? (a.__om_prev_state = a.__om_state, a.__om_state = b, a.__om_pending_state = null, a) : null; +} +function mn(a, b) { + var c = q(b) ? b : a.props, d = c.__om_state; + if (q(d)) { + var e = a.state, f = e.__om_pending_state; + e.__om_pending_state = Hg.A(O([q(f) ? f : e.__om_state, d], 0)); + c.__om_state = null; + } +} +function nn(a) { + a = a.state; + var b = a.__om_refs; + return 0 === K(b) ? null : a.__om_refs = df(Lg, bf(ob, X.f(function() { + return function(a) { + var b = Gm(a), e = Jm(a), f = Im(a), h = ff(I.c ? I.c(e) : I.call(null, e), f, qh); + Ie(b, qh) ? Ie(b, h) && (b = Nm ? Nm(h, e, f) : Om.call(null, h, e, f), a = $m(a, b)) : a = null; + return a; + }; + }(a, b), b))); +} +var pn = Cd([th, Hh, ci, di, hi, li, ri, ui, Ei, Ji, Oi], [function(a) { + var b = fn(this); + if (null != b ? b.Tc || (b.R ? 0 : t(nm, b)) : t(nm, b)) { + var c = this.state; + a = gn({props:a, isOmComponent:!0}); + var d = c.__om_prev_state; + om(b, a, q(d) ? d : c.__om_state); + } + return this.state.__om_prev_state = null; +}, !0, function() { + var a = fn(this); + (null != a ? a.gf || (a.R ? 0 : t(jm, a)) : t(jm, a)) && km(a); + if (a = B(this.state.__om_refs)) { + for (var a = B(a), b = null, c = 0, d = 0;;) { + if (d < c) { + var e = b.K(null, d); + on.f ? on.f(this, e) : on.call(null, this, e); + d += 1; + } else { + if (a = B(a)) { + b = a, Qd(b) ? (a = Fc(b), c = Gc(b), b = a, e = K(a), a = c, c = e) : (e = D(b), on.f ? on.f(this, e) : on.call(null, this, e), a = G(b), b = null, c = 0), d = 0; + } else { + return null; + } + } + } + } else { + return null; + } +}, function(a) { + var b = fn(this); + return (null != b ? b.$f || (b.R ? 0 : t(pm, b)) : t(pm, b)) ? qm(b, gn({props:a, isOmComponent:!0})) : null; +}, function(a) { + var b = this, c = b.props, d = b.state, e = fn(b); + mn(b, a); + if (null != e ? e.Yf || (e.R ? 0 : t(dm, e)) : t(dm, e)) { + return em(e, gn({props:a, isOmComponent:!0}), Am.c(b)); + } + var f = c.__om_cursor, h = a.__om_cursor; + return Ie(Gm(f), Gm(h)) ? !0 : q(function() { + var a = dn(f); + return q(a) ? (a = dn(h), q(a) ? Ie(Im(f), Im(h)) : a) : a; + }()) ? !0 : Ie(Am.c(b), Bm.c(b)) ? !0 : q(function() { + var a = 0 !== K(d.__om_refs); + return a ? Pe(function() { + return function(a) { + var b = Gm(a), c; + c = Jm(a); + c = I.c ? I.c(c) : I.call(null, c); + a = ff(c, Im(a), qh); + return Ie(b, a); + }; + }(a, f, h, c, d, e, b), d.__om_refs) : a; + }()) ? !0 : c.__om_index !== a.__om_index ? !0 : !1; +}, function() { + var a = fn(this), b = this.props, c = Vl, d = Yl, e = Wl, f = Xl, h = Zl; + Vl = this; + Yl = b.__om_app_state; + Wl = b.__om_instrument; + Xl = b.__om_descriptor; + Zl = b.__om_root_key; + try { + return (null != a ? a.Ze || (a.R ? 0 : t(rm, a)) : t(rm, a)) ? sm(a) : (null != a ? a.af || (a.R ? 0 : t(tm, a)) : t(tm, a)) ? um(a, b.__om_cursor, hn(this)) : (null != a ? a.Vc || (a.R ? 0 : t(vm, a)) : t(vm, a)) ? wm(a, hn(this)) : a; + } finally { + Zl = h, Xl = f, Wl = e, Yl = d, Vl = c; + } +}, function(a) { + var b = fn(this); + (null != b ? b.Wd || (b.R ? 0 : t(lm, b)) : t(lm, b)) && mm(b, gn({props:a, isOmComponent:!0}), Am.c(this)); + ln(this); + return nn(this); +}, function() { + var a = fn(this), b = this.props, c; + c = b.__om_init_state; + c = q(c) ? c : Ne; + var d = Ch.c(c), a = {__om_id:q(d) ? d : Wi(), __om_state:Hg.A(O([(null != a ? a.Gd || (a.R ? 0 : t(bm, a)) : t(bm, a)) ? cm(a) : null, Dd.f(c, Ch)], 0))}; + b.__om_init_state = null; + return a; +}, function() { + var a = fn(this); + return (null != a ? a.Te || (a.R ? 0 : t(hm, a)) : t(hm, a)) ? im(a) : null; +}, function() { + var a = fn(this); + return (null != a ? a.Of || (a.R ? 0 : t($l, a)) : t($l, a)) ? am(a) : null; +}, function() { + mn(this, null); + var a = fn(this); + (null != a ? a.Ud || (a.R ? 0 : t(fm, a)) : t(fm, a)) && gm(a); + return ln(this); +}]), qn = function(a) { + a.Xf = !0; + a.Rd = function() { + return function(a, c, d) { + a = this.props.__om_app_state; + this.state.__om_pending_state = c; + c = null != a; + return q(c ? d : c) ? Em(a, this) : null; + }; + }(a); + a.Sd = function() { + return function(a, c, d, e) { + var f = this.props; + a = this.state; + var h = Am.c(this), f = f.__om_app_state; + a.__om_pending_state = gf(h, c, d); + c = null != f; + return q(c ? e : c) ? Em(f, this) : null; + }; + }(a); + a.Pf = !0; + a.Cd = function() { + return function() { + return this.state.__om_state; + }; + }(a); + a.Dd = function() { + return function(a, c) { + return ef(Bm.c(this), c); + }; + }(a); + a.Qf = !0; + a.Ed = function() { + return function() { + var a = this.state, c = a.__om_pending_state; + return q(c) ? c : a.__om_state; + }; + }(a); + a.Fd = function() { + return function(a, c) { + return ef(Am.c(this), c); + }; + }(a); + return a; +}(ih(pn)); +function rn(a) { + a = sn ? sn(a) : tn.call(null, a); + a = Ul && a.dataset ? "reactid" in a.dataset ? a.dataset.reactid : null : a.getAttribute("data-" + "reactid".replace(/([A-Z])/g, "-$1").toLowerCase()); + if (!q(a)) { + throw Error("Assert failed: id"); + } + return a; +} +function un(a) { + return a.props.__om_app_state; +} +function vn(a) { + var b = un(a); + a = new V(null, 2, 5, W, [mh, rn(a)], null); + var c = ef(I.c ? I.c(b) : I.call(null, b), a); + return q(ai.c(c)) ? Ye.w(b, hf, a, function() { + return function(a) { + return Dd.f(S.h(S.h(a, oi, Ri.c(a)), Ri, Hg.A(O([Ri.c(a), ai.c(a)], 0))), ai); + }; + }(b, a, c)) : null; +} +S.A(pn, ui, function() { + var a = fn(this), b = this.props, c = function() { + var a = b.__om_init_state; + return q(a) ? a : Ne; + }(), d = function() { + var a = Ch.c(c); + return q(a) ? a : Wi(); + }(); + Hg.A(O([Dd.f(c, Ch), (null != a ? a.Gd || (a.R ? 0 : t(bm, a)) : t(bm, a)) ? cm(a) : null], 0)); + b.__om_init_state = null; + return {__om_id:d}; +}, O([Ei, function() { + var a = fn(this), b = new V(null, 3, 5, W, [mh, rn(this), Ri], null); + Ye.w(un(this), gf, b, Pm); + return (null != a ? a.Te || (a.R ? 0 : t(hm, a)) : t(hm, a)) ? im(a) : null; +}, Oi, function() { + mn(this, null); + var a = fn(this); + (null != a ? a.Ud || (a.R ? 0 : t(fm, a)) : t(fm, a)) && gm(a); + return q(wn.c ? wn.c(this) : wn.call(null, this)) ? vn(this) : null; +}, ci, function() { + var a = fn(this); + (null != a ? a.gf || (a.R ? 0 : t(jm, a)) : t(jm, a)) && km(a); + Ye.A(un(this), hf, new V(null, 1, 5, W, [mh], null), Dd, O([rn(this)], 0)); + if (a = B(this.state.__om_refs)) { + for (var a = B(a), b = null, c = 0, d = 0;;) { + if (d < c) { + var e = b.K(null, d); + on.f ? on.f(this, e) : on.call(null, this, e); + d += 1; + } else { + if (a = B(a)) { + b = a, Qd(b) ? (a = Fc(b), c = Gc(b), b = a, e = K(a), a = c, c = e) : (e = D(b), on.f ? on.f(this, e) : on.call(null, this, e), a = G(b), b = null, c = 0), d = 0; + } else { + return null; + } + } + } + } else { + return null; + } +}, ri, function(a) { + var b = fn(this); + (null != b ? b.Wd || (b.R ? 0 : t(lm, b)) : t(lm, b)) && mm(b, gn({props:a, isOmComponent:!0}), Am.c(this)); + vn(this); + return nn(this); +}, th, function(a) { + var b = fn(this), c = un(this), d = ef(I.c ? I.c(c) : I.call(null, c), new V(null, 2, 5, W, [mh, rn(this)], null)), e = new V(null, 2, 5, W, [mh, rn(this)], null); + if (null != b ? b.Tc || (b.R ? 0 : t(nm, b)) : t(nm, b)) { + a = gn({props:a, isOmComponent:!0}); + var f; + f = oi.c(d); + f = q(f) ? f : Ri.c(d); + om(b, a, f); + } + return q(oi.c(d)) ? Ye.A(c, hf, e, Dd, O([oi], 0)) : null; +}], 0)); +function xn(a, b, c) { + this.value = a; + this.state = b; + this.path = c; + this.m = 2163640079; + this.C = 8192; +} +g = xn.prototype; +g.O = function(a, b) { + return Sb.h(this, b, null); +}; +g.J = function(a, b, c) { + a = Sb.h(this.value, b, qh); + return H.f(a, qh) ? c : Mm(this, a, this.state, xd.f(this.path, b)); +}; +g.S = function(a, b, c) { + return uc(this.value, b, c); +}; +g.Sc = !0; +g.vc = function() { + return this.path; +}; +g.wc = function() { + return this.state; +}; +g.M = function() { + return Jd(this.value); +}; +g.ra = function() { + return new xn(this.value, this.state, this.path); +}; +g.Y = function() { + return Gb(this.value); +}; +g.U = function() { + return Wc(this.value); +}; +g.B = function(a, b) { + return q(dn(b)) ? H.f(this.value, Gm(b)) : H.f(this.value, b); +}; +g.Td = function() { + return this.value; +}; +g.Z = function() { + return new xn(Ad(this.value), this.state, this.path); +}; +g.mc = function(a, b) { + return new xn(Wb(this.value, b), this.state, this.path); +}; +g.Xc = !0; +g.xc = function(a, b, c, d) { + return bn(this.state, this, b, c, d); +}; +g.Rb = function(a, b) { + return Tb(this.value, b); +}; +g.nb = function(a, b, c) { + return new xn(Ub(this.value, b, c), this.state, this.path); +}; +g.X = function() { + var a = this; + return 0 < K(a.value) ? X.f(function(b) { + return function(c) { + var d = P(c, 0, null); + c = P(c, 1, null); + return new V(null, 2, 5, W, [d, Mm(b, c, a.state, xd.f(a.path, d))], null); + }; + }(this), a.value) : null; +}; +g.P = function(a, b) { + return new xn(Id(this.value, b), this.state, this.path); +}; +g.W = function(a, b) { + return new xn(Lb(this.value, b), this.state, this.path); +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +g.Cb = function() { + return ff(I.c ? I.c(this.state) : I.call(null, this.state), this.path, Gi); +}; +function yn(a, b, c) { + this.value = a; + this.state = b; + this.path = c; + this.m = 2180424479; + this.C = 8192; +} +g = yn.prototype; +g.O = function(a, b) { + return y.h(this, b, null); +}; +g.J = function(a, b, c) { + return y.h(this, b, c); +}; +g.K = function(a, b) { + return Mm(this, y.f(this.value, b), this.state, xd.f(this.path, b)); +}; +g.sa = function(a, b, c) { + return b < Gb(this.value) ? Mm(this, y.h(this.value, b, c), this.state, xd.f(this.path, b)) : c; +}; +g.S = function(a, b, c) { + return uc(this.value, b, c); +}; +g.Sc = !0; +g.vc = function() { + return this.path; +}; +g.wc = function() { + return this.state; +}; +g.M = function() { + return Jd(this.value); +}; +g.ra = function() { + return new yn(this.value, this.state, this.path); +}; +g.Y = function() { + return Gb(this.value); +}; +g.ob = function() { + return Mm(this, cc(this.value), this.state, this.path); +}; +g.pb = function() { + return Mm(this, dc(this.value), this.state, this.path); +}; +g.U = function() { + return Wc(this.value); +}; +g.B = function(a, b) { + return q(dn(b)) ? H.f(this.value, Gm(b)) : H.f(this.value, b); +}; +g.Td = function() { + return this.value; +}; +g.Z = function() { + return new yn(Ad(this.value), this.state, this.path); +}; +g.Xc = !0; +g.xc = function(a, b, c, d) { + return bn(this.state, this, b, c, d); +}; +g.Rb = function(a, b) { + return Tb(this.value, b); +}; +g.nb = function(a, b, c) { + return Mm(this, fc(this.value, b, c), this.state, this.path); +}; +g.X = function() { + var a = this; + return 0 < K(a.value) ? X.h(function(b) { + return function(c, d) { + return Mm(b, c, a.state, xd.f(a.path, d)); + }; + }(this), a.value, new Og(null, 0, Number.MAX_VALUE, 1, null)) : null; +}; +g.P = function(a, b) { + return new yn(Id(this.value, b), this.state, this.path); +}; +g.W = function(a, b) { + return new yn(Lb(this.value, b), this.state, this.path); +}; +g.call = function() { + var a = null, a = function(a, c, d) { + switch(arguments.length) { + case 2: + return this.O(null, c); + case 3: + return this.J(null, c, d); + } + throw Error("Invalid arity: " + arguments.length); + }; + a.f = function(a, c) { + return this.O(null, c); + }; + a.h = function(a, c, d) { + return this.J(null, c, d); + }; + return a; +}(); +g.apply = function(a, b) { + return this.call.apply(this, [this].concat(vb(b))); +}; +g.c = function(a) { + return this.O(null, a); +}; +g.f = function(a, b) { + return this.J(null, a, b); +}; +g.Cb = function() { + return ff(I.c ? I.c(this.state) : I.call(null, this.state), this.path, Gi); +}; +function zn(a, b, c) { + var d = Eb(a); + d.Af = !0; + d.Cb = function() { + return function() { + return ff(I.c ? I.c(b) : I.call(null, b), c, Gi); + }; + }(d); + d.Sc = !0; + d.vc = function() { + return function() { + return c; + }; + }(d); + d.wc = function() { + return function() { + return b; + }; + }(d); + d.Xc = !0; + d.xc = function() { + return function(a, c, d, k) { + return bn(b, this, c, d, k); + }; + }(d); + d.pe = !0; + d.B = function() { + return function(b, c) { + return q(dn(c)) ? H.f(a, Gm(c)) : H.f(a, c); + }; + }(d); + return d; +} +function Om(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return Nm(arguments[0], null, zd); + case 2: + return Nm(arguments[0], arguments[1], zd); + case 3: + return Nm(arguments[0], arguments[1], arguments[2]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function Nm(a, b, c) { + return q(dn(a)) ? a : (null != a ? a.Zf || (a.R ? 0 : t(Km, a)) : t(Km, a)) ? Lm.h(a, b, c) : rd(a) ? new yn(a, b, c) : Od(a) ? new xn(a, b, c) : (null != a ? a.C & 8192 || a.ke || (a.C ? 0 : t(Db, a)) : t(Db, a)) ? zn(a, b, c) : a; +} +function cn(a, b) { + var c = Jm(a), d; + d = I.c ? I.c(c) : I.call(null, c); + d = Nm(d, c, zd); + return Vm(c, b, d); +} +var An = Ue ? Ue(Ne) : Te.call(null, Ne); +function on(a, b) { + var c = a.state, d = c.__om_refs; + Xd(d, b) && (c.__om_refs = Kd.f(d, b)); + an(b, a); + return b; +} +var Bn = !1, Cn = Ue ? Ue(Lg) : Te.call(null, Lg); +function Dn(a) { + Bn = !1; + for (var b = B(I.c ? I.c(Cn) : I.call(null, Cn)), c = null, d = 0, e = 0;;) { + if (e < d) { + var f = c.K(null, e); + f.D ? f.D() : f.call(null); + e += 1; + } else { + if (b = B(b)) { + c = b, Qd(c) ? (b = Fc(c), e = Gc(c), c = b, d = K(b), b = e) : (b = D(c), b.D ? b.D() : b.call(null), b = G(c), c = null, d = 0), e = 0; + } else { + break; + } + } + } + null == a ? a = null : (b = a.jf, a = a.jf = (q(b) ? b : 0) + 1); + return a; +} +var En = Ue ? Ue(Ne) : Te.call(null, Ne); +function Fn(a, b) { + var c; + c = null != a ? a.Ze ? !0 : a.R ? !1 : t(rm, a) : t(rm, a); + c || (c = (c = null != a ? a.af ? !0 : a.R ? !1 : t(tm, a) : t(tm, a)) ? c : null != a ? a.Vc ? !0 : a.R ? !1 : t(vm, a) : t(vm, a)); + if (!c) { + throw Error([w("Assert failed: "), w([w("Invalid Om component fn, "), w(b.name), w(" does not return valid instance")].join("")), w("\n"), w("(or (satisfies? IRender x) (satisfies? IRenderProps x) (satisfies? IRenderState x))")].join("")); + } +} +function Gn(a, b) { + var c = function() { + if (q(b)) { + return b; + } + var a = Xl; + return q(a) ? a : qn; + }(); + if (null == Da(a, "om$descriptor") || c !== Da(a, "om$tag")) { + var d = function() { + var a = React.createClass(c); + return React.createFactory(a); + }(); + a.om$descriptor = d; + a.om$tag = c; + } + return Da(a, "om$descriptor"); +} +function Hn(a, b, c) { + if (!Wd(a)) { + throw Error("Assert failed: (ifn? f)"); + } + if (null != c && !Od(c)) { + throw Error("Assert failed: (or (nil? m) (map? m))"); + } + if (!q(Oe(new Jg(null, new ib(null, 11, [oh, null, vh, null, zh, null, Ah, null, Eh, null, Xh, null, $h, null, ji, null, wi, null, Bi, null, Ci, null], null), null), Wf(c)))) { + throw Error([w("Assert failed: "), w(Fe(w, "build options contains invalid keys, only :key, :key-fn :react-key, ", ":fn, :init-state, :state, and :opts allowed, given ", Ze(af.f($e(", "), Wf(c))))), w("\n"), w("(valid-opts? m)")].join("")); + } + if (null == c) { + var d = kn(), e = Gn(a, null), d = {__om_cursor:b, __om_shared:d, __om_root_key:Zl, __om_app_state:Yl, __om_descriptor:Xl, __om_instrument:Wl, children:function() { + return function(c) { + c = a.f ? a.f(b, c) : a.call(null, b, c); + Fn(c, a); + return c; + }; + }(d, e)}; + return e.c ? e.c(d) : e.call(null, d); + } + var f = null != c && (c.m & 64 || c.na) ? Be(Ve, c) : c, h = z.f(f, Eh), k = z.f(f, ji), l = z.f(f, $h), m = z.f(f, Xh), p = z.f(f, wi), r = z.f(c, vh), u = null != r ? function() { + var a = Bi.c(c); + return q(a) ? r.f ? r.f(b, a) : r.call(null, b, a) : r.c ? r.c(b) : r.call(null, b); + }() : b, x = null != h ? z.f(u, h) : null != k ? k.c ? k.c(u) : k.call(null, u) : z.f(c, Ah), d = function() { + var a = Ci.c(c); + return q(a) ? a : kn(); + }(), e = Gn(a, oh.c(c)), E; + E = q(x) ? x : void 0; + d = {__om_state:l, __om_instrument:Wl, children:null == p ? function(b, c, d, e, f, h, k, l, m) { + return function(b) { + b = a.f ? a.f(m, b) : a.call(null, m, b); + Fn(b, a); + return b; + }; + }(c, f, h, k, l, m, p, r, u, x, d, e) : function(b, c, d, e, f, h, k, l, m) { + return function(b) { + b = a.h ? a.h(m, b, k) : a.call(null, m, b, k); + Fn(b, a); + return b; + }; + }(c, f, h, k, l, m, p, r, u, x, d, e), __om_init_state:m, key:E, __om_app_state:Yl, __om_cursor:u, __om_index:Bi.c(c), __om_shared:d, __om_descriptor:Xl, __om_root_key:Zl}; + return e.c ? e.c(d) : e.call(null, d); +} +function In(a, b, c) { + if (!Wd(a)) { + throw Error("Assert failed: (ifn? f)"); + } + if (null != c && !Od(c)) { + throw Error("Assert failed: (or (nil? m) (map? m))"); + } + if (null != Wl) { + var d = Wl.h ? Wl.h(a, b, c) : Wl.call(null, a, b, c); + return H.f(d, Vh) ? Hn(a, b, c) : d; + } + return Hn(a, b, c); +} +function Jn(a, b) { + var c = Kn; + if (!Wd(c)) { + throw Error("Assert failed: (ifn? f)"); + } + if (null != b && !Od(b)) { + throw Error("Assert failed: (or (nil? m) (map? m))"); + } + return X.h(function(a, e) { + return In(c, a, S.h(b, Bi, e)); + }, a, new Og(null, 0, Number.MAX_VALUE, 1, null)); +} +function Ln(a, b, c) { + if (!(null != a ? a.We || (a.R ? 0 : t(Sm, a)) : t(Sm, a))) { + var d = Ue ? Ue(Ne) : Te.call(null, Ne), e = Ue ? Ue(Ne) : Te.call(null, Ne), f = Ue ? Ue(Lg) : Te.call(null, Lg); + a.Vf = !0; + a.Qd = function(a, b) { + return function(a, c, d, e) { + return Ye.w(b, gf, new V(null, 2, 5, W, [c, d], null), e); + }; + }(a, d, e, f); + a.Wf = function(a, b) { + return function(a, c, d) { + return Ye.w(b, Dd, c, d); + }; + }(a, d, e, f); + a.Pd = function(a, b) { + return function(a, c) { + return Ye.h(b, Dd, c); + }; + }(a, d, e, f); + a.Od = function(a, b) { + return function(a, c, d) { + return ef(I.c ? I.c(b) : I.call(null, b), new V(null, 2, 5, W, [c, d], null)); + }; + }(a, d, e, f); + a.We = !0; + a.Id = function(a, b, c) { + return function(a, b, d) { + null != d && Ye.w(c, S, b, d); + return this; + }; + }(a, d, e, f); + a.Kd = function(a, b, c) { + return function(a, b) { + Ye.h(c, Dd, b); + return this; + }; + }(a, d, e, f); + a.Jd = function(a, b, c) { + return function(a, b, d) { + a = B(I.c ? I.c(c) : I.call(null, c)); + for (var e = null, f = 0, h = 0;;) { + if (h < f) { + var k = e.K(null, h); + P(k, 0, null); + k = P(k, 1, null); + k.f ? k.f(b, d) : k.call(null, b, d); + h += 1; + } else { + if (a = B(a)) { + Qd(a) ? (f = Fc(a), a = Gc(a), e = f, f = K(f)) : (e = D(a), P(e, 0, null), e = P(e, 1, null), e.f ? e.f(b, d) : e.call(null, b, d), a = G(a), e = null, f = 0), h = 0; + } else { + break; + } + } + } + return this; + }; + }(a, d, e, f); + a.Sf = !0; + a.Md = function(a, b, c, d) { + return function() { + return I.c ? I.c(d) : I.call(null, d); + }; + }(a, d, e, f); + a.Nd = function(a, b, c, d) { + return function(a, b) { + if (Xd(I.c ? I.c(d) : I.call(null, d), b)) { + return null; + } + Ye.h(d, xd, b); + return Ye.f(this, ae); + }; + }(a, d, e, f); + a.Ld = function(a, b, c, d) { + return function() { + return Ye.f(d, Ad); + }; + }(a, d, e, f); + } + return Tm(a, b, c); +} +var Mn = function Mn(b, c) { + if (q(dn(b))) { + var d = Eb(b); + d.ke = !0; + d.ra = function() { + return function() { + return Mn(Eb(b), c); + }; + }(d); + d.Nf = !0; + d.Bd = function() { + return function(d, f) { + return Mn($m(b, f), c); + }; + }(d); + d.Tf = !0; + d.Uf = function() { + return function() { + return c; + }; + }(d); + return d; + } + return b; +}; +function Nn(a, b, c) { + return On(a, b, c, null); +} +function On(a, b, c, d) { + var e; + e = null != a ? a.Xc ? !0 : a.R ? !1 : t(Qm, a) : t(Qm, a); + if (!q(e)) { + throw Error("Assert failed: (transactable? cursor)"); + } + if (!Wd(c)) { + throw Error("Assert failed: (ifn? f)"); + } + b = null == b ? zd : Nd(b) ? b : new V(null, 1, 5, W, [b], null); + return Rm(a, b, c, d); +} +function Pn(a, b, c) { + if (!q(dn(a))) { + throw Error("Assert failed: (cursor? cursor)"); + } + return On(a, b, function() { + return c; + }, null); +} +function tn(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + switch(b.length) { + case 1: + return sn(arguments[0]); + case 2: + return Qn(arguments[0], arguments[1]); + default: + throw Error([w("Invalid arity: "), w(b.length)].join(""));; + } +} +function sn(a) { + return ReactDOM.findDOMNode(a); +} +function Qn(a, b) { + if ("string" !== typeof b) { + throw Error("Assert failed: (string? name)"); + } + var c = a.refs, c = null == c ? null : c[b]; + return null == c ? null : ReactDOM.findDOMNode(c); +} +function wn(a) { + return a.isMounted(); +} +function Rn(a, b, c) { + if (!q(en(a))) { + throw Error("Assert failed: (component? owner)"); + } + b = Nd(b) ? b : new V(null, 1, 5, W, [b], null); + return Cm.w(a, b, c, !0); +} +;function Sn(a) { + var b = Tn; + a = "/(?:)/" === "" + w(b) ? xd.f(Af(N("", X.f(w, B(a)))), "") : Af(("" + w(a)).split(b)); + if (1 < K(a)) { + a: { + for (;;) { + if ("" === (null == a ? null : cc(a))) { + a = null == a ? null : dc(a); + } else { + break a; + } + } + } + } + return a; +} +;var Un; +function Vn(a, b, c) { + b = jn(b, Uh); + q(b) && (oa(za(b.trim())) ? al(c, new V(null, 2, 5, W, [Th, a], null)) : (Pn(a, gi, b), al(c, new V(null, 2, 5, W, [bi, a], null)))); + return !1; +} +var Kn = function Kn(b, c) { + "undefined" === typeof Un && (Un = function(b, c, f, h) { + this.uf = b; + this.va = c; + this.ua = f; + this.Me = h; + this.m = 393216; + this.C = 0; + }, Un.prototype.P = function(b, c) { + return new Un(this.uf, this.va, this.ua, c); + }, Un.prototype.M = function() { + return this.Me; + }, Un.prototype.Gd = !0, Un.prototype.Hd = function() { + return new ib(null, 1, [Uh, gi.c(this.va)], null); + }, Un.prototype.Tc = !0, Un.prototype.Uc = function() { + var b; + b = ki.c(this.va); + b = q(b) ? jn(this.ua, Ai) : b; + if (q(b)) { + b = Qn(this.ua, "editField"); + var c = b.value.length; + b.focus(); + b.setSelectionRange(c, c); + return Rn(this.ua, Ai, null); + } + return null; + }, Un.prototype.Vc = !0, Un.prototype.Wc = function(b, c) { + var f = this, h = null != c && (c.m & 64 || c.na) ? Be(Ve, c) : c, k = z.f(h, Qh), l = this, m = function() { + var b = q(Oh.c(f.va)) ? [w(""), w("completed ")].join("") : ""; + return q(ki.c(f.va)) ? [w(b), w("editing")].join("") : b; + }(); + return Yj({className:m, style:Qj(qi.c(f.va))}, O([Vj({className:"view"}, O([function() { + var b = {className:"toggle", type:"checkbox", checked:function() { + var b = Oh.c(f.va); + return q(b) ? "checked" : b; + }(), onChange:function(b, c, d, e, h, k) { + return function() { + return Nn(f.va, Oh, function() { + return function(b) { + return qb(b); + }; + }(b, c, d, e, h, k)); + }; + }(m, l, c, h, h, k)}; + return dk.c ? dk.c(b) : dk.call(null, b); + }(), Xj({onDoubleClick:function(b, c, d, e, h, k) { + return function() { + var b = f.va, c = f.ua; + Qn(c, "editField"); + al(k, new V(null, 2, 5, W, [Ph, b], null)); + Rn(c, Ai, !0); + Rn(c, Uh, gi.c(b)); + return c; + }; + }(m, l, c, h, h, k)}, O([gi.c(f.va)], 0)), Tj({className:"destroy", onClick:function(b, c, d, e, h, k) { + return function() { + return al(k, new V(null, 2, 5, W, [Th, f.va], null)); + }; + }(m, l, c, h, h, k)})], 0)), function() { + var b = {ref:"editField", className:"edit", value:jn(f.ua, Uh), onBlur:function(b, c, d, e, h, k) { + return function() { + return Vn(f.va, f.ua, k); + }; + }(m, l, c, h, h, k), onChange:function() { + return function(b) { + return Rn(f.ua, Uh, b.target.value); + }; + }(m, l, c, h, h, k), onKeyDown:function(b, c, d, e, h, k) { + return function(b) { + var c; + c = f.va; + var d = f.ua; + b = b.keyCode; + q(fe ? nc(27, b) : ee.call(null, 27, b)) ? (Rn(d, Uh, gi.c(c)), c = al(k, new V(null, 2, 5, W, [Fi, c], null))) : c = q(fe ? nc(13, b) : ee.call(null, 13, b)) ? Vn(c, d, k) : null; + return c; + }; + }(m, l, c, h, h, k)}; + return dk.c ? dk.c(b) : dk.call(null, b); + }()], 0)); + }, Un.Wb = function() { + return new V(null, 4, 5, W, [Id(ph, new ib(null, 1, [Le, je(Me, je(new V(null, 2, 5, W, [Pi, yh], null)))], null)), Pi, yh, Za.Lf], null); + }, Un.qb = !0, Un.Za = "todomvc.item/t_todomvc$item18769", Un.Eb = function(b, c) { + return tc(c, "todomvc.item/t_todomvc$item18769"); + }); + return new Un(Kn, b, c, Ne); +}; +function Wn() { + 0 != Xn && (Yn[fa(this)] = this); + this.Vb = this.Vb; + this.wb = this.wb; +} +var Xn = 0, Yn = {}; +Wn.prototype.Vb = !1; +Wn.prototype.Lc = function() { + if (!this.Vb && (this.Vb = !0, this.ab(), 0 != Xn)) { + var a = fa(this); + delete Yn[a]; + } +}; +Wn.prototype.ab = function() { + if (this.wb) { + for (;this.wb.length;) { + this.wb.shift()(); + } + } +}; +function Zn(a) { + a && "function" == typeof a.Lc && a.Lc(); +} +;var $n = !dl || 9 <= Number(ql), ao = dl && !ol("9"); +!gl || ol("528"); +fl && ol("1.9b") || dl && ol("8") || cl && ol("9.5") || gl && ol("528"); +fl && !ol("8") || dl && ol("9"); +function bo(a, b) { + this.type = a; + this.currentTarget = this.target = b; + this.defaultPrevented = this.yb = !1; + this.Yd = !0; +} +bo.prototype.stopPropagation = function() { + this.yb = !0; +}; +bo.prototype.preventDefault = function() { + this.defaultPrevented = !0; + this.Yd = !1; +}; +function co(a, b) { + bo.call(this, a ? a.type : ""); + this.relatedTarget = this.currentTarget = this.target = null; + this.charCode = this.keyCode = this.button = this.screenY = this.screenX = this.clientY = this.clientX = this.offsetY = this.offsetX = 0; + this.metaKey = this.shiftKey = this.altKey = this.ctrlKey = !1; + this.Gb = this.state = null; + if (a) { + var c = this.type = a.type, d = a.changedTouches ? a.changedTouches[0] : null; + this.target = a.target || a.srcElement; + this.currentTarget = b; + var e = a.relatedTarget; + if (e) { + if (fl) { + var f; + a: { + try { + Ya(e.nodeName); + f = !0; + break a; + } catch (h) { + } + f = !1; + } + f || (e = null); + } + } else { + "mouseover" == c ? e = a.fromElement : "mouseout" == c && (e = a.toElement); + } + this.relatedTarget = e; + null === d ? (this.offsetX = gl || void 0 !== a.offsetX ? a.offsetX : a.layerX, this.offsetY = gl || void 0 !== a.offsetY ? a.offsetY : a.layerY, this.clientX = void 0 !== a.clientX ? a.clientX : a.pageX, this.clientY = void 0 !== a.clientY ? a.clientY : a.pageY, this.screenX = a.screenX || 0, this.screenY = a.screenY || 0) : (this.clientX = void 0 !== d.clientX ? d.clientX : d.pageX, this.clientY = void 0 !== d.clientY ? d.clientY : d.pageY, this.screenX = d.screenX || 0, this.screenY = d.screenY || + 0); + this.button = a.button; + this.keyCode = a.keyCode || 0; + this.charCode = a.charCode || ("keypress" == c ? a.keyCode : 0); + this.ctrlKey = a.ctrlKey; + this.altKey = a.altKey; + this.shiftKey = a.shiftKey; + this.metaKey = a.metaKey; + this.state = a.state; + this.Gb = a; + a.defaultPrevented && this.preventDefault(); + } +} +na(co, bo); +co.prototype.stopPropagation = function() { + co.Mb.stopPropagation.call(this); + this.Gb.stopPropagation ? this.Gb.stopPropagation() : this.Gb.cancelBubble = !0; +}; +co.prototype.preventDefault = function() { + co.Mb.preventDefault.call(this); + var a = this.Gb; + if (a.preventDefault) { + a.preventDefault(); + } else { + if (a.returnValue = !1, ao) { + try { + if (a.ctrlKey || 112 <= a.keyCode && 123 >= a.keyCode) { + a.keyCode = -1; + } + } catch (b) { + } + } + } +}; +var eo = "closure_listenable_" + (1E6 * Math.random() | 0), fo = 0; +function go(a, b, c, d, e) { + this.listener = a; + this.yc = null; + this.src = b; + this.type = c; + this.Qb = !!d; + this.Ja = e; + this.key = ++fo; + this.Kb = this.kc = !1; +} +function ho(a) { + a.Kb = !0; + a.listener = null; + a.yc = null; + a.src = null; + a.Ja = null; +} +;function io(a) { + this.src = a; + this.pa = {}; + this.ic = 0; +} +g = io.prototype; +g.add = function(a, b, c, d, e) { + var f = a.toString(); + a = this.pa[f]; + a || (a = this.pa[f] = [], this.ic++); + var h = jo(a, b, d, e); + -1 < h ? (b = a[h], c || (b.kc = !1)) : (b = new go(b, this.src, f, !!d, e), b.kc = c, a.push(b)); + return b; +}; +g.remove = function(a, b, c, d) { + a = a.toString(); + if (!(a in this.pa)) { + return !1; + } + var e = this.pa[a]; + b = jo(e, b, c, d); + return -1 < b ? (ho(e[b]), Array.prototype.splice.call(e, b, 1), 0 == e.length && (delete this.pa[a], this.ic--), !0) : !1; +}; +function ko(a, b) { + var c = b.type; + if (c in a.pa) { + var d = a.pa[c], e = Va(d, b), f; + (f = 0 <= e) && Array.prototype.splice.call(d, e, 1); + f && (ho(b), 0 == a.pa[c].length && (delete a.pa[c], a.ic--)); + } +} +g.zc = function(a) { + a = a && a.toString(); + var b = 0, c; + for (c in this.pa) { + if (!a || c == a) { + for (var d = this.pa[c], e = 0;e < d.length;e++) { + ++b, ho(d[e]); + } + delete this.pa[c]; + this.ic--; + } + } + return b; +}; +g.Yb = function(a, b, c, d) { + a = this.pa[a.toString()]; + var e = -1; + a && (e = jo(a, b, c, d)); + return -1 < e ? a[e] : null; +}; +g.hasListener = function(a, b) { + var c = void 0 !== a, d = c ? a.toString() : "", e = void 0 !== b; + return Ca(this.pa, function(a) { + for (var h = 0;h < a.length;++h) { + if (!(c && a[h].type != d || e && a[h].Qb != b)) { + return !0; + } + } + return !1; + }); +}; +function jo(a, b, c, d) { + for (var e = 0;e < a.length;++e) { + var f = a[e]; + if (!f.Kb && f.listener == b && f.Qb == !!c && f.Ja == d) { + return e; + } + } + return -1; +} +;var lo = "closure_lm_" + (1E6 * Math.random() | 0), mo = {}, no = 0; +function oo(a, b, c, d, e) { + if (ba(b)) { + for (var f = 0;f < b.length;f++) { + oo(a, b[f], c, d, e); + } + return null; + } + c = po(c); + if (a && a[eo]) { + a = a.vb(b, c, d, e); + } else { + if (!b) { + throw Error("Invalid event type"); + } + var f = !!d, h = qo(a); + h || (a[lo] = h = new io(a)); + c = h.add(b, c, !1, d, e); + if (!c.yc) { + d = ro(); + c.yc = d; + d.src = a; + d.listener = c; + if (a.addEventListener) { + a.addEventListener(b.toString(), d, f); + } else { + if (a.attachEvent) { + a.attachEvent(so(b.toString()), d); + } else { + throw Error("addEventListener and attachEvent are unavailable."); + } + } + no++; + } + a = c; + } + return a; +} +function ro() { + var a = to, b = $n ? function(c) { + return a.call(b.src, b.listener, c); + } : function(c) { + c = a.call(b.src, b.listener, c); + if (!c) { + return c; + } + }; + return b; +} +function uo(a, b, c, d, e) { + if (ba(b)) { + for (var f = 0;f < b.length;f++) { + uo(a, b[f], c, d, e); + } + } else { + c = po(c), a && a[eo] ? a.cd(b, c, d, e) : a && (a = qo(a)) && (b = a.Yb(b, c, !!d, e)) && vo(b); + } +} +function vo(a) { + if ("number" != typeof a && a && !a.Kb) { + var b = a.src; + if (b && b[eo]) { + ko(b.bb, a); + } else { + var c = a.type, d = a.yc; + b.removeEventListener ? b.removeEventListener(c, d, a.Qb) : b.detachEvent && b.detachEvent(so(c), d); + no--; + (c = qo(b)) ? (ko(c, a), 0 == c.ic && (c.src = null, b[lo] = null)) : ho(a); + } + } +} +function so(a) { + return a in mo ? mo[a] : mo[a] = "on" + a; +} +function wo(a, b, c, d) { + var e = !0; + if (a = qo(a)) { + if (b = a.pa[b.toString()]) { + for (b = b.concat(), a = 0;a < b.length;a++) { + var f = b[a]; + f && f.Qb == c && !f.Kb && (f = xo(f, d), e = e && !1 !== f); + } + } + } + return e; +} +function xo(a, b) { + var c = a.listener, d = a.Ja || a.src; + a.kc && vo(a); + return c.call(d, b); +} +function to(a, b) { + if (a.Kb) { + return !0; + } + if (!$n) { + var c; + if (!(c = b)) { + a: { + c = ["window", "event"]; + for (var d = aa, e;e = c.shift();) { + if (null != d[e]) { + d = d[e]; + } else { + c = null; + break a; + } + } + c = d; + } + } + e = c; + c = new co(e, this); + d = !0; + if (!(0 > e.keyCode || void 0 != e.returnValue)) { + a: { + var f = !1; + if (0 == e.keyCode) { + try { + e.keyCode = -1; + break a; + } catch (l) { + f = !0; + } + } + if (f || void 0 == e.returnValue) { + e.returnValue = !0; + } + } + e = []; + for (f = c.currentTarget;f;f = f.parentNode) { + e.push(f); + } + for (var f = a.type, h = e.length - 1;!c.yb && 0 <= h;h--) { + c.currentTarget = e[h]; + var k = wo(e[h], f, !0, c), d = d && k; + } + for (h = 0;!c.yb && h < e.length;h++) { + c.currentTarget = e[h], k = wo(e[h], f, !1, c), d = d && k; + } + } + return d; + } + return xo(a, new co(b, this)); +} +function qo(a) { + a = a[lo]; + return a instanceof io ? a : null; +} +var yo = "__closure_events_fn_" + (1E9 * Math.random() >>> 0); +function po(a) { + if (ea(a)) { + return a; + } + a[yo] || (a[yo] = function(b) { + return a.handleEvent(b); + }); + return a[yo]; +} +;function zo() { + Wn.call(this); + this.bb = new io(this); + this.ge = this; + this.Yc = null; +} +na(zo, Wn); +zo.prototype[eo] = !0; +g = zo.prototype; +g.addEventListener = function(a, b, c, d) { + oo(this, a, b, c, d); +}; +g.removeEventListener = function(a, b, c, d) { + uo(this, a, b, c, d); +}; +g.dispatchEvent = function(a) { + var b, c = this.Yc; + if (c) { + for (b = [];c;c = c.Yc) { + b.push(c); + } + } + var c = this.ge, d = a.type || a; + if (ca(a)) { + a = new bo(a, c); + } else { + if (a instanceof bo) { + a.target = a.target || c; + } else { + var e = a; + a = new bo(d, c); + Fa(a, e); + } + } + var e = !0, f; + if (b) { + for (var h = b.length - 1;!a.yb && 0 <= h;h--) { + f = a.currentTarget = b[h], e = Ao(f, d, !0, a) && e; + } + } + a.yb || (f = a.currentTarget = c, e = Ao(f, d, !0, a) && e, a.yb || (e = Ao(f, d, !1, a) && e)); + if (b) { + for (h = 0;!a.yb && h < b.length;h++) { + f = a.currentTarget = b[h], e = Ao(f, d, !1, a) && e; + } + } + return e; +}; +g.ab = function() { + zo.Mb.ab.call(this); + this.bb && this.bb.zc(void 0); + this.Yc = null; +}; +g.vb = function(a, b, c, d) { + return this.bb.add(String(a), b, !1, c, d); +}; +g.cd = function(a, b, c, d) { + return this.bb.remove(String(a), b, c, d); +}; +function Ao(a, b, c, d) { + b = a.bb.pa[String(b)]; + if (!b) { + return !0; + } + b = b.concat(); + for (var e = !0, f = 0;f < b.length;++f) { + var h = b[f]; + if (h && !h.Kb && h.Qb == c) { + var k = h.listener, l = h.Ja || h.src; + h.kc && ko(a.bb, h); + e = !1 !== k.call(l, d) && e; + } + } + return e && 0 != d.Yd; +} +g.Yb = function(a, b, c, d) { + return this.bb.Yb(String(a), b, c, d); +}; +g.hasListener = function(a, b) { + return this.bb.hasListener(void 0 !== a ? String(a) : void 0, b); +}; +function Bo(a, b) { + zo.call(this); + this.ac = a || 1; + this.Nb = b || aa; + this.Cc = ka(this.rf, this); + this.Rc = ma(); +} +na(Bo, zo); +g = Bo.prototype; +g.enabled = !1; +g.aa = null; +g.setInterval = function(a) { + this.ac = a; + this.aa && this.enabled ? (this.stop(), this.start()) : this.aa && this.stop(); +}; +g.rf = function() { + if (this.enabled) { + var a = ma() - this.Rc; + 0 < a && a < .8 * this.ac ? this.aa = this.Nb.setTimeout(this.Cc, this.ac - a) : (this.aa && (this.Nb.clearTimeout(this.aa), this.aa = null), this.dispatchEvent("tick"), this.enabled && (this.aa = this.Nb.setTimeout(this.Cc, this.ac), this.Rc = ma())); + } +}; +g.start = function() { + this.enabled = !0; + this.aa || (this.aa = this.Nb.setTimeout(this.Cc, this.ac), this.Rc = ma()); +}; +g.stop = function() { + this.enabled = !1; + this.aa && (this.Nb.clearTimeout(this.aa), this.aa = null); +}; +g.ab = function() { + Bo.Mb.ab.call(this); + this.stop(); + delete this.Nb; +}; +function Co(a) { + Wn.call(this); + this.xd = a; + this.bc = {}; +} +na(Co, Wn); +var Do = []; +g = Co.prototype; +g.vb = function(a, b, c, d) { + ba(b) || (b && (Do[0] = b.toString()), b = Do); + for (var e = 0;e < b.length;e++) { + var f = oo(a, b[e], c || this.handleEvent, d || !1, this.xd || this); + if (!f) { + break; + } + this.bc[f.key] = f; + } + return this; +}; +g.cd = function(a, b, c, d, e) { + if (ba(b)) { + for (var f = 0;f < b.length;f++) { + this.cd(a, b[f], c, d, e); + } + } else { + c = c || this.handleEvent, e = e || this.xd || this, c = po(c), d = !!d, b = a && a[eo] ? a.Yb(b, c, d, e) : a ? (a = qo(a)) ? a.Yb(b, c, d, e) : null : null, b && (vo(b), delete this.bc[b.key]); + } + return this; +}; +g.zc = function() { + Ba(this.bc, function(a, b) { + this.bc.hasOwnProperty(b) && vo(a); + }, this); + this.bc = {}; +}; +g.ab = function() { + Co.Mb.ab.call(this); + this.zc(); +}; +g.handleEvent = function() { + throw Error("EventHandler.handleEvent not implemented"); +}; +function Eo(a) { + bo.call(this, "navigate"); + this.vf = a; +} +na(Eo, bo); +function Fo(a, b) { + for (var c = [a], d = b.length - 1;0 <= d;--d) { + c.push(typeof b[d], b[d]); + } + return c.join("\x0B"); +} +;function Go(a, b, c, d) { + zo.call(this); + if (a && !b) { + throw Error("Can't use invisible history without providing a blank page."); + } + var e; + if (c) { + e = c; + } else { + e = "history_state" + Ho; + var f = Ol("input", {type:"text", name:e, id:e, style:vl("display:none")}); + document.write(Kl(f)); + e = Sl(e); + } + this.sc = e; + c = c ? (c = 9 == c.nodeType ? c : c.ownerDocument || c.document) ? c.parentWindow || c.defaultView : window : window; + this.gb = c; + this.Oc = b; + dl && !b && (this.Oc = "https" == window.location.protocol ? Hl(ul(vl("https:///"))) : Hl(ul(vl('javascript:""')))); + this.aa = new Bo(Io); + b = la(Zn, this.aa); + this.Vb ? b.call(void 0) : (this.wb || (this.wb = []), this.wb.push(b)); + this.Ob = !a; + this.sb = new Co(this); + if (a || Jo) { + var h; + if (d) { + h = d; + } else { + a = "history_iframe" + Ho; + c = this.Oc; + d = {id:a, style:vl("display:none"), sandbox:void 0}; + c && Gl(c); + b = {}; + b.src = c || null; + b.srcdoc = null; + c = {sandbox:""}; + e = {}; + for (h in b) { + e[h] = b[h]; + } + for (h in c) { + e[h] = c[h]; + } + for (h in d) { + f = h.toLowerCase(); + if (f in b) { + throw Error('Cannot override "' + f + '" attribute, got "' + h + '" with value "' + d[h] + '"'); + } + f in c && delete e[f]; + e[h] = d[h]; + } + h = Pl("iframe", e, void 0); + document.write(Kl(h)); + h = Sl(a); + } + this.tc = h; + this.ae = !0; + } + Jo && (this.sb.vb(this.gb, "load", this.kf), this.$d = this.Mc = !1); + this.Ob ? Ko(this, Lo(this), !0) : Mo(this, this.sc.value); + Ho++; +} +na(Go, zo); +Go.prototype.rc = !1; +Go.prototype.Jb = !1; +Go.prototype.cc = null; +var No = function(a, b) { + var c = b || Fo; + return function() { + var b = this || aa, b = b.closure_memoize_cache_ || (b.closure_memoize_cache_ = {}), e = c(fa(a), arguments); + return b.hasOwnProperty(e) ? b[e] : b[e] = a.apply(this, arguments); + }; +}(function() { + return dl ? 8 <= Number(ql) : "onhashchange" in aa; +}), Jo = dl && !(8 <= Number(ql)); +g = Go.prototype; +g.dc = null; +g.ab = function() { + Go.Mb.ab.call(this); + this.sb.Lc(); + Oo(this, !1); +}; +function Oo(a, b) { + if (b != a.rc) { + if (Jo && !a.Mc) { + a.$d = b; + } else { + if (b) { + if (cl ? a.sb.vb(a.gb.document, Po, a.nf) : fl && a.sb.vb(a.gb, "pageshow", a.mf), No() && a.Ob) { + a.sb.vb(a.gb, "hashchange", a.lf), a.rc = !0, a.dispatchEvent(new Eo(Lo(a))); + } else { + if (!dl || !(Z("iPad") || Z("Android") && !Z("Mobile") || Z("Silk")) && (Z("iPod") || Z("iPhone") || Z("Android") || Z("IEMobile")) || a.Mc) { + a.sb.vb(a.aa, "tick", ka(a.ie, a, !0)), a.rc = !0, Jo || (a.cc = Lo(a), a.dispatchEvent(new Eo(Lo(a)))), a.aa.start(); + } + } + } else { + a.rc = !1, a.sb.zc(), a.aa.stop(); + } + } + } +} +g.kf = function() { + this.Mc = !0; + this.sc.value && Mo(this, this.sc.value, !0); + Oo(this, this.$d); +}; +g.mf = function(a) { + a.Gb.persisted && (Oo(this, !1), Oo(this, !0)); +}; +g.lf = function() { + var a = Qo(this.gb); + a != this.cc && Ro(this, a); +}; +function Lo(a) { + return null != a.dc ? a.dc : a.Ob ? Qo(a.gb) : So(a) || ""; +} +function Qo(a) { + a = a.location.href; + var b = a.indexOf("#"); + return 0 > b ? "" : a.substring(b + 1); +} +function Ko(a, b, c) { + a = a.gb.location; + var d = a.href.split("#")[0], e = -1 != a.href.indexOf("#"); + if (Jo || e || b) { + d += "#" + b; + } + d != a.href && (c ? a.replace(d) : a.href = d); +} +function Mo(a, b, c) { + if (a.ae || b != So(a)) { + if (a.ae = !1, b = encodeURIComponent(String(b)), dl) { + var d = Tl(a.tc); + d.open("text/html", c ? "replace" : void 0); + c = Ql(Ol("title", {}, a.gb.document.title), Ol("body", {}, b)); + d.write(Kl(c)); + d.close(); + } else { + if (d = Gl(a.Oc) + "#" + b, a = a.tc.contentWindow) { + c ? a.location.replace(d) : a.location.href = d; + } + } + } +} +function So(a) { + if (dl) { + return a = Tl(a.tc), a.body ? decodeURIComponent(a.body.innerHTML.replace(/\+/g, " ")) : null; + } + var b = a.tc.contentWindow; + if (b) { + var c; + try { + c = decodeURIComponent(Qo(b).replace(/\+/g, " ")); + } catch (d) { + return a.Jb || (1 != a.Jb && a.aa.setInterval(To), a.Jb = !0), null; + } + a.Jb && (0 != a.Jb && a.aa.setInterval(Io), a.Jb = !1); + return c || null; + } + return null; +} +g.ie = function() { + if (this.Ob) { + var a = Qo(this.gb); + a != this.cc && Ro(this, a); + } + if (!this.Ob || Jo) { + if (a = So(this) || "", null == this.dc || a == this.dc) { + this.dc = null, a != this.cc && Ro(this, a); + } + } +}; +function Ro(a, b) { + a.cc = a.sc.value = b; + a.Ob ? (Jo && Mo(a, b), Ko(a, b)) : Mo(a, b); + a.dispatchEvent(new Eo(Lo(a))); +} +g.nf = function() { + this.aa.stop(); + this.aa.start(); +}; +var Po = ["mousedown", "keydown", "mousemove"], Ho = 0, Io = 150, To = 1E4; +var Uo = Ue ? Ue(Ne) : Te.call(null, Ne), Tn = /\//; +function Vo(a, b) { + return q(H.f(D(a), ":")) ? ag([me.c(a.substring(1)), b], !1) : null; +} +function Wo(a, b) { + return H.f(a, b); +} +function Xo(a, b) { + var c = Sn(a), d = Sn(b); + return H.f(K(c), K(d)) ? Oe(Ud, X.h(function() { + return function(a, b) { + var c = H.f(D(a), ":"); + return q(c) ? c : H.f(a, b); + }; + }(c, d), c, d)) : null; +} +function Yo(a, b) { + return q(Xo(a, b)) ? Be(Hg, function() { + return function d(a) { + return new oe(null, function() { + for (var b = a;;) { + if (b = B(b)) { + if (Qd(b)) { + var h = Fc(b), k = K(h), l = new qe(Array(k), 0); + a: { + for (var m = 0;;) { + if (m < k) { + var p = y.f(h, m), p = Be(Vo, p); + null != p && l.add(p); + m += 1; + } else { + h = !0; + break a; + } + } + } + return h ? te(l.ya(), d(Gc(b))) : te(l.ya(), null); + } + l = D(b); + l = Be(Vo, l); + if (null != l) { + return N(l, d($c(b))); + } + b = $c(b); + } else { + return null; + } + } + }, null, null); + }(Mg(Sn(a), Sn(b))); + }()) : null; +} +function Zo(a, b) { + return bf(function(c) { + c = D(c); + return a.f ? a.f(c, b) : a.call(null, c, b); + }, I.c ? I.c(Uo) : I.call(null, Uo)); +} +;var $o, ab = function() { + function a(a) { + var d = null; + if (0 < arguments.length) { + for (var d = 0, e = Array(arguments.length - 0);d < e.length;) { + e[d] = arguments[d + 0], ++d; + } + d = new C(e, 0); + } + return b.call(this, d); + } + function b(a) { + return console.log.apply(console, yb ? xb(a) : wb.call(null, a)); + } + a.F = 0; + a.L = function(a) { + a = B(a); + return b(a); + }; + a.A = b; + return a; +}(), db = function() { + function a(a) { + var d = null; + if (0 < arguments.length) { + for (var d = 0, e = Array(arguments.length - 0);d < e.length;) { + e[d] = arguments[d + 0], ++d; + } + d = new C(e, 0); + } + return b.call(this, d); + } + function b(a) { + return console.error.apply(console, yb ? xb(a) : wb.call(null, a)); + } + a.F = 0; + a.L = function(a) { + a = B(a); + return b(a); + }; + a.A = b; + return a; +}(), ap, bp = new ib(null, 2, [wh, ei, uh, zd], null); +ap = Ue ? Ue(bp) : Te.call(null, bp); +Ye.w(Uo, S, "/", function(a) { + null != a && (a.m & 64 || a.na) && Be(Ve, a); + return Ye.w(ap, S, wh, ei); +}); +Ye.w(Uo, S, "/:filter", function(a) { + a = null != a && (a.m & 64 || a.na) ? Be(Ve, a) : a; + a = z.f(a, mi); + return Ye.w(ap, S, wh, me.c(a)); +}); +var cp = new Go; +oo(cp, "navigate", function(a) { + a = a.vf; + var b = D(Zo(Wo, a)); + if (q(b)) { + var c = P(b, 0, null), b = P(b, 1, null); + a = b.c ? b.c(Ne) : b.call(null, Ne); + } else { + (c = B(Zo(Xo, a))) ? (b = D(c), c = P(b, 0, null), b = P(b, 1, null), a = Yo(c, a), a = b.c ? b.c(a) : b.call(null, a)) : a = null; + } + return a; +}); +Oo(cp, !0); +function dp(a, b) { + var c = null != a && (a.m & 64 || a.na) ? Be(Ve, a) : a, d = z.f(c, uh), e = z.f(c, wh), f = z.f(c, ki); + return ak({className:"main", style:Qj(Ld(d))}, O([function() { + var b = {className:"toggle-all", type:"checkbox", onChange:function(a, b, c) { + return function(a) { + return ep.f ? ep.f(a, c) : ep.call(null, a, c); + }; + }(a, c, c, d, e, f), checked:Oe(Oh, d)}; + return dk.c ? dk.c(b) : dk.call(null, b); + }(), Ee(bk, {className:"todo-list"}, Jn(d, new ib(null, 3, [Xh, new ib(null, 1, [Qh, b], null), Eh, ti, vh, function(a, b, c, d, e, f) { + return function(a) { + var b = H.f(ti.c(a), f) ? S.h(a, ki, !0) : a; + a: { + switch(e instanceof T ? e.Ia : null) { + case "all": + a = !0; + break a; + case "active": + a = qb(Oh.c(a)); + break a; + case "completed": + a = Oh.c(a); + break a; + default: + throw Error([w("No matching clause: "), w(e)].join(""));; + } + } + return qb(a) ? S.h(b, qi, !0) : b; + }; + }(a, c, c, d, e, f)], null)))], 0)); +} +function fp(a, b) { + return 0 < a ? Uj({className:"clear-completed", onClick:function() { + return al(b, new V(null, 2, 5, W, [Ti, new Date], null)); + }}, O([[w("Clear completed ("), w(a), w(")")].join("")], 0)) : null; +} +function gp(a, b, c, d) { + c = fp(c, d); + d = S.h(Mg(new V(null, 3, 5, W, [ei, si, Oh], null), $e("")), wh.c(a), "selected"); + a = {className:"footer", style:Qj(Ld(uh.c(a)))}; + b = O([React.DOM.span.apply(null, xb(N({className:"todo-count"}, X.f(Rj, O([React.DOM.strong.apply(null, xb(N(null, X.f(Rj, O([b], 0))))), [w(" "), w(1 === b ? "item" : [w("item"), w("s")].join("")), w(" left")].join("")], 0))))), bk.A({className:"filters"}, O([Yj(null, O([Sj({href:"#/", className:d.c ? d.c(ei) : d.call(null, ei)}, O(["All"], 0))], 0)), Yj(null, O([Sj({href:"#/active", className:d.c ? d.c(si) : d.call(null, si)}, O(["Active"], 0))], 0)), Yj(null, O([Sj({href:"#/completed", className:d.c ? + d.c(Oh) : d.call(null, Oh)}, O(["Completed"], 0))], 0))], 0)), c], 0); + return React.DOM.footer.apply(null, xb(N(a, X.f(Rj, b)))); +} +function ep(a, b) { + return Nn(b, uh, function(a) { + return function(b) { + return Af(X.f(function(a) { + return function(b) { + return S.h(b, Oh, a); + }; + }(a), b)); + }; + }(a.target.checked)); +} +function hp(a, b, c) { + return 13 === a.which ? (a = Qn(c, "newField"), oa(za(a.value.trim())) || (c = new ib(null, 3, [ti, Wi(), gi, a.value, Oh, !1], null), On(b, uh, function(a) { + return function(b) { + return xd.f(b, a); + }; + }(c, a), new V(null, 2, 5, W, [Lh, c], null)), a.value = ""), !1) : null; +} +function ip(a, b) { + var c = null != b && (b.m & 64 || b.na) ? Be(Ve, b) : b, d = z.f(c, ti); + return On(a, uh, function(a, b, c) { + return function(d) { + return df(zd, cf(function(a, b, c) { + return function(a) { + return H.f(ti.c(a), c); + }; + }(a, b, c), d)); + }; + }(b, c, d), new V(null, 2, 5, W, [Zh, d], null)); +} +function jp(a) { + return Nn(a, uh, function(a) { + return df(zd, cf(Oh, a)); + }); +} +function kp(a, b, c) { + switch(a instanceof T ? a.Ia : null) { + case "destroy": + return ip(b, c); + case "edit": + return a = null != c && (c.m & 64 || c.na) ? Be(Ve, c) : c, a = z.f(a, ti), Pn(b, ki, a); + case "save": + return Pn(b, ki, null); + case "clear": + return jp(b); + case "cancel": + return Pn(b, ki, null); + default: + return null; + } +} +(function(a, b, c) { + var d = null != c && (c.m & 64 || c.na) ? Be(Ve, c) : c, e = z.f(d, Ii), f = z.f(d, Si), h = z.f(d, lh), k = z.f(d, zh), l = z.f(d, oh), m = z.f(d, Mh), p = z.f(d, Di); + if (!Wd(a)) { + throw Error([w("Assert failed: "), w("First argument must be a function"), w("\n"), w("(ifn? f)")].join("")); + } + if (null == e) { + throw Error([w("Assert failed: "), w("No target specified to om.core/root"), w("\n"), w("(not (nil? target))")].join("")); + } + var r = I.c ? I.c(En) : I.call(null, En); + Xd(r, e) && z.f(r, e).call(null); + null == eh && (eh = Ue ? Ue(0) : Te.call(null, 0)); + r = Zc.c([w("G__"), w(Ye.f(eh, jd))].join("")); + b = (null != b ? b.C & 16384 || b.xf || (b.C ? 0 : t(Ic, b)) : t(Ic, b)) ? b : Ue ? Ue(b) : Te.call(null, b); + var u = Ln(b, r, f), x = q(m) ? m : ae, E = Dd.A(d, Ii, O([Si, lh, Mh, Di], 0)), A = Ue ? Ue(null) : Te.call(null, null), F = function(b, c, d, e, f, h, k, l, m, p, r, u, x, E) { + return function cb() { + Ye.h(Cn, Kd, cb); + var c = I.c ? I.c(d) : I.call(null, d), k = function() { + var a = Mn(null == u ? Nm(c, d, zd) : Nm(ef(c, u), d, u), b); + return e.c ? e.c(a) : e.call(null, a); + }(); + if (!q(Zm(d, b, Fh))) { + Xm(d, b, Fh, !0); + var l = ek(function() { + var c = Xl, e = Wl, h = Yl, l = Zl; + Xl = E; + Wl = x; + Yl = d; + Zl = b; + try { + return In(a, k, f); + } finally { + Zl = l, Yl = h, Wl = e, Xl = c; + } + }(), p); + null == (I.c ? I.c(h) : I.call(null, h)) && (Xe.f ? Xe.f(h, l) : Xe.call(null, h, l)); + } + l = Dm(d); + Fm(d); + if (!Ld(l)) { + for (var l = B(l), m = null, r = 0, A = 0;;) { + if (A < r) { + var F = m.K(null, A); + if (q(F.isMounted())) { + var Q = F.state.__om_next_cursor; + q(Q) && (F.props.__om_cursor = Q, F.state.__om_next_cursor = null); + q(function() { + var a = fn(F); + return (a = !(null != a ? a.Re || (a.R ? 0 : t(xm, a)) : t(xm, a))) ? a : F.shouldComponentUpdate(F.props, F.state); + }()) && F.forceUpdate(); + } + A += 1; + } else { + if (l = B(l)) { + m = l; + if (Qd(m)) { + l = Fc(m), A = Gc(m), m = l, r = K(l), l = A; + } else { + var U = D(m); + q(U.isMounted()) && (l = U.state.__om_next_cursor, q(l) && (U.props.__om_cursor = l, U.state.__om_next_cursor = null), q(function() { + var a = fn(U); + return (a = !(null != a ? a.Re || (a.R ? 0 : t(xm, a)) : t(xm, a))) ? a : U.shouldComponentUpdate(U.props, U.state); + }()) && U.forceUpdate()); + l = G(m); + m = null; + r = 0; + } + A = 0; + } else { + break; + } + } + } + } + l = I.c ? I.c(An) : I.call(null, An); + if (!Ld(l)) { + for (l = B(l), m = null, A = r = 0;;) { + if (A < r) { + Q = m.K(null, A); + P(Q, 0, null); + for (var Q = P(Q, 1, null), Q = I.c ? I.c(Q) : I.call(null, Q), Q = B(Q), Y = null, pa = 0, Ce = 0;;) { + if (Ce < pa) { + var yd = Y.K(null, Ce); + P(yd, 0, null); + yd = P(yd, 1, null); + q(yd.shouldComponentUpdate(yd.props, yd.state)) && yd.forceUpdate(); + Ce += 1; + } else { + if (Q = B(Q)) { + Qd(Q) ? (pa = Fc(Q), Q = Gc(Q), Y = pa, pa = K(pa)) : (Y = D(Q), P(Y, 0, null), Y = P(Y, 1, null), q(Y.shouldComponentUpdate(Y.props, Y.state)) && Y.forceUpdate(), Q = G(Q), Y = null, pa = 0), Ce = 0; + } else { + break; + } + } + } + A += 1; + } else { + if (l = B(l)) { + if (Qd(l)) { + r = Fc(l), l = Gc(l), m = r, r = K(r); + } else { + m = D(l); + P(m, 0, null); + m = P(m, 1, null); + m = I.c ? I.c(m) : I.call(null, m); + m = B(m); + r = null; + for (Q = A = 0;;) { + if (Q < A) { + Y = r.K(null, Q), P(Y, 0, null), Y = P(Y, 1, null), q(Y.shouldComponentUpdate(Y.props, Y.state)) && Y.forceUpdate(), Q += 1; + } else { + if (m = B(m)) { + Qd(m) ? (A = Fc(m), m = Gc(m), r = A, A = K(A)) : (r = D(m), P(r, 0, null), r = P(r, 1, null), q(r.shouldComponentUpdate(r.props, r.state)) && r.forceUpdate(), m = G(m), r = null, A = 0), Q = 0; + } else { + break; + } + } + } + l = G(l); + m = null; + r = 0; + } + A = 0; + } else { + break; + } + } + } + } + return I.c ? I.c(h) : I.call(null, h); + }; + }(r, b, u, x, E, A, c, d, d, e, f, h, k, l, m, p); + dh(u, r, function(a, b, c, d, e, f, h, k, l, m, p, r, u, x, A, E, F) { + return function(sb, Jb, Kb, $b) { + qb(Zm(c, a, fi)) && Kb !== $b && Xm(c, a, Fh, !1); + Xm(c, a, fi, !1); + Xd(I.c ? I.c(Cn) : I.call(null, Cn), h) || Ye.h(Cn, xd, h); + if (q(Bn)) { + return null; + } + Bn = !0; + return Ed(F) ? F.D ? F.D() : F.call(null) : !1 === F || "undefined" === typeof requestAnimationFrame ? setTimeout(function(a, b, c) { + return function() { + return Dn(c); + }; + }(a, b, c, d, e, f, h, k, l, m, p, r, u, x, A, E, F), 16) : requestAnimationFrame(function(a, b, c) { + return function() { + return Dn(c); + }; + }(a, b, c, d, e, f, h, k, l, m, p, r, u, x, A, E, F)); + }; + }(r, b, u, x, E, A, F, c, d, d, e, f, h, k, l, m, p)); + Ye.w(En, S, e, function(a, b, c, d, e, f, h, k, l, m, p) { + return function() { + Ym(c, a); + yc(c, a); + Um(c, a); + Ye.h(Cn, Kd, h); + Ye.h(En, Dd, p); + return ReactDOM.unmountComponentAtNode(p); + }; + }(r, b, u, x, E, A, F, c, d, d, e, f, h, k, l, m, p)); + return F(); +})(function lp(b, c) { + var d = null != b && (b.m & 64 || b.na) ? Be(Ve, b) : b, e = z.f(d, uh); + "undefined" === typeof $o && ($o = function(b, c, d, e, m, p, r) { + this.tf = b; + this.pf = c; + this.ua = d; + this.He = e; + this.app = m; + this.Bc = p; + this.Je = r; + this.m = 393216; + this.C = 0; + }, $o.prototype.P = function() { + return function(b, c) { + return new $o(this.tf, this.pf, this.ua, this.He, this.app, this.Bc, c); + }; + }(b, d, d, e), $o.prototype.M = function() { + return function() { + return this.Je; + }; + }(b, d, d, e), $o.prototype.Ud = !0, $o.prototype.Vd = function(b, c, d, e) { + return function() { + var m = this, p = Zk(null); + Rn(m.ua, Qh, p); + var r = Zk(1); + Gk(function(b, c, d, e, f, h, k) { + return function() { + var l = function() { + return function(b) { + return function() { + function c(d) { + for (;;) { + var e; + a: { + try { + for (;;) { + var f = b(d); + if (!le(f, Wh)) { + e = f; + break a; + } + } + } catch (h) { + if (h instanceof Object) { + d[5] = h, Wk(d), e = Wh; + } else { + throw h; + } + } + } + if (!le(e, Wh)) { + return e; + } + } + } + function d() { + var b = [null, null, null, null, null, null, null, null]; + b[0] = e; + b[1] = 1; + return b; + } + var e = null, e = function(b) { + switch(arguments.length) { + case 0: + return d.call(this); + case 1: + return c.call(this, b); + } + throw Error("Invalid arity: " + arguments.length); + }; + e.D = d; + e.c = c; + return e; + }(); + }(function(b, c) { + return function(b) { + var d = b[1]; + if (1 === d) { + return b[2] = null, b[1] = 2, Wh; + } + if (2 === d) { + return b[1] = 4, Wh; + } + if (3 === d) { + return Vk(b, b[2]); + } + if (4 === d) { + return Uk(b, c); + } + if (5 === d) { + return b[2] = null, b[1] = 6, Wh; + } + if (6 === d) { + return b[2] = b[2], b[1] = 3, Wh; + } + if (7 === d) { + var e = b[2], d = P(e, 0, null), e = P(e, 1, null), d = kp(d, m.app, e); + b[7] = d; + b[2] = null; + b[1] = 2; + return Wh; + } + return null; + }; + }(b, c, d, e, f, h, k), b, c, d, e, f, h, k); + }(), p = function() { + var c = l.D ? l.D() : l.call(null); + c[6] = b; + return c; + }(); + return Tk(p); + }; + }(r, p, this, b, c, d, e)); + return r; + }; + }(b, d, d, e), $o.prototype.Wd = !0, $o.prototype.Xd = function() { + return function() { + return new Date; + }; + }(b, d, d, e), $o.prototype.Tc = !0, $o.prototype.Uc = function() { + return function() { + var b; + b = this.Bc; + if (null != b) { + b = localStorage.setItem("todos", "" + w(b)); + } else { + if (b = localStorage.getItem("todos"), null != b) { + if ("string" !== typeof b) { + throw Error("Cannot read from non-string object."); + } + b = oj(new Zi(b, [], -1), !1, null); + } else { + b = zd; + } + } + return b; + }; + }(b, d, d, e), $o.prototype.Vc = !0, $o.prototype.Wc = function(b, c, d, e) { + return function(m, p) { + var r = this, u = null != p && (p.m & 64 || p.na) ? Be(Ve, p) : p, x = z.f(u, Qh), E = this, A = K(cf(Oh, r.Bc)), F = K(r.Bc) - A; + return Vj(null, O([React.DOM.header.apply(null, xb(N({className:"header"}, X.f(Rj, O([Wj(), function() { + var m = {ref:"newField", className:"new-todo", placeholder:"What needs to be done?", onKeyDown:function() { + return function(b) { + return hp(b, r.app, r.ua); + }; + }(A, F, E, p, u, x, b, c, d, e)}; + return dk.c ? dk.c(m) : dk.call(null, m); + }(), dp(r.app, x), gp(r.app, A, F, x)], 0)))))], 0)); + }; + }(b, d, d, e), $o.Wb = function() { + return function() { + return new V(null, 7, 5, W, [Id(Ni, new ib(null, 1, [Le, je(Me, je(new V(null, 2, 5, W, [new ib(null, 2, [ni, new V(null, 1, 5, W, [Rh], null), Nh, Li], null), yh], null)))], null)), rh, yh, Bh, Li, Rh, sh], null); + }; + }(b, d, d, e), $o.qb = !0, $o.Za = "todomvc.app/t_todomvc$app14481", $o.Eb = function() { + return function(b, c) { + return tc(c, "todomvc.app/t_todomvc$app14481"); + }; + }(b, d, d, e)); + return new $o(lp, b, c, d, d, e, Ne); +}, ap, new ib(null, 1, [Ii, document.querySelector(".todoapp")], null)); +ek(Vj(null, O([Zj(O(["Double-click to edit a todo"], 0)), Zj(O([function(a) { + for (var b = [], c = arguments.length, d = 0;;) { + if (d < c) { + b.push(arguments[d]), d += 1; + } else { + break; + } + } + return Sj(arguments[0], 1 < b.length ? new C(b.slice(1), 0, null) : null); +}({href:"http://github.com/swannodette"})], 0)), Zj(O([["Part of", Sj({href:"http://todomvc.com"}, O(["TodoMVC"], 0))]], 0))], 0)), document.querySelector(".info")); diff --git a/implementations/om-1.0.0-alpha/bower.json b/implementations/om-1.0.0-alpha/bower.json new file mode 100644 index 000000000..8b90de55a --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower.json @@ -0,0 +1,9 @@ +{ + "name": "todomvc-om", + "version": "0.0.0", + "dependencies": { + "todomvc-app-css": "~2.0.6", + "todomvc-common": "~1.0.2", + "director": "~1.2.0" + } +} diff --git a/implementations/om-1.0.0-alpha/bower_components/director/.bower.json b/implementations/om-1.0.0-alpha/bower_components/director/.bower.json new file mode 100644 index 000000000..69d580994 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/.bower.json @@ -0,0 +1,19 @@ +{ + "name": "director", + "version": "1.2.8", + "dependencies": {}, + "main": "build/director.js", + "scripts": [ + "build/director.js" + ], + "homepage": "https://github.com/flatiron/director", + "_release": "1.2.8", + "_resolution": { + "type": "version", + "tag": "v1.2.8", + "commit": "758cfc4886c9bf651f75f0b73f649d1b2fe7dcf3" + }, + "_source": "https://github.com/flatiron/director.git", + "_target": "~1.2.0", + "_originalSource": "director" +} \ No newline at end of file diff --git a/implementations/om-1.0.0-alpha/bower_components/director/.gitignore b/implementations/om-1.0.0-alpha/bower_components/director/.gitignore new file mode 100644 index 000000000..ff1a80c4e --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/.gitignore @@ -0,0 +1,6 @@ +/.idea/ +node_modules +npm-debug.log +.DS_Store + +/test/browser/browserified-bundle.js diff --git a/implementations/om-1.0.0-alpha/bower_components/director/.travis.yml b/implementations/om-1.0.0-alpha/bower_components/director/.travis.yml new file mode 100644 index 000000000..b895b7f0b --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/.travis.yml @@ -0,0 +1,14 @@ +language: node_js + +before_install: + - curl --location http://git.io/1OcIZA | bash -s + +node_js: + - "0.8" + - "0.10" + - "0.11" + +notifications: + email: + - travis@nodejitsu.com + irc: "irc.freenode.org#nodejitsu" diff --git a/implementations/om-1.0.0-alpha/bower_components/director/LICENSE b/implementations/om-1.0.0-alpha/bower_components/director/LICENSE new file mode 100644 index 000000000..8a4981085 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2011 Charlie Robbins, Paolo Fragomeni, & the Contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/implementations/om-1.0.0-alpha/bower_components/director/README.md b/implementations/om-1.0.0-alpha/bower_components/director/README.md new file mode 100644 index 000000000..a2f64f636 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/README.md @@ -0,0 +1,962 @@ +![Logo](https://github.com/flatiron/director/raw/master/img/director.png) + +# Synopsis + +Director is a router. Routing is the process of determining what code to run +when a URL is requested. + +# Motivation + +A routing library that works in both the browser and node.js environments with +as few differences as possible. Simplifies the development of Single Page Apps +and Node.js applications. Dependency free (doesn't require jQuery or Express, +etc). + +# Status +[![Build Status](https://secure.travis-ci.org/flatiron/director.png?branch=master)](http://travis-ci.org/flatiron/director) + +# Features + +* [Client-Side Routing](#client-side-routing) +* [Server-Side HTTP Routing](#server-side-http-routing) +* [Server-Side CLI Routing](#server-side-cli-routing) + +# Usage + +* [API Documentation](#api-documentation) +* [Frequently Asked Questions](#faq) + +## Building client-side script + +Run the provided CLI script. + +```bash +./bin/build +``` + +## Client-side Routing + +It simply watches the hash of the URL to determine what to do, for example: + +``` +http://foo.com/#/bar +``` + +Client-side routing (aka hash-routing) allows you to specify some information +about the state of the application using the URL. So that when the user visits +a specific URL, the application can be transformed accordingly. + +![Hash route](https://github.com/flatiron/director/raw/master/img/hashRoute.png) + +Here is a simple example: + +```html + + + + + A Gentle Introduction + + + + + + + + + + +``` + +Director works great with your favorite DOM library, such as jQuery. + +```html + + + + + A Gentle Introduction 2 + + + + + + + + + +
Author Name
+
Book1, Book2, Book3
+ + + +``` + +You can find a browser-specific build of `director` [here][1] which has all of +the server code stripped away. + +## Server-Side HTTP Routing + +Director handles routing for HTTP requests similar to `journey` or `express`: + +```js + // + // require the native http module, as well as director. + // + var http = require('http'), + director = require('director'); + + // + // create some logic to be routed to. + // + function helloWorld() { + this.res.writeHead(200, { 'Content-Type': 'text/plain' }) + this.res.end('hello world'); + } + + // + // define a routing table. + // + var router = new director.http.Router({ + '/hello': { + get: helloWorld + } + }); + + // + // setup a server and when there is a request, dispatch the + // route that was requested in the request object. + // + var server = http.createServer(function (req, res) { + router.dispatch(req, res, function (err) { + if (err) { + res.writeHead(404); + res.end(); + } + }); + }); + + // + // You can also do ad-hoc routing, similar to `journey` or `express`. + // This can be done with a string or a regexp. + // + router.get('/bonjour', helloWorld); + router.get(/hola/, helloWorld); + + // + // set the server to listen on port `8080`. + // + server.listen(8080); +``` + +### See Also: + + - Auto-generated Node.js API Clients for routers using + [Director-Reflector](http://github.com/flatiron/director-reflector) + - RESTful Resource routing using [restful](http://github.com/flatiron/restful) + - HTML / Plain Text views of routers using + [Director-Explorer](http://github.com/flatiron/director-explorer) + +## Server-Side CLI Routing + +Director supports Command Line Interface routing. Routes for cli options are +based on command line input (i.e. `process.argv`) instead of a URL. + +``` js + var director = require('director'); + + var router = new director.cli.Router(); + + router.on('create', function () { + console.log('create something'); + }); + + router.on(/destroy/, function () { + console.log('destroy something'); + }); + + // You will need to dispatch the cli arguments yourself + router.dispatch('on', process.argv.slice(2).join(' ')); +``` + +Using the cli router, you can dispatch commands by passing them as a string. +For example, if this example is in a file called `foo.js`: + +```bash +$ node foo.js create +create something +$ node foo.js destroy +destroy something +``` + +# API Documentation + +* [Constructor](#constructor) +* [Routing Table](#routing-table) +* [Adhoc Routing](#adhoc-routing) +* [Scoped Routing](#scoped-routing) +* [Routing Events](#routing-events) +* [Configuration](#configuration) +* [URL Matching](#url-matching) +* [URL Parameters](#url-parameters) +* [Wildcard routes](#wildcard-routes) +* [Route Recursion](#route-recursion) +* [Async Routing](#async-routing) +* [Resources](#resources) +* [History API](#history-api) +* [Instance Methods](#instance-methods) +* [Attach Properties to `this`](#attach-properties-to-this) +* [HTTP Streaming and Body Parsing](#http-streaming-and-body-parsing) + +## Constructor + +``` js + var router = Router(routes); +``` + +## Routing Table + +An object literal that contains nested route definitions. A potentially nested +set of key/value pairs. The keys in the object literal represent each potential +part of the URL. The values in the object literal contain references to the +functions that should be associated with them. *bark* and *meow* are two +functions that you have defined in your code. + +``` js + // + // Assign routes to an object literal. + // + var routes = { + // + // a route which assigns the function `bark`. + // + '/dog': bark, + // + // a route which assigns the functions `meow` and `scratch`. + // + '/cat': [meow, scratch] + }; + + // + // Instantiate the router. + // + var router = Router(routes); +``` + +## Adhoc Routing + +When developing large client-side or server-side applications it is not always +possible to define routes in one location. Usually individual decoupled +components register their own routes with the application router. We refer to +this as _Adhoc Routing._ Lets take a look at the API `director` exposes for +adhoc routing: + +**Client-side Routing** + +``` js + var router = new Router().init(); + + router.on('/some/resource', function () { + // + // Do something on `/#/some/resource` + // + }); +``` + +**HTTP Routing** + +``` js + var router = new director.http.Router(); + + router.get(/\/some\/resource/, function () { + // + // Do something on an GET to `/some/resource` + // + }); +``` + +## Scoped Routing + +In large web appliations, both [Client-side](#client-side) and +[Server-side](#http-routing), routes are often scoped within a few individual +resources. Director exposes a simple way to do this for [Adhoc +Routing](#adhoc-routing) scenarios: + +``` js + var router = new director.http.Router(); + + // + // Create routes inside the `/users` scope. + // + router.path(/\/users\/(\w+)/, function () { + // + // The `this` context of the function passed to `.path()` + // is the Router itself. + // + + this.post(function (id) { + // + // Create the user with the specified `id`. + // + }); + + this.get(function (id) { + // + // Retreive the user with the specified `id`. + // + }); + + this.get(/\/friends/, function (id) { + // + // Get the friends for the user with the specified `id`. + // + }); + }); +``` + +## Routing Events + +In `director`, a "routing event" is a named property in the +[Routing Table](#routing-table) which can be assigned to a function or an Array +of functions to be called when a route is matched in a call to +`router.dispatch()`. + +* **on:** A function or Array of functions to execute when the route is matched. +* **before:** A function or Array of functions to execute before calling the + `on` method(s). + +**Client-side only** + +* **after:** A function or Array of functions to execute when leaving a + particular route. +* **once:** A function or Array of functions to execute only once for a + particular route. + +## Configuration + +Given the flexible nature of `director` there are several options available for +both the [Client-side](#client-side) and [Server-side](#http-routing). These +options can be set using the `.configure()` method: + +``` js + var router = new director.Router(routes).configure(options); +``` + +The `options` are: + +* **recurse:** Controls [route recursion](#route-recursion). Use `forward`, + `backward`, or `false`. Default is `false` Client-side, and `backward` + Server-side. +* **strict:** If set to `false`, then trailing slashes (or other delimiters) + are allowed in routes. Default is `true`. +* **async:** Controls [async routing](#async-routing). Use `true` or `false`. + Default is `false`. +* **delimiter:** Character separator between route fragments. Default is `/`. +* **notfound:** A function to call if no route is found on a call to + `router.dispatch()`. +* **on:** A function (or list of functions) to call on every call to + `router.dispatch()` when a route is found. +* **before:** A function (or list of functions) to call before every call to + `router.dispatch()` when a route is found. + +**Client-side only** + +* **resource:** An object to which string-based routes will be bound. This can + be especially useful for late-binding to route functions (such as async + client-side requires). +* **after:** A function (or list of functions) to call when a given route is no + longer the active route. +* **html5history:** If set to `true` and client supports `pushState()`, then + uses HTML5 History API instead of hash fragments. See + [History API](#history-api) for more information. +* **run_handler_in_init:** If `html5history` is enabled, the route handler by + default is executed upon `Router.init()` since with real URIs the router can + not know if it should call a route handler or not. Setting this to `false` + disables the route handler initial execution. +* **convert_hash_in_init:** If `html5history` is enabled, the window.location hash by default is converted to a route upon `Router.init()` since with canonical URIs the router can not know if it should convert the hash to a route or not. Setting this to `false` disables the hash conversion on router initialisation. + +## URL Matching + +``` js + var router = Router({ + // + // given the route '/dog/yella'. + // + '/dog': { + '/:color': { + // + // this function will return the value 'yella'. + // + on: function (color) { console.log(color) } + } + } + }); +``` + +Routes can sometimes become very complex, `simple/:tokens` don't always +suffice. Director supports regular expressions inside the route names. The +values captured from the regular expressions are passed to your listener +function. + +``` js + var router = Router({ + // + // given the route '/hello/world'. + // + '/hello': { + '/(\\w+)': { + // + // this function will return the value 'world'. + // + on: function (who) { console.log(who) } + } + } + }); +``` + +``` js + var router = Router({ + // + // given the route '/hello/world/johny/appleseed'. + // + '/hello': { + '/world/?([^\/]*)\/([^\/]*)/?': function (a, b) { + console.log(a, b); + } + } + }); +``` + +## URL Parameters + +When you are using the same route fragments it is more descriptive to define +these fragments by name and then use them in your +[Routing Table](#routing-table) or [Adhoc Routes](#adhoc-routing). Consider a +simple example where a `userId` is used repeatedly. + +``` js + // + // Create a router. This could also be director.cli.Router() or + // director.http.Router(). + // + var router = new director.Router(); + + // + // A route could be defined using the `userId` explicitly. + // + router.on(/([\w-_]+)/, function (userId) { }); + + // + // Define a shorthand for this fragment called `userId`. + // + router.param('userId', /([\\w\\-]+)/); + + // + // Now multiple routes can be defined with the same + // regular expression. + // + router.on('/anything/:userId', function (userId) { }); + router.on('/something-else/:userId', function (userId) { }); +``` + +## Wildcard routes + +It is possible to define wildcard routes, so that /foo and /foo/a/b/c routes to +the same handler, and gets passed `""` and `"a/b/c"` respectively. + +``` js + router.on("/foo/?((\w|.)*)"), function (path) { }); +``` + +## Route Recursion + +Can be assigned the value of `forward` or `backward`. The recurse option will +determine the order in which to fire the listeners that are associated with +your routes. If this option is NOT specified or set to null, then only the +listeners associated with an exact match will be fired. + +### No recursion, with the URL /dog/angry + +``` js + var routes = { + '/dog': { + '/angry': { + // + // Only this method will be fired. + // + on: growl + }, + on: bark + } + }; + + var router = Router(routes); +``` + +### Recursion set to `backward`, with the URL /dog/angry + +``` js + var routes = { + '/dog': { + '/angry': { + // + // This method will be fired first. + // + on: growl + }, + // + // This method will be fired second. + // + on: bark + } + }; + + var router = Router(routes).configure({ recurse: 'backward' }); +``` + +### Recursion set to `forward`, with the URL /dog/angry + +``` js + var routes = { + '/dog': { + '/angry': { + // + // This method will be fired second. + // + on: growl + }, + // + // This method will be fired first. + // + on: bark + } + }; + + var router = Router(routes).configure({ recurse: 'forward' }); +``` + +### Breaking out of recursion, with the URL /dog/angry + +``` js + var routes = { + '/dog': { + '/angry': { + // + // This method will be fired first. + // + on: function() { return false; } + }, + // + // This method will not be fired. + // + on: bark + } + }; + + // + // This feature works in reverse with recursion set to true. + // + var router = Router(routes).configure({ recurse: 'backward' }); +``` + +## Async Routing + +Before diving into how Director exposes async routing, you should understand +[Route Recursion](#route-recursion). At it's core route recursion is about +evaluating a series of functions gathered when traversing the [Routing +Table](#routing-table). + +Normally this series of functions is evaluated synchronously. In async routing, +these functions are evaluated asynchronously. Async routing can be extremely +useful both on the client-side and the server-side: + +* **Client-side:** To ensure an animation or other async operations (such as + HTTP requests for authentication) have completed before continuing evaluation + of a route. +* **Server-side:** To ensure arbitrary async operations (such as performing + authentication) have completed before continuing the evaluation of a route. + +The method signatures for route functions in synchronous and asynchronous +evaluation are different: async route functions take an additional `next()` +callback. + +### Synchronous route functions + +``` js + var router = new director.Router(); + + router.on('/:foo/:bar/:bazz', function (foo, bar, bazz) { + // + // Do something asynchronous with `foo`, `bar`, and `bazz`. + // + }); +``` + +### Asynchronous route functions + +``` js + var router = new director.http.Router().configure({ async: true }); + + router.on('/:foo/:bar/:bazz', function (foo, bar, bazz, next) { + // + // Go do something async, and determine that routing should stop + // + next(false); + }); +``` + +## Resources + +**Available on the Client-side only.** An object literal containing functions. +If a host object is specified, your route definitions can provide string +literals that represent the function names inside the host object. A host +object can provide the means for better encapsulation and design. + +``` js + + var router = Router({ + + '/hello': { + '/usa': 'americas', + '/china': 'asia' + } + + }).configure({ resource: container }).init(); + + var container = { + americas: function() { return true; }, + china: function() { return true; } + }; + +``` + +## History API + +**Available on the Client-side only.** Director supports using HTML5 History +API instead of hash fragments for navigation. To use the API, pass +`{html5history: true}` to `configure()`. Use of the API is enabled only if the +client supports `pushState()`. + +Using the API gives you cleaner URIs but they come with a cost. Unlike with +hash fragments your route URIs must exist. When the client enters a page, say +http://foo.com/bar/baz, the web server must respond with something meaningful. +Usually this means that your web server checks the URI points to something +that, in a sense, exists, and then serves the client the JavaScript +application. + +If you're after a single-page application you can not use plain old `` tags for navigation anymore. When such link is clicked, web +browsers try to ask for the resource from server which is not of course desired +for a single-page application. Instead you need to use e.g. click handlers and +call the `setRoute()` method yourself. + +## Attach Properties To `this` + +**Available in the http router only.** Generally, the `this` object bound to +route handlers, will contain the request in `this.req` and the response in +`this.res`. One may attach additional properties to `this` with the +`router.attach` method: + +```js + var director = require('director'); + + var router = new director.http.Router().configure(options); + + // + // Attach properties to `this` + // + router.attach(function () { + this.data = [1,2,3]; + }); + + // + // Access properties attached to `this` in your routes! + // + router.get('/hello', function () { + this.res.writeHead(200, { 'content-type': 'text/plain' }); + + // + // Response will be `[1,2,3]`! + // + this.res.end(this.data); + }); +``` + +This API may be used to attach convenience methods to the `this` context of +route handlers. + +## HTTP Streaming and Body Parsing + +When you are performing HTTP routing there are two common scenarios: + +* Buffer the request body and parse it according to the `Content-Type` header + (usually `application/json` or `application/x-www-form-urlencoded`). +* Stream the request body by manually calling `.pipe` or listening to the + `data` and `end` events. + +By default `director.http.Router()` will attempt to parse either the `.chunks` +or `.body` properties set on the request parameter passed to +`router.dispatch(request, response, callback)`. The router instance will also +wait for the `end` event before firing any routes. + +**Default Behavior** + +``` js + var director = require('director'); + + var router = new director.http.Router(); + + router.get('/', function () { + // + // This will not work, because all of the data + // events and the end event have already fired. + // + this.req.on('data', function (chunk) { + console.log(chunk) + }); + }); +``` + +In [flatiron][2], `director` is used in conjunction with [union][3] which uses +a `BufferedStream` proxy to the raw `http.Request` instance. [union][3] will +set the `req.chunks` property for you and director will automatically parse the +body. If you wish to perform this buffering yourself directly with `director` +you can use a simple request handler in your http server: + +``` js + var http = require('http'), + director = require('director'); + + var router = new director.http.Router(); + + var server = http.createServer(function (req, res) { + req.chunks = []; + req.on('data', function (chunk) { + req.chunks.push(chunk.toString()); + }); + + router.dispatch(req, res, function (err) { + if (err) { + res.writeHead(404); + res.end(); + } + + console.log('Served ' + req.url); + }); + }); + + router.post('/', function () { + this.res.writeHead(200, { 'Content-Type': 'application/json' }) + this.res.end(JSON.stringify(this.req.body)); + }); +``` + +**Streaming Support** + +If you wish to get access to the request stream before the `end` event is +fired, you can pass the `{ stream: true }` options to the route. + +``` js + var director = require('director'); + + var router = new director.http.Router(); + + router.get('/', { stream: true }, function () { + // + // This will work because the route handler is invoked + // immediately without waiting for the `end` event. + // + this.req.on('data', function (chunk) { + console.log(chunk); + }); + }); +``` + +## Instance methods + +### configure(options) + +* `options` {Object}: Options to configure this instance with. + +Configures the Router instance with the specified `options`. See +[Configuration](#configuration) for more documentation. + +### param(token, matcher) + +* token {string}: Named parameter token to set to the specified `matcher` +* matcher {string|Regexp}: Matcher for the specified `token`. + +Adds a route fragment for the given string `token` to the specified regex +`matcher` to this Router instance. See [URL Parameters](#url-parameters) for more +documentation. + +### on(method, path, route) + +* `method` {string}: Method to insert within the Routing Table (e.g. `on`, + `get`, etc.). +* `path` {string}: Path within the Routing Table to set the `route` to. +* `route` {function|Array}: Route handler to invoke for the `method` and `path`. + +Adds the `route` handler for the specified `method` and `path` within the +[Routing Table](#routing-table). + +### path(path, routesFn) + +* `path` {string|Regexp}: Scope within the Routing Table to invoke the + `routesFn` within. +* `routesFn` {function}: Adhoc Routing function with calls to `this.on()`, + `this.get()` etc. + +Invokes the `routesFn` within the scope of the specified `path` for this Router +instance. + +### dispatch(method, path[, callback]) + +* method {string}: Method to invoke handlers for within the Routing Table +* path {string}: Path within the Routing Table to match +* callback {function}: Invoked once all route handlers have been called. + +Dispatches the route handlers matched within the [Routing Table](#routing-table) +for this instance for the specified `method` and `path`. + +### mount(routes, path) + +* routes {object}: Partial routing table to insert into this instance. +* path {string|Regexp}: Path within the Routing Table to insert the `routes` + into. + +Inserts the partial [Routing Table](#routing-table), `routes`, into the Routing +Table for this Router instance at the specified `path`. + +## Instance methods (Client-side only) + +### init([redirect]) + +* `redirect` {String}: This value will be used if '/#/' is not found in the + URL. (e.g., init('/') will resolve to '/#/', init('foo') will resolve to + '/#foo'). + +Initialize the router, start listening for changes to the URL. + +### getRoute([index]) + +* `index` {Number}: The hash value is divided by forward slashes, each section + then has an index, if this is provided, only that section of the route will + be returned. + +Returns the entire route or just a section of it. + +### setRoute(route) + +* `route` {String}: Supply a route value, such as `home/stats`. + +Set the current route. + +### setRoute(start, length) + +* `start` {Number} - The position at which to start removing items. +* `length` {Number} - The number of items to remove from the route. + +Remove a segment from the current route. + +### setRoute(index, value) + +* `index` {Number} - The hash value is divided by forward slashes, each section + then has an index. +* `value` {String} - The new value to assign the the position indicated by the + first parameter. + +Set a segment of the current route. + +# Frequently Asked Questions + +## What About SEO? + +Is using a Client-side router a problem for SEO? Yes. If advertising is a +requirement, you are probably building a "Web Page" and not a "Web +Application". Director on the client is meant for script-heavy Web +Applications. + +##### LICENSE: MIT +##### Author: [Charlie Robbins](https://github.com/indexzero) +##### Contributors: [Paolo Fragomeni](https://github.com/hij1nx) + +[0]: http://github.com/flatiron/director +[1]: https://github.com/flatiron/director/blob/master/build/director.min.js +[2]: http://github.com/flatiron/flatiron +[3]: http://github.com/flatiron/union diff --git a/implementations/om-1.0.0-alpha/bower_components/director/bin/build b/implementations/om-1.0.0-alpha/bower_components/director/bin/build new file mode 100755 index 000000000..e054226fa --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/bin/build @@ -0,0 +1,81 @@ +#!/usr/bin/env node + +var Codesurgeon = require('codesurgeon').Codesurgeon; +var surgeon = new Codesurgeon(); + +var path = require('path'); + +var root = path.join(__dirname, '..'); +var lib = path.join(root, 'lib', 'director'); + +// +// Distill and package the browser version. +// +surgeon + // + .configure({ + package: root + '/package.json', + owner: 'Charlie Robbins, Paolo Fragomeni & the Contributors (Using Codesurgeon).', + noVersion: true + }) + .read( + path.join(lib, 'browser.js') + ) + // + // We want everything so far. specify extract with no + // parameters to get everything into the output buffer. + // + .extract() + // + // Clear the input so far, but don't clear the output. + // + .clear('inputs') + // + // Read the `router.js` file + // + .read( + path.join(lib, 'router.js') + ) + // + // The current input buffer contains stuff that we dont + // want in the browser build, so let's cherry pick from + // the buffer. + // + .extract( + '_every', + '_flatten', + '_asyncEverySeries', + 'paramifyString', + 'regifyString', + 'terminator', + 'QUERY_SEPARATOR', + 'Router.prototype.configure', + 'Router.prototype.param', + 'Router.prototype.on', + 'Router.prototype.path', + 'Router.prototype.dispatch', + 'Router.prototype.invoke', + 'Router.prototype.traverse', + 'Router.prototype.insert', + 'Router.prototype.insertEx', + 'Router.prototype.extend', + 'Router.prototype.runlist', + 'Router.prototype.mount' + ) + // + // Wrap everything that is in the current buffer with a + // closure so that we don't get any collisions with other + // libraries. + // + .wrap() + // + // Write the debuggable version of the file. This file will + // get renamed to include the version from the package.json. + // + .write(root + '/build/director.js') + // + // Make a minified version for production use. + // + .uglify() + .write(root + '/build/director.min.js') +; diff --git a/implementations/om-1.0.0-alpha/bower_components/director/bower.json b/implementations/om-1.0.0-alpha/bower_components/director/bower.json new file mode 100644 index 000000000..f939bb470 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/bower.json @@ -0,0 +1,9 @@ +{ + "name": "director", + "version": "1.2.7", + "dependencies": {}, + "main": "build/director.js", + "scripts": [ + "build/director.js" + ] +} diff --git a/implementations/om-1.0.0-alpha/bower_components/director/build/director.js b/implementations/om-1.0.0-alpha/bower_components/director/build/director.js new file mode 100644 index 000000000..103887872 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/build/director.js @@ -0,0 +1,725 @@ + + +// +// Generated on Tue Dec 16 2014 12:13:47 GMT+0100 (CET) by Charlie Robbins, Paolo Fragomeni & the Contributors (Using Codesurgeon). +// Version 1.2.6 +// + +(function (exports) { + +/* + * browser.js: Browser specific functionality for director. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var dloc = document.location; + +function dlocHashEmpty() { + // Non-IE browsers return '' when the address bar shows '#'; Director's logic + // assumes both mean empty. + return dloc.hash === '' || dloc.hash === '#'; +} + +var listener = { + mode: 'modern', + hash: dloc.hash, + history: false, + + check: function () { + var h = dloc.hash; + if (h != this.hash) { + this.hash = h; + this.onHashChanged(); + } + }, + + fire: function () { + if (this.mode === 'modern') { + this.history === true ? window.onpopstate() : window.onhashchange(); + } + else { + this.onHashChanged(); + } + }, + + init: function (fn, history) { + var self = this; + this.history = history; + + if (!Router.listeners) { + Router.listeners = []; + } + + function onchange(onChangeEvent) { + for (var i = 0, l = Router.listeners.length; i < l; i++) { + Router.listeners[i](onChangeEvent); + } + } + + //note IE8 is being counted as 'modern' because it has the hashchange event + if ('onhashchange' in window && (document.documentMode === undefined + || document.documentMode > 7)) { + // At least for now HTML5 history is available for 'modern' browsers only + if (this.history === true) { + // There is an old bug in Chrome that causes onpopstate to fire even + // upon initial page load. Since the handler is run manually in init(), + // this would cause Chrome to run it twise. Currently the only + // workaround seems to be to set the handler after the initial page load + // http://code.google.com/p/chromium/issues/detail?id=63040 + setTimeout(function() { + window.onpopstate = onchange; + }, 500); + } + else { + window.onhashchange = onchange; + } + this.mode = 'modern'; + } + else { + // + // IE support, based on a concept by Erik Arvidson ... + // + var frame = document.createElement('iframe'); + frame.id = 'state-frame'; + frame.style.display = 'none'; + document.body.appendChild(frame); + this.writeFrame(''); + + if ('onpropertychange' in document && 'attachEvent' in document) { + document.attachEvent('onpropertychange', function () { + if (event.propertyName === 'location') { + self.check(); + } + }); + } + + window.setInterval(function () { self.check(); }, 50); + + this.onHashChanged = onchange; + this.mode = 'legacy'; + } + + Router.listeners.push(fn); + + return this.mode; + }, + + destroy: function (fn) { + if (!Router || !Router.listeners) { + return; + } + + var listeners = Router.listeners; + + for (var i = listeners.length - 1; i >= 0; i--) { + if (listeners[i] === fn) { + listeners.splice(i, 1); + } + } + }, + + setHash: function (s) { + // Mozilla always adds an entry to the history + if (this.mode === 'legacy') { + this.writeFrame(s); + } + + if (this.history === true) { + window.history.pushState({}, document.title, s); + // Fire an onpopstate event manually since pushing does not obviously + // trigger the pop event. + this.fire(); + } else { + dloc.hash = (s[0] === '/') ? s : '/' + s; + } + return this; + }, + + writeFrame: function (s) { + // IE support... + var f = document.getElementById('state-frame'); + var d = f.contentDocument || f.contentWindow.document; + d.open(); + d.write(" + + + + + + + diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/browser/helpers/api.js b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/helpers/api.js new file mode 100644 index 000000000..d784700aa --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/helpers/api.js @@ -0,0 +1,77 @@ +module("Director.js", { + setup: function() { + window.location.hash = ""; + shared = {}; + // Init needed keys earlier because of in HTML5 mode the route handler + // is executed upon Router.init() and due to that setting shared.fired + // in the param test of createTest is too late + if (HTML5TEST) { + shared.fired = []; + shared.fired_count = 0; + } + }, + teardown: function() { + window.location.hash = ""; + shared = {}; + } +}); + +var shared; + +function createTest(name, config, use, test, initialRoute) { + // We rename to `RouterAlias` for the browserify tests, since we want to be + // sure that no code is depending on `window.Router` being available. + var Router = window.Router || window.RouterAlias; + + if (typeof use === 'function') { + test = use; + use = undefined; + } + + if (HTML5TEST) { + if (use === undefined) { + use = {}; + } + + if (use.run_handler_in_init === undefined) { + use.run_handler_in_init = false; + } + use.html5history = true; + } + + // Because of the use of setTimeout when defining onpopstate + var innerTimeout = HTML5TEST === true ? 500 : 0; + + asyncTest(name, function() { + setTimeout(function() { + var router = new Router(config), + context; + + if (use !== undefined) { + router.configure(use); + } + + router.init(initialRoute); + + setTimeout(function() { + test.call(context = { + router: router, + navigate: function(url, callback) { + if (HTML5TEST) { + router.setRoute(url); + } else { + window.location.hash = url; + } + setTimeout(function() { + callback.call(context); + }, 14); + }, + finish: function() { + router.destroy(); + start(); + } + }) + }, innerTimeout); + }, 14); + }); +}; diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-harness.html b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-harness.html new file mode 100644 index 000000000..eaf8ffc24 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-harness.html @@ -0,0 +1,23 @@ + + + + + Director HTML5 Tests + + + +

Note: in order to execute HTML5 mode test this file needs to be served with provided nodejs backend. Start the server from director/test/browser/backend and go to http://localhost:8080/ to launch the tests.

+ +
+
+ + + + + + + + + diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-test.js new file mode 100644 index 000000000..628d3c970 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/html5-routes-test.js @@ -0,0 +1,660 @@ +var browser_history_support = (window.history != null ? window.history.pushState : null) != null; + +createTest('Nested route with the many children as a tokens, callbacks should yield historic params', { + '/a': { + '/:id': { + '/:id': function(a, b) { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, ''), a, b); + } else { + shared.fired.push(location.pathname, a, b); + } + } + } + } +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['/a/b/c', 'b', 'c']); + this.finish(); + }); +}); + +createTest('Nested route with the first child as a token, callback should yield a param', { + '/foo': { + '/:id': { + on: function(id) { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, ''), id); + } else { + shared.fired.push(location.pathname, id); + } + } + } + } +}, function() { + this.navigate('/foo/a', function() { + this.navigate('/foo/b/c', function() { + deepEqual(shared.fired, ['/foo/a', 'a']); + this.finish(); + }); + }); +}); + +createTest('Nested route with the first child as a regexp, callback should yield a param', { + '/foo': { + '/(\\w+)': { + on: function(value) { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, ''), value); + } else { + shared.fired.push(location.pathname, value); + } + } + } + } +}, function() { + this.navigate('/foo/a', function() { + this.navigate('/foo/b/c', function() { + deepEqual(shared.fired, ['/foo/a', 'a']); + this.finish(); + }); + }); +}); + +createTest('Nested route with the several regular expressions, callback should yield a param', { + '/a': { + '/(\\w+)': { + '/(\\w+)': function(a, b) { + shared.fired.push(a, b); + } + } + } +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['b', 'c']); + this.finish(); + }); +}); + +createTest('Single nested route with on member containing function value', { + '/a': { + '/b': { + on: function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } + } + } +}, function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['/a/b']); + this.finish(); + }); +}); + +createTest('Single non-nested route with on member containing function value', { + '/a/b': { + on: function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } + } +}, function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['/a/b']); + this.finish(); + }); +}); + +createTest('Single nested route with on member containing array of function values', { + '/a': { + '/b': { + on: [function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + }, + function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + }] + } + } +}, function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['/a/b', '/a/b']); + this.finish(); + }); +}); + +createTest('method should only fire once on the route.', { + '/a': { + '/b': { + once: function() { + shared.fired_count++; + } + } + } +}, function() { + this.navigate('/a/b', function() { + this.navigate('/a/b', function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired_count, 1); + this.finish(); + }); + }); + }); +}); + +createTest('method should only fire once on the route, multiple nesting.', { + '/a': { + on: function() { shared.fired_count++; }, + once: function() { shared.fired_count++; } + }, + '/b': { + on: function() { shared.fired_count++; }, + once: function() { shared.fired_count++; } + } +}, function() { + this.navigate('/a', function() { + this.navigate('/b', function() { + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired_count, 6); + this.finish(); + }); + }); + }); + }); +}); + +createTest('overlapping routes with tokens.', { + '/a/:b/c' : function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + }, + '/a/:b/c/:d' : function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } +}, function() { + this.navigate('/a/b/c', function() { + + this.navigate('/a/b/c/d', function() { + deepEqual(shared.fired, ['/a/b/c', '/a/b/c/d']); + this.finish(); + }); + }); +}); + +// // // +// // // Recursion features +// // // ---------------------------------------------------------- + +createTest('Nested routes with no recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c']); + this.finish(); + }); +}); + +createTest('Nested routes with backward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'backward' +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c', 'b', 'a']); + this.finish(); + }); +}); + +createTest('Breaking out of nested routes with backward recursion', { + '/a': { + '/:b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + return false; + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'backward' +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c', 'b']); + this.finish(); + }); +}); + +createTest('Nested routes with forward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['a', 'b', 'c']); + this.finish(); + }); +}); + +createTest('Nested routes with forward recursion, single route with an after event.', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + }, + after: function() { + shared.fired.push('c-after'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + this.navigate('/a/b/c', function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['a', 'b', 'c', 'c-after', 'a', 'b']); + this.finish(); + }); + }); +}); + +createTest('Breaking out of nested routes with forward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + return false; + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['a', 'b']); + this.finish(); + }); +}); + +// +// ABOVE IS WORKING +// + +// // +// // Special Events +// // ---------------------------------------------------------- + +createTest('All global event should fire after every route', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + '/c': { + on: function a() { + shared.fired.push('a'); + } + } + }, + '/d': { + '/:e': { + on: function a() { + shared.fired.push('a'); + } + } + } +}, { + after: function() { + shared.fired.push('b'); + } +}, function() { + this.navigate('/a', function() { + this.navigate('/b/c', function() { + this.navigate('/d/e', function() { + deepEqual(shared.fired, ['a', 'b', 'a', 'b', 'a']); + this.finish(); + }); + }); + }); + +}); + +createTest('Not found.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + notfound: function() { + shared.fired.push('notfound'); + } +}, function() { + this.navigate('/c', function() { + this.navigate('/d', function() { + deepEqual(shared.fired, ['notfound', 'notfound']); + this.finish(); + }); + }); +}); + +createTest('On all.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + on: function() { + shared.fired.push('c'); + } +}, function() { + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired, ['a', 'c', 'b', 'c']); + this.finish(); + }); + }); +}); + + +createTest('After all.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + after: function() { + shared.fired.push('c'); + } +}, function() { + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired, ['a', 'c', 'b']); + this.finish(); + }); + }); +}); + +createTest('resource object.', { + '/a': { + '/b/:c': { + on: 'f1' + }, + on: 'f2' + }, + '/d': { + on: ['f1', 'f2'] + } +}, +{ + resource: { + f1: function (name){ + shared.fired.push("f1-" + name); + }, + f2: function (name){ + shared.fired.push("f2"); + } + } +}, function() { + this.navigate('/a/b/c', function() { + this.navigate('/d', function() { + deepEqual(shared.fired, ['f1-c', 'f1-undefined', 'f2']); + this.finish(); + }); + }); +}); + +createTest('argument matching should be case agnostic', { + '/fooBar/:name': { + on: function(name) { + shared.fired.push("fooBar-" + name); + } + } +}, function() { + this.navigate('/fooBar/tesTing', function() { + deepEqual(shared.fired, ['fooBar-tesTing']); + this.finish(); + }); +}); + +createTest('sanity test', { + '/is/:this/:sane': { + on: function(a, b) { + shared.fired.push('yes ' + a + ' is ' + b); + } + }, + '/': { + on: function() { + shared.fired.push('is there sanity?'); + } + } +}, function() { + this.navigate('/is/there/sanity', function() { + deepEqual(shared.fired, ['yes there is sanity']); + this.finish(); + }); +}); + +createTest('`/` route should be navigable from the routing table', { + '/': { + on: function root() { + shared.fired.push('/'); + } + }, + '/:username': { + on: function afunc(username) { + shared.fired.push('/' + username); + } + } +}, function() { + this.navigate('/', function root() { + deepEqual(shared.fired, ['/']); + this.finish(); + }); +}); + +createTest('`/` route should not override a `/:token` route', { + '/': { + on: function root() { + shared.fired.push('/'); + } + }, + '/:username': { + on: function afunc(username) { + shared.fired.push('/' + username); + } + } +}, function() { + this.navigate('/a', function afunc() { + deepEqual(shared.fired, ['/a']); + this.finish(); + }); +}); + +createTest('should accept the root as a token.', { + '/:a': { + on: function root() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } + } +}, function() { + this.navigate('/a', function root() { + deepEqual(shared.fired, ['/a']); + this.finish(); + }); +}); + +createTest('routes should allow wildcards.', { + '/:a/b*d': { + on: function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } + } +}, function() { + this.navigate('/a/bcd', function root() { + deepEqual(shared.fired, ['/a/bcd']); + this.finish(); + }); +}); + +createTest('functions should have |this| context of the router instance.', { + '/': { + on: function root() { + shared.fired.push(!!this.routes); + } + } +}, function() { + this.navigate('/', function root() { + deepEqual(shared.fired, [true]); + this.finish(); + }); +}); + +createTest('setRoute with a single parameter should change location correctly', { + '/bonk': { + on: function() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(window.location.pathname); + } + } + } +}, function() { + var self = this; + this.router.setRoute('/bonk'); + setTimeout(function() { + deepEqual(shared.fired, ['/bonk']); + self.finish(); + }, 14) +}); + +createTest('route should accept _ and . within parameters', { + '/:a': { + on: function root() { + if (!browser_history_support) { + shared.fired.push(location.hash.replace(/^#/, '')); + } else { + shared.fired.push(location.pathname); + } + } + } +}, function() { + this.navigate('/a_complex_route.co.uk', function root() { + deepEqual(shared.fired, ['/a_complex_route.co.uk']); + this.finish(); + }); +}); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-harness.html b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-harness.html new file mode 100644 index 000000000..c97c82667 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-harness.html @@ -0,0 +1,21 @@ + + + + + Director Tests + + + +
+
+ + + + + + + + + diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-test.js new file mode 100644 index 000000000..93831c212 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/browser/routes-test.js @@ -0,0 +1,739 @@ + +createTest('Nested route with the many children as a tokens, callbacks should yield historic params', { + '/a': { + '/:id': { + '/:id': function(a, b) { + shared.fired.push(location.hash, a, b); + } + } + } +}, function() { + shared.fired = []; + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['#/a/b/c', 'b', 'c']); + this.finish(); + }); +}); + +createTest('Nested route with the first child as a token, callback should yield a param', { + '/foo': { + '/:id': { + on: function(id) { + shared.fired.push(location.hash, id); + } + } + } +}, function() { + shared.fired = []; + this.navigate('/foo/a', function() { + this.navigate('/foo/b/c', function() { + deepEqual(shared.fired, ['#/foo/a', 'a']); + this.finish(); + }); + }); +}); + +createTest('Nested route with the first child as a regexp, callback should yield a param', { + '/foo': { + '/(\\w+)': { + on: function(value) { + shared.fired.push(location.hash, value); + } + } + } +}, function() { + shared.fired = []; + this.navigate('/foo/a', function() { + this.navigate('/foo/b/c', function() { + deepEqual(shared.fired, ['#/foo/a', 'a']); + this.finish(); + }); + }); +}); + +createTest('Nested route with the several regular expressions, callback should yield a param', { + '/a': { + '/(\\w+)': { + '/(\\w+)': function(a, b) { + shared.fired.push(a, b); + } + } + } +}, function() { + shared.fired = []; + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['b', 'c']); + this.finish(); + }); +}); + + + +createTest('Single nested route with on member containing function value', { + '/a': { + '/b': { + on: function() { + shared.fired.push(location.hash); + } + } + } +}, function() { + shared.fired = []; + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['#/a/b']); + this.finish(); + }); +}); + +createTest('Single non-nested route with on member containing function value', { + '/a/b': { + on: function() { + shared.fired.push(location.hash); + } + } +}, function() { + shared.fired = []; + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['#/a/b']); + this.finish(); + }); +}); + +createTest('Single nested route with on member containing array of function values', { + '/a': { + '/b': { + on: [function() { shared.fired.push(location.hash); }, + function() { shared.fired.push(location.hash); }] + } + } +}, function() { + shared.fired = []; + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['#/a/b', '#/a/b']); + this.finish(); + }); +}); + +createTest('method should only fire once on the route.', { + '/a': { + '/b': { + once: function() { + shared.fired++; + } + } + } +}, function() { + shared.fired = 0; + this.navigate('/a/b', function() { + this.navigate('/a/b', function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, 1); + this.finish(); + }); + }); + }); +}); + +createTest('method should only fire once on the route, multiple nesting.', { + '/a': { + on: function() { shared.fired++; }, + once: function() { shared.fired++; } + }, + '/b': { + on: function() { shared.fired++; }, + once: function() { shared.fired++; } + } +}, function() { + shared.fired = 0; + this.navigate('/a', function() { + this.navigate('/b', function() { + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired, 6); + this.finish(); + }); + }); + }); + }); +}); + +createTest('overlapping routes with tokens.', { + '/a/:b/c' : function() { + shared.fired.push(location.hash); + }, + '/a/:b/c/:d' : function() { + shared.fired.push(location.hash); + } +}, function() { + shared.fired = []; + this.navigate('/a/b/c', function() { + + this.navigate('/a/b/c/d', function() { + deepEqual(shared.fired, ['#/a/b/c', '#/a/b/c/d']); + this.finish(); + }); + }); +}); + +// // // +// // // Recursion features +// // // ---------------------------------------------------------- + +createTest('Nested routes with no recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c']); + this.finish(); + }); +}); + +createTest('Nested routes with backward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'backward' +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c', 'b', 'a']); + this.finish(); + }); +}); + +createTest('Breaking out of nested routes with backward recursion', { + '/a': { + '/:b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + return false; + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'backward' +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['c', 'b']); + this.finish(); + }); +}); + +createTest('Nested routes with forward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['a', 'b', 'c']); + this.finish(); + }); +}); + +createTest('Nested routes with forward recursion, single route with an after event.', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + }, + after: function() { + shared.fired.push('c-after'); + } + }, + on: function b() { + shared.fired.push('b'); + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + this.navigate('/a/b', function() { + deepEqual(shared.fired, ['a', 'b', 'c', 'c-after', 'a', 'b']); + this.finish(); + }); + }); +}); + +createTest('Breaking out of nested routes with forward recursion', { + '/a': { + '/b': { + '/c': { + on: function c() { + shared.fired.push('c'); + } + }, + on: function b() { + shared.fired.push('b'); + return false; + } + }, + on: function a() { + shared.fired.push('a'); + } + } +}, { + recurse: 'forward' +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + deepEqual(shared.fired, ['a', 'b']); + this.finish(); + }); +}); + +// +// ABOVE IS WORKING +// + +// // +// // Special Events +// // ---------------------------------------------------------- + +createTest('All global event should fire after every route', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + '/c': { + on: function a() { + shared.fired.push('a'); + } + } + }, + '/d': { + '/:e': { + on: function a() { + shared.fired.push('a'); + } + } + } +}, { + after: function() { + shared.fired.push('b'); + } +}, function() { + shared.fired = []; + + this.navigate('/a', function() { + this.navigate('/b/c', function() { + this.navigate('/d/e', function() { + deepEqual(shared.fired, ['a', 'b', 'a', 'b', 'a']); + this.finish(); + }); + }); + }); + +}); + +createTest('Not found.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + notfound: function() { + shared.fired.push('notfound'); + } +}, function() { + shared.fired = []; + + this.navigate('/c', function() { + this.navigate('/d', function() { + deepEqual(shared.fired, ['notfound', 'notfound']); + this.finish(); + }); + }); +}); + +createTest('On all.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + on: function() { + shared.fired.push('c'); + } +}, function() { + shared.fired = []; + + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired, ['a', 'c', 'b', 'c']); + this.finish(); + }); + }); +}); + + +createTest('After all.', { + '/a': { + on: function a() { + shared.fired.push('a'); + } + }, + '/b': { + on: function a() { + shared.fired.push('b'); + } + } +}, { + after: function() { + shared.fired.push('c'); + } +}, function() { + shared.fired = []; + + this.navigate('/a', function() { + this.navigate('/b', function() { + deepEqual(shared.fired, ['a', 'c', 'b']); + this.finish(); + }); + }); +}); + +createTest('resource object.', { + '/a': { + '/b/:c': { + on: 'f1' + }, + on: 'f2' + }, + '/d': { + on: ['f1', 'f2'] + } +}, +{ + resource: { + f1: function (name){ + shared.fired.push("f1-" + name); + }, + f2: function (name){ + shared.fired.push("f2"); + } + } +}, function() { + shared.fired = []; + + this.navigate('/a/b/c', function() { + this.navigate('/d', function() { + deepEqual(shared.fired, ['f1-c', 'f1-undefined', 'f2']); + this.finish(); + }); + }); +}); + +createTest('argument matching should be case agnostic', { + '/fooBar/:name': { + on: function(name) { + shared.fired.push("fooBar-" + name); + } + } +}, function() { + shared.fired = []; + this.navigate('/fooBar/tesTing', function() { + deepEqual(shared.fired, ['fooBar-tesTing']); + this.finish(); + }); +}); + +createTest('sanity test', { + '/is/:this/:sane': { + on: function(a, b) { + shared.fired.push('yes ' + a + ' is ' + b); + } + }, + '/': { + on: function() { + shared.fired.push('is there sanity?'); + } + } +}, function() { + shared.fired = []; + this.navigate('/is/there/sanity', function() { + deepEqual(shared.fired, ['yes there is sanity']); + this.finish(); + }); +}); + +createTest('`/` route should be navigable from the routing table', { + '/': { + on: function root() { + shared.fired.push('/'); + } + }, + '/:username': { + on: function afunc(username) { + shared.fired.push('/' + username); + } + } +}, function() { + shared.fired = []; + this.navigate('/', function root() { + deepEqual(shared.fired, ['/']); + this.finish(); + }); +}); + +createTest('`/` route should not override a `/:token` route', { + '/': { + on: function root() { + shared.fired.push('/'); + } + }, + '/:username': { + on: function afunc(username) { + shared.fired.push('/' + username); + } + } +}, function() { + shared.fired = []; + this.navigate('/a', function afunc() { + deepEqual(shared.fired, ['/a']); + this.finish(); + }); +}); + +createTest('should accept the root as a token.', { + '/:a': { + on: function root() { + shared.fired.push(location.hash); + } + } +}, function() { + shared.fired = []; + this.navigate('/a', function root() { + deepEqual(shared.fired, ['#/a']); + this.finish(); + }); +}); + +createTest('routes should allow wildcards.', { + '/:a/b*d': { + on: function() { + shared.fired.push(location.hash); + } + } +}, function() { + shared.fired = []; + this.navigate('/a/bcd', function root() { + deepEqual(shared.fired, ['#/a/bcd']); + this.finish(); + }); +}); + +createTest('functions should have |this| context of the router instance.', { + '/': { + on: function root() { + shared.fired.push(!!this.routes); + } + } +}, function() { + shared.fired = []; + this.navigate('/', function root() { + deepEqual(shared.fired, [true]); + this.finish(); + }); +}); + +createTest('setRoute with a single parameter should change location correctly', { + '/bonk': { + on: function() { + shared.fired.push(window.location.hash); + } + } +}, function() { + var self = this; + shared.fired = []; + this.router.setRoute('/bonk'); + setTimeout(function() { + deepEqual(shared.fired, ['#/bonk']); + self.finish(); + }, 14) +}); + +createTest('route should accept _ and . within parameters', { + '/:a': { + on: function root() { + shared.fired.push(location.hash); + } + } +}, function() { + shared.fired = []; + this.navigate('/a_complex_route.co.uk', function root() { + deepEqual(shared.fired, ['#/a_complex_route.co.uk']); + this.finish(); + }); +}); + +createTest('initializing with a default route should only result in one route handling', { + '/': { + on: function root() { + if (!shared.init){ + shared.init = 0; + } + shared.init++; + } + }, + '/test': { + on: function root() { + if (!shared.test){ + shared.test = 0; + } + shared.test++; + } + } + }, function() { + this.navigate('/test', function root() { + equal(shared.init, 1); + equal(shared.test, 1); + this.finish(); + }); + }, + null, + '/'); + +createTest('changing the hash twice should call each route once', { + '/hash1': { + on: function root() { + shared.fired.push('hash1'); + } + }, + '/hash2': { + on: function root() { + shared.fired.push('hash2'); + } + } + }, function() { + shared.fired = []; + this.navigate('/hash1', function(){}); + this.navigate('/hash2', function(){ + deepEqual(shared.fired, ['hash1', 'hash2']); + this.finish(); + }); + } +); + +// This test doesn't use the createTest since createTest runs init on the router before +// running the test, which is what we want to test. +test('fire the correct route when initializing the router', function(){ + window.location.hash = 'initial'; + var fired = []; + var router = new (window.Router || window.RouterAlias)({ + '/initial': function(){ + fired.push('/initial'); + }, + 'initial': function(){ + fired.push('initial'); + } + }); + router.init(); + deepEqual(fired, ['/initial', 'initial']); + router.destroy(); +}); + +test('do not combine hash if convert_hash_in_init is false', function(){ + window.location.hash = 'initial'; + var fired = []; + var initialPath = window.location.pathname; + var routes = { + '/initial': function(){ + fired.push('/initial'); + }, + 'initial': function(){ + fired.push('initial'); + } + }; + routes[initialPath] = function(){ + fired.push('*'); + }; + + var router = new (window.Router || window.RouterAlias)(routes); + + router.configure({ + html5history: true, + convert_hash_in_init: false + }); + router.init(); + deepEqual(fired, ['*']); + router.destroy(); +}); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/dispatch-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/dispatch-test.js new file mode 100644 index 000000000..98dc58c30 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/dispatch-test.js @@ -0,0 +1,55 @@ +/* + * dispatch-test.js: Tests for the core dispatch method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/cli/dispatch').addBatch({ + "An instance of director.cli.Router": { + topic: function () { + var router = new director.cli.Router(), + that = this; + + that.matched = {}; + that.matched['users'] = []; + that.matched['apps'] = [] + + router.on('users create', function () { + that.matched['users'].push('on users create'); + }); + + router.on(/apps (\w+\s\w+)/, function () { + assert.equal(arguments.length, 1); + that.matched['apps'].push('on apps (\\w+\\s\\w+)'); + }); + + return router; + }, + "should have the correct routing table": function (router) { + assert.isObject(router.routes.users); + assert.isObject(router.routes.users.create); + }, + "the dispatch() method": { + "users create": function (router) { + assert.isTrue(router.dispatch('on', 'users create')); + assert.equal(this.matched.users[0], 'on users create'); + }, + "apps foo bar": function (router) { + assert.isTrue(router.dispatch('on', 'apps foo bar')); + assert.equal(this.matched['apps'][0], 'on apps (\\w+\\s\\w+)'); + }, + "not here": function (router) { + assert.isFalse(router.dispatch('on', 'not here')); + }, + "still not here": function (router) { + assert.isFalse(router.dispatch('on', 'still not here')); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/mount-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/mount-test.js new file mode 100644 index 000000000..fe92b3528 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/mount-test.js @@ -0,0 +1,30 @@ +/* + * mount-test.js: Tests for the core mount method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/cli/path').addBatch({ + "An instance of director.cli.Router with routes": { + topic: new director.cli.Router({ + 'apps': function () { + console.log('apps'); + }, + ' users': function () { + console.log('users'); + } + }), + "should create the correct nested routing table": function (router) { + assert.isObject(router.routes.apps); + assert.isFunction(router.routes.apps.on); + assert.isObject(router.routes.users); + assert.isFunction(router.routes.users.on); + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/path-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/path-test.js new file mode 100644 index 000000000..08b4b5510 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/cli/path-test.js @@ -0,0 +1,39 @@ +/* + * dispatch-test.js: Tests for the core dispatch method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/cli/path').addBatch({ + "An instance of director.cli.Router": { + topic: new director.cli.Router(), + "the path() method": { + "should create the correct nested routing table": function (router) { + function noop () {} + + router.path(/apps/, function () { + router.path(/foo/, function () { + router.on(/bar/, noop); + }); + + router.on(/list/, noop); + }); + + router.on(/users/, noop); + + assert.isObject(router.routes.apps); + assert.isFunction(router.routes.apps.list.on); + assert.isObject(router.routes.apps.foo); + assert.isFunction(router.routes.apps.foo.bar.on); + assert.isFunction(router.routes.users.on); + } + } + } +}).export(module); + diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/dispatch-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/dispatch-test.js new file mode 100644 index 000000000..53a33de45 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/dispatch-test.js @@ -0,0 +1,113 @@ +/* + * dispatch-test.js: Tests for the core dispatch method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/core/dispatch').addBatch({ + "An instance of director.Router": { + topic: function () { + var that = this; + that.matched = {}; + that.matched['/'] = []; + that.matched['foo'] = []; + that.matched['f*'] = [] + + var router = new director.Router({ + '/': { + before: function () { that.matched['/'].push('before /') }, + on: function () { that.matched['/'].push('on /') }, + after: function () { that.matched['/'].push('after /') } + }, + '/foo': { + before: function () { that.matched.foo.push('before foo') }, + on: function () { that.matched.foo.push('on foo') }, + after: function () { that.matched.foo.push('after foo') }, + '/bar': { + before: function () { that.matched.foo.push('before foo bar') }, + on: function () { that.matched.foo.push('foo bar') }, + after: function () { that.matched.foo.push('after foo bar') }, + '/buzz': function () { that.matched.foo.push('foo bar buzz') } + } + }, + '/f*': { + '/barbie': function () { that.matched['f*'].push('f* barbie') } + } + }); + + router.configure({ + recurse: 'backward' + }); + + return router; + }, + "should have the correct routing table": function (router) { + assert.isObject(router.routes.foo); + assert.isObject(router.routes.foo.bar); + assert.isObject(router.routes.foo.bar.buzz); + assert.isFunction(router.routes.foo.bar.buzz.on); + }, + "the dispatch() method": { + "/": function (router) { + assert.isTrue(router.dispatch('on', '/')); + assert.isTrue(router.dispatch('on', '/')); + + assert.equal(this.matched['/'][0], 'before /'); + assert.equal(this.matched['/'][1], 'on /'); + assert.equal(this.matched['/'][2], 'after /'); + }, + "/foo/bar/buzz": function (router) { + assert.isTrue(router.dispatch('on', '/foo/bar/buzz')); + + assert.equal(this.matched.foo[0], 'foo bar buzz'); + assert.equal(this.matched.foo[1], 'before foo bar'); + assert.equal(this.matched.foo[2], 'foo bar'); + assert.equal(this.matched.foo[3], 'before foo'); + assert.equal(this.matched.foo[4], 'on foo'); + }, + "/foo/barbie": function (router) { + assert.isTrue(router.dispatch('on', '/foo/barbie')); + assert.equal(this.matched['f*'][0], 'f* barbie'); + }, + "/foo/barbie/": function (router) { + assert.isFalse(router.dispatch('on', '/foo/barbie/')); + }, + "/foo/BAD": function (router) { + assert.isFalse(router.dispatch('on', '/foo/BAD')); + }, + "/bar/bar": function (router) { + assert.isFalse(router.dispatch('on', '/bar/bar')); + }, + "with the strict option disabled": { + topic: function (router) { + return router.configure({ + recurse: 'backward', + strict: false + }); + }, + "should have the proper configuration set": function (router) { + assert.isFalse(router.strict); + }, + "/foo/barbie/": function (router) { + assert.isTrue(router.dispatch('on', '/foo/barbie/')); + assert.equal(this.matched['f*'][0], 'f* barbie'); + }, + "/foo/bar/buzz": function (router) { + assert.isTrue(router.dispatch('on', '/foo/bar/buzz')); + + assert.equal(this.matched.foo[0], 'foo bar buzz'); + assert.equal(this.matched.foo[1], 'before foo bar'); + assert.equal(this.matched.foo[2], 'foo bar'); + assert.equal(this.matched.foo[3], 'before foo'); + assert.equal(this.matched.foo[4], 'on foo'); + }, + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/insert-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/insert-test.js new file mode 100644 index 000000000..c828dd9ba --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/insert-test.js @@ -0,0 +1,45 @@ +/* + * insert-test.js: Tests for inserting routes into a normalized routing table. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/core/insert').addBatch({ + "An instance of director.Router": { + topic: new director.Router(), + "the insert() method": { + "'on', ['foo', 'bar']": function (router) { + function route () { } + + router.insert('on', ['foo', 'bar'], route); + assert.strictEqual(router.routes.foo.bar.on, route); + }, + "'on', ['foo', 'bar'] again": function (router) { + function route () { } + + router.insert('on', ['foo', 'bar'], route); + assert.isArray(router.routes.foo.bar.on); + assert.strictEqual(router.routes.foo.bar.on.length, 2); + }, + "'on', ['foo', 'bar'] a third time": function (router) { + function route () { } + + router.insert('on', ['foo', 'bar'], route); + assert.isArray(router.routes.foo.bar.on); + assert.strictEqual(router.routes.foo.bar.on.length, 3); + }, + "'get', ['fizz', 'buzz']": function (router) { + function route () { } + + router.insert('get', ['fizz', 'buzz'], route); + assert.strictEqual(router.routes.fizz.buzz.get, route); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/mount-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/mount-test.js new file mode 100644 index 000000000..47eac4ac0 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/mount-test.js @@ -0,0 +1,117 @@ +/* + * mount-test.js: Tests for mounting and normalizing routes into a Router instance. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +function assertRoute (fn, path, route) { + if (path.length === 1) { + return assert.strictEqual(route[path.shift()], fn); + } + + route = route[path.shift()]; + assert.isObject(route); + assertRoute(fn, path, route); +} + +vows.describe('director/core/mount').addBatch({ + "An instance of director.Router": { + "with no preconfigured params": { + topic: new director.Router(), + "the mount() method": { + "should sanitize the routes correctly": function (router) { + function foobar () { } + function foostar () { } + function foobazzbuzz () { } + function foodog () { } + function root () {} + var fnArray = [foobar, foostar]; + + router.mount({ + '/': { + before: root, + on: root, + after: root, + '/nesting': { + on: foobar, + '/deep': foostar + } + }, + '/foo': { + '/bar': foobar, + '/*': foostar, + '/jitsu/then': { + before: foobar + } + }, + '/foo/bazz': { + '/buzz': foobazzbuzz + }, + '/foo/jitsu': { + '/then': fnArray + }, + '/foo/jitsu/then/now': foostar, + '/foo/:dog': foodog + }); + + assertRoute(root, ['on'], router.routes); + assertRoute(root, ['after'], router.routes); + assertRoute(root, ['before'], router.routes); + assertRoute(foobar, ['nesting', 'on'], router.routes); + assertRoute(foostar, ['nesting', 'deep', 'on'], router.routes); + assertRoute(foobar, [ 'foo', 'bar', 'on'], router.routes); + assertRoute(foostar, ['foo', '([_.()!\\ %@&a-zA-Z0-9-]+)', 'on'], router.routes); + assertRoute(fnArray, ['foo', 'jitsu', 'then', 'on'], router.routes); + assertRoute(foobar, ['foo', 'jitsu', 'then', 'before'], router.routes); + assertRoute(foobazzbuzz, ['foo', 'bazz', 'buzz', 'on'], router.routes); + assertRoute(foostar, ['foo', 'jitsu', 'then', 'now', 'on'], router.routes); + assertRoute(foodog, ['foo', '([._a-zA-Z0-9-%()]+)', 'on'], router.routes); + }, + + "should accept string path": function(router) { + function dogs () { } + + router.mount({ + '/dogs': { + on: dogs + } + }, + '/api'); + + assertRoute(dogs, ['api', 'dogs', 'on'], router.routes); + } + } + }, + "with preconfigured params": { + topic: function () { + var router = new director.Router(); + router.param('city', '([\\w\\-]+)'); + router.param(':country', /([A-Z][A-Za-z]+)/); + router.param(':zip', /([\d]{5})/); + return router; + }, + "should sanitize the routes correctly": function (router) { + function usaCityZip () { } + function countryCityZip () { } + + router.mount({ + '/usa/:city/:zip': usaCityZip, + '/world': { + '/:country': { + '/:city/:zip': countryCityZip + } + } + }); + + assertRoute(usaCityZip, ['usa', '([\\w\\-]+)', '([\\d]{5})', 'on'], router.routes); + assertRoute(countryCityZip, ['world', '([A-Z][A-Za-z]+)', '([\\w\\-]+)', '([\\d]{5})', 'on'], router.routes); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/on-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/on-test.js new file mode 100644 index 000000000..22e182dec --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/on-test.js @@ -0,0 +1,38 @@ +/* + * on-test.js: Tests for the on/route method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/core/insert').addBatch({ + "An instance of director.Router": { + topic: new director.Router(), + "the on() method": { + "['foo', 'bar']": function (router) { + function noop () { } + + router.on(['foo', 'bar'], noop); + assert.strictEqual(router.routes.foo.on, noop); + assert.strictEqual(router.routes.bar.on, noop); + }, + "'baz'": function (router) { + function noop () { } + + router.on('baz', noop); + assert.strictEqual(router.routes.baz.on, noop); + }, + "'after', 'baz'": function (router) { + function noop () { } + + router.on('after', 'boo', noop); + assert.strictEqual(router.routes.boo.after, noop); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/path-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/path-test.js new file mode 100644 index 000000000..ec3313e27 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/path-test.js @@ -0,0 +1,49 @@ +/* + * path-test.js: Tests for the core `.path()` method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/core/path').addBatch({ + "An instance of director.Router": { + topic: function () { + var that = this; + that.matched = {}; + that.matched['foo'] = []; + that.matched['newyork'] = []; + + var router = new director.Router({ + '/foo': function () { that.matched['foo'].push('foo'); } + }); + return router; + }, + "the path() method": { + "should create the correct nested routing table": function (router) { + var that = this; + router.path('/regions', function () { + this.on('/:state', function(country) { + that.matched['newyork'].push('new york'); + }); + }); + + assert.isFunction(router.routes.foo.on); + assert.isObject(router.routes.regions); + assert.isFunction(router.routes.regions['([._a-zA-Z0-9-%()]+)'].on); + }, + "should dispatch the function correctly": function (router) { + router.dispatch('on', '/regions/newyork') + router.dispatch('on', '/foo'); + assert.equal(this.matched['foo'].length, 1); + assert.equal(this.matched['newyork'].length, 1); + assert.equal(this.matched['foo'][0], 'foo'); + assert.equal(this.matched['newyork'][0], 'new york'); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/regifystring-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/regifystring-test.js new file mode 100644 index 000000000..a0757885e --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/core/regifystring-test.js @@ -0,0 +1,117 @@ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +var callback = function() { + return true; +}; + +var testRoute = function(route, callback) { + var router = new director.Router(); + router.on(route, callback); + + return function(value) { + return router.dispatch('on', value); + }; +}; + +vows.describe('director/core/regifyString').addBatch({ + + 'When using "/home(.*)"': { + topic: function() { + return testRoute('/home(.*)', callback); + }, + + 'Should match "/homepage"': function(result) { + assert.isTrue(result('/homepage')); + }, + + 'Should match "/home/page"': function(result) { + assert.isTrue(result('/home/page')); + }, + + 'Should not match "/foo-bar"': function(result) { + assert.isFalse(result('/foo-bar')); + } + }, + + 'When using "/home.*"': { + topic: function() { + return testRoute('/home.*', callback); + }, + + 'Should match "/homepage"': function(result) { + assert.isTrue(result('/homepage')); + }, + + 'Should match "/home/page"': function(result) { + assert.isTrue(result('/home/page')); + }, + + 'Should not match "/foo-bar"': function(result) { + assert.isFalse(result('/foo-bar')); + } + }, + + 'When using "/home(page[0-9])*"': { + topic: function() { + return testRoute('/home(page[0-9])*', callback); + }, + + 'Should match "/home"': function(result) { + assert.isTrue(result('/home')); + }, + + 'Should match "/homepage0", "/homepage1", etc.': function(result) { + for (i = 0; i < 10; i++) { + assert.isTrue(result('/homepage' + i)); + } + }, + + 'Should not match "/home_page"': function(result) { + assert.isFalse(result('/home_page')); + }, + + 'Should not match "/home/page"': function(result) { + assert.isFalse(result('/home/page')); + } + }, + + 'When using "/home*"': { + topic: function() { + return testRoute('/home*', callback); + }, + + 'Should match "/homepage"': function(result) { + assert.isTrue(result('/homepage')); + }, + + 'Should match "/home_page"': function(result) { + assert.isTrue(result('/home_page')); + }, + + 'Should match "/home-page"': function(result) { + assert.isTrue(result('/home-page')); + }, + + 'Should not match "/home/page"': function(result) { + assert.isFalse(result('/home/page')); + } + }, + 'When using "/folder/::home"': { + topic: function() { + return testRoute('/folder/::home', callback); + }, + 'Should match "/folder/:home"': function(result) { + assert.isTrue(result('/folder/:home')); + }, + 'Should not match "/folder/::home"': function(result) { + assert.isFalse(result('/folder/::home')); + }, + 'Should not match "/folder/abc" (the catchall regexp)': function(result) { + assert.isFalse(result('/folder/abc')); + } + } + +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/index.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/index.js new file mode 100644 index 000000000..2104da69b --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/index.js @@ -0,0 +1,52 @@ +/* + * index.js: Test helpers for director. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var http = require('http'); + +exports.createServer = function (router) { + return http.createServer(function (req, res) { + router.dispatch(req, res, function (err) { + if (err) { + res.writeHead(404); + res.end(); + } + }); + }); +}; + +exports.handlers = { + respondWithId: function (id) { + this.res.writeHead(200, { 'Content-Type': 'text/plain' }) + this.res.end('hello from (' + id + ')'); + }, + respondWithData: function () { + this.res.writeHead(200, { 'Content-Type': 'application/json' }) + this.res.end(JSON.stringify(this.data)); + }, + respondWithOk: function () { + return function () { + this.res.writeHead(200); + this.res.end('ok'); + }; + }, + streamBody: function () { + var body = '', + res = this.res; + + this.req.on('data', function (chunk) { + body += chunk; + }); + + this.req.on('end', function () { + res.writeHead(200, { 'Content-Type': 'application/json' }); + res.end(body); + }); + } +}; + +exports.macros = require('./macros'); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/macros.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/macros.js new file mode 100644 index 000000000..d97a17e11 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/helpers/macros.js @@ -0,0 +1,55 @@ +/* + * macros.js: Test macros for director tests. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + request = require('request'); + +exports.assertGet = function(port, uri, expected) { + var context = { + topic: function () { + request({ uri: 'http://localhost:' + port + '/' + uri }, this.callback); + } + }; + + context['should respond with `' + expected + '`'] = function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 200); + assert.equal(body, expected); + }; + + return context; +}; + +exports.assert404 = function (port, uri) { + return { + topic: function () { + request({ uri: 'http://localhost:' + port + '/' + uri }, this.callback); + }, + "should respond with 404": function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 404); + } + }; +}; + +exports.assertPost = function(port, uri, expected) { + return { + topic: function () { + request({ + method: 'POST', + uri: 'http://localhost:' + port + '/' + uri, + body: JSON.stringify(expected) + }, this.callback); + }, + "should respond with the POST body": function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 200); + assert.deepEqual(JSON.parse(body), expected); + } + }; +}; diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/accept-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/accept-test.js new file mode 100644 index 000000000..7353a7087 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/accept-test.js @@ -0,0 +1,88 @@ +/* + * accept-test.js: Tests for `content-type`-based routing + * + * (C) 2012, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + apiEasy = require('api-easy'), + director = require('../../../lib/director'), + helpers = require('../helpers'), + macros = helpers.macros, + handlers = helpers.handlers; + +var PORT = 9067; + +apiEasy.describe('director/http/accept') + .addBatch({ + "An instance of `director.http.Router`": { + "with routes set up": { + topic: function () { + var router = new director.http.Router(); + router.get('/json', { accept: 'application/json' }, handlers.respondWithOk()); + router.get('/txt', { accept: 'text/plain' }, handlers.respondWithOk()); + router.get('/both', { accept: ['text/plain', 'application/json'] }, handlers.respondWithOk()); + router.get('/regex', { accept: /.+\/x\-.+/ }, handlers.respondWithOk()); + + router.get('/weird', { accept: 'application/json' }, function () { + this.res.writeHead(400); + this.res.end(); + }); + + router.get('/weird', handlers.respondWithOk()); + + helpers.createServer(router).listen(PORT, this.callback); + }, + "should be created": function (err) { + assert(!err); + } + } + } + }) + .use('localhost', PORT) + .discuss('with `content-type: application/json`') + .setHeader('content-type', 'application/json') + .get('/json') + .expect(200) + .get('/txt') + .expect(404) + .get('/both') + .expect(200) + .get('/regex') + .expect(404) + .get('/weird') + .expect(400) + .undiscuss() + .next() + .discuss('with `content-type: text/plain`') + .setHeader('content-type', 'text/plain') + .get('/json') + .expect(404) + .get('/txt') + .expect(200) + .get('/both') + .expect(200) + .get('/regex') + .expect(404) + .get('/weird') + .expect(200) + .undiscuss() + .next() + .discuss('with `content-type: application/x-tar-gz`') + .setHeader('content-type', 'application/x-tar-gz`') + .get('/json') + .get('/json') + .expect(404) + .get('/txt') + .expect(404) + .get('/both') + .expect(404) + .get('/regex') + .expect(200) + .get('/weird') + .expect(200) + .undiscuss() + .export(module); + diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/attach-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/attach-test.js new file mode 100644 index 000000000..9fb320a70 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/attach-test.js @@ -0,0 +1,51 @@ +/* + * attach-test.js: Tests 'router.attach' functionality. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + http = require('http'), + vows = require('vows'), + request = require('request'), + director = require('../../../lib/director'), + helpers = require('../helpers'), + handlers = helpers.handlers, + macros = helpers.macros; + +function assertData(uri) { + return macros.assertGet( + 9091, + uri, + JSON.stringify([1,2,3]) + ); +} + +vows.describe('director/http/attach').addBatch({ + "An instance of director.http.Router": { + "instantiated with a Routing table": { + topic: new director.http.Router({ + '/hello': { + get: handlers.respondWithData + } + }), + "should have the correct routes defined": function (router) { + assert.isObject(router.routes.hello); + assert.isFunction(router.routes.hello.get); + }, + "when passed to an http.Server instance": { + topic: function (router) { + router.attach(function () { + this.data = [1,2,3]; + }); + + helpers.createServer(router) + .listen(9091, this.callback); + }, + "a request to hello": assertData('hello'), + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/before-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/before-test.js new file mode 100644 index 000000000..9502c87b3 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/before-test.js @@ -0,0 +1,38 @@ +/* + * before-test.js: Tests for running before methods on HTTP server(s). + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + http = require('http'), + vows = require('vows'), + request = require('request'), + director = require('../../../lib/director'), + helpers = require('../helpers'), + handlers = helpers.handlers, + macros = helpers.macros; + +vows.describe('director/http/before').addBatch({ + "An instance of director.http.Router": { + "with ad-hoc routes including .before()": { + topic: function () { + var router = new director.http.Router(); + + router.before('/hello', function () { }); + router.after('/hello', function () { }); + router.get('/hello', handlers.respondWithId); + + return router; + }, + "should have the correct routes defined": function (router) { + assert.isObject(router.routes.hello); + assert.isFunction(router.routes.hello.before); + assert.isFunction(router.routes.hello.after); + assert.isFunction(router.routes.hello.get); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/configure-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/configure-test.js new file mode 100644 index 000000000..11b274e17 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/configure-test.js @@ -0,0 +1,37 @@ +/* + * on-test.js: Tests for the on/route method. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/core/configure').addBatch({ + "An instance of director.Router": { + topic: new director.http.Router(), + "the configure() method": { + "called with an empty object": { + "should default recurse to 'forward'": function(router) { + router.configure({}); + assert.strictEqual(router.recurse, 'forward'); + } + }, + "called with recurse = false": { + "should set recurse to false": function(router) { + router.configure({ recurse: false }); + assert.strictEqual(router.recurse, false); + } + }, + "called with recurse = 'backward'": { + "should set recurse to 'backward'": function(router) { + router.configure({ recurse: 'backward' }); + assert.strictEqual(router.recurse, 'backward'); + } + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/http-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/http-test.js new file mode 100644 index 000000000..8bfe0b204 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/http-test.js @@ -0,0 +1,96 @@ +/* + * http-test.js: Tests for basic HTTP server(s). + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + http = require('http'), + vows = require('vows'), + request = require('request'), + director = require('../../../lib/director'), + helpers = require('../helpers'), + handlers = helpers.handlers, + macros = helpers.macros; + +function assertBark(uri) { + return macros.assertGet( + 9090, + uri, + 'hello from (bark)' + ); +} + +vows.describe('director/http').addBatch({ + "An instance of director.http.Router": { + "instantiated with a Routing table": { + topic: new director.http.Router({ + '/hello': { + get: handlers.respondWithId + } + }), + "should have the correct routes defined": function (router) { + assert.isObject(router.routes.hello); + assert.isFunction(router.routes.hello.get); + }, + "when passed to an http.Server instance": { + topic: function (router) { + router.get(/foo\/bar\/(\w+)/, handlers.respondWithId); + router.get(/add\/:param\/bark/, handlers.respondWithId); + router.get(/foo\/update\/(\w+)/, handlers.respondWithId); + router.path(/bar\/bazz\//, function () { + this.get(/(\w+)/, handlers.respondWithId); + }); + router.get(/\/foo\/wild\/(.*)/, handlers.respondWithId); + router.get(/(\/v2)?\/somepath/, handlers.respondWithId); + + helpers.createServer(router) + .listen(9090, this.callback); + }, + "a request to foo/bar/bark": assertBark('foo/bar/bark'), + "a request to foo/update/bark": assertBark('foo/update/bark'), + "a request to bar/bazz/bark": assertBark('bar/bazz/bark'), + "a request to foo/bar/bark?test=test": assertBark('foo/bar/bark?test=test'), + "a request to foo/wild/bark": assertBark('foo/wild/bark'), + "a request to add/:param/bark": { + topic: function () { + request({ uri: 'http://localhost:9090/add/test/bark' }, this.callback); + }, + 'should respond and parse the params': function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 200); + assert.equal(body, 'hello from (test)'); + } + }, + "an encoded request to add/:param/bark": { + topic: function () { + request({ uri: 'http://localhost:9090/add/something%40example.com/bark' }, this.callback); + }, + 'should respond and parse the params': function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 200); + assert.equal(body, 'hello from (something%40example.com)'); + } + }, + "an encoded request to add/:param/bark with additional special characters": { + topic: function () { + request({ uri: 'http://localhost:9090/add/something%40(example).com/bark' }, this.callback); + }, + 'should respond and parse the params': function (err, res, body) { + assert.isNull(err); + assert.equal(res.statusCode, 200); + assert.equal(body, 'hello from (something%40(example).com)'); + } + }, + "a request to foo/%RT": macros.assert404(9090, 'foo/%RT'), + "a request to /v2/somepath": macros.assertGet( + 9090, + '/v2/somepath', + 'hello from (/v2)' + ) + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/methods-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/methods-test.js new file mode 100644 index 000000000..13a257422 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/methods-test.js @@ -0,0 +1,42 @@ +/* + * methods-test.js: Tests for HTTP methods. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/http/methods').addBatch({ + "When using director": { + "an instance of director.http.Router should have all relevant RFC methods": function () { + var router = new director.http.Router(); + director.http.methods.forEach(function (method) { + assert.isFunction(router[method.toLowerCase()]); + }); + }, + "the path() method": { + topic: new director.http.Router(), + "/resource": { + "should insert nested routes correct": function (router) { + function getResource() {} + function modifyResource() {} + + router.path(/\/resource/, function () { + this.get(getResource); + + this.put(/\/update/, modifyResource); + this.post(/create/, modifyResource); + }); + + assert.equal(router.routes.resource.get, getResource); + assert.equal(router.routes.resource.update.put, modifyResource); + assert.equal(router.routes.resource.create.post, modifyResource); + } + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/recursion-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/recursion-test.js new file mode 100644 index 000000000..3b508edef --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/recursion-test.js @@ -0,0 +1,43 @@ +/* + * recursion-test.js: Tests for recursive route retrieval. + * + * (C) 2011, Nodejitsu Inc. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/http/index').addBatch({ + "the traverse() method" : { + topic: new director.http.Router(), + "/some/1/nested/2/route/3" : { + "should return a stack of three functions and three captures" : function(router) { + function alpha() {} + function beta() {} + function gamma() {} + + router.path('/some/:id', function() { + this.get(alpha); + this.path('/nested/:id', function() { + this.get(beta); + this.path('/route/:id', function() { + this.get(gamma); + }); + }); + }); + + var fns = router.traverse('get', '/some/1/nested/2/route/3', router.routes, ''); + var runlist = router.runlist(fns); + assert.equal(runlist[0], gamma); + assert.equal(runlist[1], beta); + assert.equal(runlist[2], alpha); + assert.equal(runlist.captures[0], 1); + assert.equal(runlist.captures[1], 2); + assert.equal(runlist.captures[2], 3); + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/responses-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/responses-test.js new file mode 100644 index 000000000..3f6b92364 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/responses-test.js @@ -0,0 +1,21 @@ +/* + * responses-test.js: Tests for HTTP responses. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + vows = require('vows'), + director = require('../../../lib/director'); + +vows.describe('director/http/responses').addBatch({ + "When using director.http": { + "it should have the relevant responses defined": function () { + Object.keys(require('../../../lib/director/http/responses')).forEach(function (name) { + assert.isFunction(director.http[name]); + }); + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/stream-test.js b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/stream-test.js new file mode 100644 index 000000000..4a5cef51a --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/director/test/server/http/stream-test.js @@ -0,0 +1,46 @@ +/* + * stream-test.js: Tests for streaming HTTP in director. + * + * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors. + * MIT LICENSE + * + */ + +var assert = require('assert'), + http = require('http'), + vows = require('vows'), + request = require('request'), + director = require('../../../lib/director'), + helpers = require('../helpers'), + macros = helpers.macros, + handlers = helpers.handlers + +vows.describe('director/http/stream').addBatch({ + "An instance of director.http.Router": { + "with streaming routes": { + topic: function () { + var router = new director.http.Router(); + router.post(/foo\/bar/, { stream: true }, handlers.streamBody); + router.path('/a-path', function () { + this.post({ stream: true }, handlers.streamBody); + }); + + return router; + }, + "when passed to an http.Server instance": { + topic: function (router) { + helpers.createServer(router) + .listen(9092, this.callback); + }, + "a POST request to /foo/bar": macros.assertPost(9092, 'foo/bar', { + foo: 'foo', + bar: 'bar' + }), + "a POST request to /a-path": macros.assertPost(9092, 'a-path', { + foo: 'foo', + bar: 'bar' + }) + } + } + } +}).export(module); diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.bower.json b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.bower.json new file mode 100644 index 000000000..f749f663c --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.bower.json @@ -0,0 +1,14 @@ +{ + "name": "todomvc-app-css", + "homepage": "https://github.com/tastejs/todomvc-app-css", + "version": "2.0.6", + "_release": "2.0.6", + "_resolution": { + "type": "version", + "tag": "v2.0.6", + "commit": "5ade7578fef53eb3da33a4d640041a0596db0a9b" + }, + "_source": "https://github.com/tastejs/todomvc-app-css.git", + "_target": "~2.0.6", + "_originalSource": "todomvc-app-css" +} \ No newline at end of file diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.editorconfig b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.editorconfig new file mode 100644 index 000000000..86c8f59f7 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.editorconfig @@ -0,0 +1,15 @@ +root = true + +[*] +indent_style = tab +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[package.json] +indent_style = space +indent_size = 2 + +[*.md] +trim_trailing_whitespace = false diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.gitattributes b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.gitattributes new file mode 100644 index 000000000..176a458f9 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/.gitattributes @@ -0,0 +1 @@ +* text=auto diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/index.css b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/index.css new file mode 100644 index 000000000..b45de0d0f --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/index.css @@ -0,0 +1,370 @@ +html, +body { + margin: 0; + padding: 0; +} + +button { + margin: 0; + padding: 0; + border: 0; + background: none; + font-size: 100%; + vertical-align: baseline; + font-family: inherit; + font-weight: inherit; + color: inherit; + -webkit-appearance: none; + appearance: none; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +body { + font: 14px 'Helvetica Neue', Helvetica, Arial, sans-serif; + line-height: 1.4em; + background: #f5f5f5; + color: #4d4d4d; + min-width: 230px; + max-width: 550px; + margin: 0 auto; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + font-weight: 300; +} + +:focus { + outline: 0; +} + +.hidden { + display: none; +} + +.todoapp { + background: #fff; + margin: 130px 0 40px 0; + position: relative; + box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.2), + 0 25px 50px 0 rgba(0, 0, 0, 0.1); +} + +.todoapp input::-webkit-input-placeholder { + font-style: italic; + font-weight: 300; + color: #e6e6e6; +} + +.todoapp input::-moz-placeholder { + font-style: italic; + font-weight: 300; + color: #e6e6e6; +} + +.todoapp input::input-placeholder { + font-style: italic; + font-weight: 300; + color: #e6e6e6; +} + +.todoapp h1 { + position: absolute; + top: -155px; + width: 100%; + font-size: 100px; + font-weight: 100; + text-align: center; + color: rgba(175, 47, 47, 0.15); + -webkit-text-rendering: optimizeLegibility; + -moz-text-rendering: optimizeLegibility; + text-rendering: optimizeLegibility; +} + +.new-todo, +.edit { + position: relative; + margin: 0; + width: 100%; + font-size: 24px; + font-family: inherit; + font-weight: inherit; + line-height: 1.4em; + border: 0; + color: inherit; + padding: 6px; + border: 1px solid #999; + box-shadow: inset 0 -1px 5px 0 rgba(0, 0, 0, 0.2); + box-sizing: border-box; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.new-todo { + padding: 16px 16px 16px 60px; + border: none; + background: rgba(0, 0, 0, 0.003); + box-shadow: inset 0 -2px 1px rgba(0,0,0,0.03); +} + +.main { + position: relative; + z-index: 2; + border-top: 1px solid #e6e6e6; +} + +label[for='toggle-all'] { + display: none; +} + +.toggle-all { + position: absolute; + top: -55px; + left: -12px; + width: 60px; + height: 34px; + text-align: center; + border: none; /* Mobile Safari */ +} + +.toggle-all:before { + content: '❯'; + font-size: 22px; + color: #e6e6e6; + padding: 10px 27px 10px 27px; +} + +.toggle-all:checked:before { + color: #737373; +} + +.todo-list { + margin: 0; + padding: 0; + list-style: none; +} + +.todo-list li { + position: relative; + font-size: 24px; + border-bottom: 1px solid #ededed; +} + +.todo-list li:last-child { + border-bottom: none; +} + +.todo-list li.editing { + border-bottom: none; + padding: 0; +} + +.todo-list li.editing .edit { + display: block; + width: 506px; + padding: 12px 16px; + margin: 0 0 0 43px; +} + +.todo-list li.editing .view { + display: none; +} + +.todo-list li .toggle { + text-align: center; + width: 40px; + /* auto, since non-WebKit browsers doesn't support input styling */ + height: auto; + position: absolute; + top: 0; + bottom: 0; + margin: auto 0; + border: none; /* Mobile Safari */ + -webkit-appearance: none; + appearance: none; +} + +.todo-list li .toggle:after { + content: url('data:image/svg+xml;utf8,'); +} + +.todo-list li .toggle:checked:after { + content: url('data:image/svg+xml;utf8,'); +} + +.todo-list li label { + word-break: break-all; + padding: 15px 60px 15px 15px; + margin-left: 45px; + display: block; + line-height: 1.2; + transition: color 0.4s; +} + +.todo-list li.completed label { + color: #d9d9d9; + text-decoration: line-through; +} + +.todo-list li .destroy { + display: none; + position: absolute; + top: 0; + right: 10px; + bottom: 0; + width: 40px; + height: 40px; + margin: auto 0; + font-size: 30px; + color: #cc9a9a; + margin-bottom: 11px; + transition: color 0.2s ease-out; +} + +.todo-list li .destroy:hover { + color: #af5b5e; +} + +.todo-list li .destroy:after { + content: '×'; +} + +.todo-list li:hover .destroy { + display: block; +} + +.todo-list li .edit { + display: none; +} + +.todo-list li.editing:last-child { + margin-bottom: -1px; +} + +.footer { + color: #777; + padding: 10px 15px; + height: 20px; + text-align: center; + border-top: 1px solid #e6e6e6; +} + +.footer:before { + content: ''; + position: absolute; + right: 0; + bottom: 0; + left: 0; + height: 50px; + overflow: hidden; + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.2), + 0 8px 0 -3px #f6f6f6, + 0 9px 1px -3px rgba(0, 0, 0, 0.2), + 0 16px 0 -6px #f6f6f6, + 0 17px 2px -6px rgba(0, 0, 0, 0.2); +} + +.todo-count { + float: left; + text-align: left; +} + +.todo-count strong { + font-weight: 300; +} + +.filters { + margin: 0; + padding: 0; + list-style: none; + position: absolute; + right: 0; + left: 0; +} + +.filters li { + display: inline; +} + +.filters li a { + color: inherit; + margin: 3px; + padding: 3px 7px; + text-decoration: none; + border: 1px solid transparent; + border-radius: 3px; +} + +.filters li a:hover { + border-color: rgba(175, 47, 47, 0.1); +} + +.filters li a.selected { + border-color: rgba(175, 47, 47, 0.2); +} + +.clear-completed, +html .clear-completed:active { + float: right; + position: relative; + line-height: 20px; + text-decoration: none; + cursor: pointer; +} + +.clear-completed:hover { + text-decoration: underline; +} + +.info { + margin: 65px auto 0; + color: #bfbfbf; + font-size: 10px; + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); + text-align: center; +} + +.info p { + line-height: 1; +} + +.info a { + color: inherit; + text-decoration: none; + font-weight: 400; +} + +.info a:hover { + text-decoration: underline; +} + +/* + Hack to remove background from Mobile Safari. + Can't use it globally since it destroys checkboxes in Firefox +*/ +@media screen and (-webkit-min-device-pixel-ratio:0) { + .toggle-all, + .todo-list li .toggle { + background: none; + } + + .todo-list li .toggle { + height: 40px; + } + + .toggle-all { + -webkit-transform: rotate(90deg); + transform: rotate(90deg); + -webkit-appearance: none; + appearance: none; + } +} + +@media (max-width: 430px) { + .footer { + height: 50px; + } + + .filters { + bottom: 10px; + } +} diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/package.json b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/package.json new file mode 100644 index 000000000..46531c5d2 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/package.json @@ -0,0 +1,26 @@ +{ + "name": "todomvc-app-css", + "style": "index.css", + "version": "2.0.6", + "description": "CSS for TodoMVC apps", + "license": "CC-BY-4.0", + "repository": "tastejs/todomvc-app-css", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "sindresorhus.com" + }, + "files": [ + "index.css" + ], + "keywords": [ + "todomvc", + "tastejs", + "app", + "todo", + "template", + "css", + "style", + "stylesheet" + ] +} diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/readme.md b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/readme.md new file mode 100644 index 000000000..6ddbebf02 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/readme.md @@ -0,0 +1,28 @@ +# todomvc-app-css + +> CSS for TodoMVC apps + +![](screenshot.png) + + +## Install + + +``` +$ npm install --save todomvc-app-css +``` + + +## Getting started + +```html + +``` + +See the [TodoMVC app template](https://github.com/tastejs/todomvc-app-template). + + + +## License + +
Creative Commons License
This work by Sindre Sorhus is licensed under a Creative Commons Attribution 4.0 International License. diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/screenshot.png b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/screenshot.png new file mode 100644 index 000000000..5bb7dc28a Binary files /dev/null and b/implementations/om-1.0.0-alpha/bower_components/todomvc-app-css/screenshot.png differ diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.bower.json b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.bower.json new file mode 100644 index 000000000..2496cbbab --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.bower.json @@ -0,0 +1,14 @@ +{ + "name": "todomvc-common", + "homepage": "https://github.com/tastejs/todomvc-common", + "version": "1.0.2", + "_release": "1.0.2", + "_resolution": { + "type": "version", + "tag": "v1.0.2", + "commit": "9ebd1b2dc9e9b28d9015d03306b6969f3043aae6" + }, + "_source": "https://github.com/tastejs/todomvc-common.git", + "_target": "~1.0.2", + "_originalSource": "todomvc-common" +} \ No newline at end of file diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.editorconfig b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.editorconfig new file mode 100644 index 000000000..86c8f59f7 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.editorconfig @@ -0,0 +1,15 @@ +root = true + +[*] +indent_style = tab +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[package.json] +indent_style = space +indent_size = 2 + +[*.md] +trim_trailing_whitespace = false diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitattributes b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitattributes new file mode 100644 index 000000000..176a458f9 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitattributes @@ -0,0 +1 @@ +* text=auto diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitignore b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitignore new file mode 100644 index 000000000..3c3629e64 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.gitignore @@ -0,0 +1 @@ +node_modules diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.jshintrc b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.jshintrc new file mode 100644 index 000000000..804f8af72 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/.jshintrc @@ -0,0 +1,13 @@ +{ + "node": true, + "esnext": true, + "bitwise": true, + "camelcase": true, + "curly": true, + "immed": true, + "newcap": true, + "noarg": true, + "undef": true, + "unused": "vars", + "strict": true +} diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.css b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.css new file mode 100644 index 000000000..da65968a7 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.css @@ -0,0 +1,141 @@ +hr { + margin: 20px 0; + border: 0; + border-top: 1px dashed #c5c5c5; + border-bottom: 1px dashed #f7f7f7; +} + +.learn a { + font-weight: normal; + text-decoration: none; + color: #b83f45; +} + +.learn a:hover { + text-decoration: underline; + color: #787e7e; +} + +.learn h3, +.learn h4, +.learn h5 { + margin: 10px 0; + font-weight: 500; + line-height: 1.2; + color: #000; +} + +.learn h3 { + font-size: 24px; +} + +.learn h4 { + font-size: 18px; +} + +.learn h5 { + margin-bottom: 0; + font-size: 14px; +} + +.learn ul { + padding: 0; + margin: 0 0 30px 25px; +} + +.learn li { + line-height: 20px; +} + +.learn p { + font-size: 15px; + font-weight: 300; + line-height: 1.3; + margin-top: 0; + margin-bottom: 0; +} + +#issue-count { + display: none; +} + +.quote { + border: none; + margin: 20px 0 60px 0; +} + +.quote p { + font-style: italic; +} + +.quote p:before { + content: '“'; + font-size: 50px; + opacity: .15; + position: absolute; + top: -20px; + left: 3px; +} + +.quote p:after { + content: '”'; + font-size: 50px; + opacity: .15; + position: absolute; + bottom: -42px; + right: 3px; +} + +.quote footer { + position: absolute; + bottom: -40px; + right: 0; +} + +.quote footer img { + border-radius: 3px; +} + +.quote footer a { + margin-left: 5px; + vertical-align: middle; +} + +.speech-bubble { + position: relative; + padding: 10px; + background: rgba(0, 0, 0, .04); + border-radius: 5px; +} + +.speech-bubble:after { + content: ''; + position: absolute; + top: 100%; + right: 30px; + border: 13px solid transparent; + border-top-color: rgba(0, 0, 0, .04); +} + +.learn-bar > .learn { + position: absolute; + width: 272px; + top: 8px; + left: -300px; + padding: 10px; + border-radius: 5px; + background-color: rgba(255, 255, 255, .6); + transition-property: left; + transition-duration: 500ms; +} + +@media (min-width: 899px) { + .learn-bar { + width: auto; + padding-left: 300px; + } + + .learn-bar > .learn { + left: 8px; + } +} diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.js b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.js new file mode 100644 index 000000000..3c6723f39 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/base.js @@ -0,0 +1,249 @@ +/* global _ */ +(function () { + 'use strict'; + + /* jshint ignore:start */ + // Underscore's Template Module + // Courtesy of underscorejs.org + var _ = (function (_) { + _.defaults = function (object) { + if (!object) { + return object; + } + for (var argsIndex = 1, argsLength = arguments.length; argsIndex < argsLength; argsIndex++) { + var iterable = arguments[argsIndex]; + if (iterable) { + for (var key in iterable) { + if (object[key] == null) { + object[key] = iterable[key]; + } + } + } + } + return object; + } + + // By default, Underscore uses ERB-style template delimiters, change the + // following template settings to use alternative delimiters. + _.templateSettings = { + evaluate : /<%([\s\S]+?)%>/g, + interpolate : /<%=([\s\S]+?)%>/g, + escape : /<%-([\s\S]+?)%>/g + }; + + // When customizing `templateSettings`, if you don't want to define an + // interpolation, evaluation or escaping regex, we need one that is + // guaranteed not to match. + var noMatch = /(.)^/; + + // Certain characters need to be escaped so that they can be put into a + // string literal. + var escapes = { + "'": "'", + '\\': '\\', + '\r': 'r', + '\n': 'n', + '\t': 't', + '\u2028': 'u2028', + '\u2029': 'u2029' + }; + + var escaper = /\\|'|\r|\n|\t|\u2028|\u2029/g; + + // JavaScript micro-templating, similar to John Resig's implementation. + // Underscore templating handles arbitrary delimiters, preserves whitespace, + // and correctly escapes quotes within interpolated code. + _.template = function(text, data, settings) { + var render; + settings = _.defaults({}, settings, _.templateSettings); + + // Combine delimiters into one regular expression via alternation. + var matcher = new RegExp([ + (settings.escape || noMatch).source, + (settings.interpolate || noMatch).source, + (settings.evaluate || noMatch).source + ].join('|') + '|$', 'g'); + + // Compile the template source, escaping string literals appropriately. + var index = 0; + var source = "__p+='"; + text.replace(matcher, function(match, escape, interpolate, evaluate, offset) { + source += text.slice(index, offset) + .replace(escaper, function(match) { return '\\' + escapes[match]; }); + + if (escape) { + source += "'+\n((__t=(" + escape + "))==null?'':_.escape(__t))+\n'"; + } + if (interpolate) { + source += "'+\n((__t=(" + interpolate + "))==null?'':__t)+\n'"; + } + if (evaluate) { + source += "';\n" + evaluate + "\n__p+='"; + } + index = offset + match.length; + return match; + }); + source += "';\n"; + + // If a variable is not specified, place data values in local scope. + if (!settings.variable) source = 'with(obj||{}){\n' + source + '}\n'; + + source = "var __t,__p='',__j=Array.prototype.join," + + "print=function(){__p+=__j.call(arguments,'');};\n" + + source + "return __p;\n"; + + try { + render = new Function(settings.variable || 'obj', '_', source); + } catch (e) { + e.source = source; + throw e; + } + + if (data) return render(data, _); + var template = function(data) { + return render.call(this, data, _); + }; + + // Provide the compiled function source as a convenience for precompilation. + template.source = 'function(' + (settings.variable || 'obj') + '){\n' + source + '}'; + + return template; + }; + + return _; + })({}); + + if (location.hostname === 'todomvc.com') { + (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ + (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), + m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) + })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); + ga('create', 'UA-31081062-1', 'auto'); + ga('send', 'pageview'); + } + /* jshint ignore:end */ + + function redirect() { + if (location.hostname === 'tastejs.github.io') { + location.href = location.href.replace('tastejs.github.io/todomvc', 'todomvc.com'); + } + } + + function findRoot() { + var base = location.href.indexOf('examples/'); + return location.href.substr(0, base); + } + + function getFile(file, callback) { + if (!location.host) { + return console.info('Miss the info bar? Run TodoMVC from a server to avoid a cross-origin error.'); + } + + var xhr = new XMLHttpRequest(); + + xhr.open('GET', findRoot() + file, true); + xhr.send(); + + xhr.onload = function () { + if (xhr.status === 200 && callback) { + callback(xhr.responseText); + } + }; + } + + function Learn(learnJSON, config) { + if (!(this instanceof Learn)) { + return new Learn(learnJSON, config); + } + + var template, framework; + + if (typeof learnJSON !== 'object') { + try { + learnJSON = JSON.parse(learnJSON); + } catch (e) { + return; + } + } + + if (config) { + template = config.template; + framework = config.framework; + } + + if (!template && learnJSON.templates) { + template = learnJSON.templates.todomvc; + } + + if (!framework && document.querySelector('[data-framework]')) { + framework = document.querySelector('[data-framework]').dataset.framework; + } + + this.template = template; + + if (learnJSON.backend) { + this.frameworkJSON = learnJSON.backend; + this.frameworkJSON.issueLabel = framework; + this.append({ + backend: true + }); + } else if (learnJSON[framework]) { + this.frameworkJSON = learnJSON[framework]; + this.frameworkJSON.issueLabel = framework; + this.append(); + } + + this.fetchIssueCount(); + } + + Learn.prototype.append = function (opts) { + var aside = document.createElement('aside'); + aside.innerHTML = _.template(this.template, this.frameworkJSON); + aside.className = 'learn'; + + if (opts && opts.backend) { + // Remove demo link + var sourceLinks = aside.querySelector('.source-links'); + var heading = sourceLinks.firstElementChild; + var sourceLink = sourceLinks.lastElementChild; + // Correct link path + var href = sourceLink.getAttribute('href'); + sourceLink.setAttribute('href', href.substr(href.lastIndexOf('http'))); + sourceLinks.innerHTML = heading.outerHTML + sourceLink.outerHTML; + } else { + // Localize demo links + var demoLinks = aside.querySelectorAll('.demo-link'); + Array.prototype.forEach.call(demoLinks, function (demoLink) { + if (demoLink.getAttribute('href').substr(0, 4) !== 'http') { + demoLink.setAttribute('href', findRoot() + demoLink.getAttribute('href')); + } + }); + } + + document.body.className = (document.body.className + ' learn-bar').trim(); + document.body.insertAdjacentHTML('afterBegin', aside.outerHTML); + }; + + Learn.prototype.fetchIssueCount = function () { + var issueLink = document.getElementById('issue-count-link'); + if (issueLink) { + var url = issueLink.href.replace('https://github.com', 'https://api.github.com/repos'); + var xhr = new XMLHttpRequest(); + xhr.open('GET', url, true); + xhr.onload = function (e) { + var parsedResponse = JSON.parse(e.target.responseText); + if (parsedResponse instanceof Array) { + var count = parsedResponse.length; + if (count !== 0) { + issueLink.innerHTML = 'This app has ' + count + ' open issues'; + document.getElementById('issue-count').style.display = 'inline'; + } + } + }; + xhr.send(); + } + }; + + redirect(); + getFile('learn.json', Learn); +})(); diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/package.json b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/package.json new file mode 100644 index 000000000..5be7f479e --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/package.json @@ -0,0 +1,19 @@ +{ + "name": "todomvc-common", + "version": "1.0.2", + "description": "Common TodoMVC utilities used by our apps", + "license": "MIT", + "repository": "tastejs/todomvc-common", + "author": "TasteJS", + "main": "base.js", + "files": [ + "base.js", + "base.css" + ], + "keywords": [ + "todomvc", + "tastejs", + "util", + "utilities" + ] +} diff --git a/implementations/om-1.0.0-alpha/bower_components/todomvc-common/readme.md b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/readme.md new file mode 100644 index 000000000..7a5de5118 --- /dev/null +++ b/implementations/om-1.0.0-alpha/bower_components/todomvc-common/readme.md @@ -0,0 +1,15 @@ +# todomvc-common + +> Common TodoMVC utilities used by our apps + + +## Install + +``` +$ npm install --save todomvc-common +``` + + +## License + +MIT © [TasteJS](http://tastejs.com) diff --git a/implementations/om-1.0.0-alpha/index.html b/implementations/om-1.0.0-alpha/index.html new file mode 100644 index 000000000..919c700e2 --- /dev/null +++ b/implementations/om-1.0.0-alpha/index.html @@ -0,0 +1,19 @@ + + + + + + Om • TodoMVC + + + + +
+
+
+ + + + + + diff --git a/implementations/om-1.0.0-alpha/project.clj b/implementations/om-1.0.0-alpha/project.clj new file mode 100644 index 000000000..4f68c7848 --- /dev/null +++ b/implementations/om-1.0.0-alpha/project.clj @@ -0,0 +1,15 @@ +(defproject todomvc "0.1.0-SNAPSHOT" + :description "FIXME: write this!" + :url "http://example.com/FIXME" + + :jvm-opts ^:replace ["-Xms512m" "-Xmx512m" "-server"] + + :dependencies [[org.clojure/clojure "1.8.0"] + [org.clojure/clojurescript "1.9.229"] + [org.clojure/core.async "0.2.391"] + [secretary "0.4.0"] + [org.omcljs/om "1.0.0-alpha45"]] + + :source-paths ["src"] + + :clean-targets ["out"]) diff --git a/implementations/om-1.0.0-alpha/readme.md b/implementations/om-1.0.0-alpha/readme.md new file mode 100644 index 000000000..eb46bf665 --- /dev/null +++ b/implementations/om-1.0.0-alpha/readme.md @@ -0,0 +1,16 @@ +# Om TodoMVC Example + +> Om is a ClojureScript UI component library over React. + +> _[Om - /github.com/omcljs/om](http:///github.com/omcljs/om)_ + +## Running + +To build this project run: + +``` +bower install +lein trampoline run -m clojure.main script/build.clj +``` + +Then open `index.html` in your favorite browser. diff --git a/implementations/om-1.0.0-alpha/script/build.clj b/implementations/om-1.0.0-alpha/script/build.clj new file mode 100644 index 000000000..306544f35 --- /dev/null +++ b/implementations/om-1.0.0-alpha/script/build.clj @@ -0,0 +1,14 @@ +(require '[cljs.build.api :as b]) + +(b/build "src" + {:output-to "app.js" + :output-dir "out" + :optimizations :advanced + :static-fns true + :optimize-constants true + :pretty-print true + :externs ["src/js/externs.js"] + :closure-defines '{goog.DEBUG false} + :verbose true}) + +(System/exit 0) diff --git a/implementations/om-1.0.0-alpha/src/todomvc/app.cljs b/implementations/om-1.0.0-alpha/src/todomvc/app.cljs new file mode 100644 index 000000000..4d2c14e3e --- /dev/null +++ b/implementations/om-1.0.0-alpha/src/todomvc/app.cljs @@ -0,0 +1,168 @@ +(ns todomvc.app + (:require-macros [cljs.core.async.macros :refer [go]] + [secretary.macros :refer [defroute]]) + (:require [goog.events :as events] + [cljs.core.async :refer [put! todo + (= (:id todo) editing) (assoc :editing true) + (not (visible? todo showing)) (assoc :hidden true)))})))) + +(defn make-clear-button [completed comm] + (when (pos? completed) + (dom/button + #js {:className "clear-completed" + :onClick #(put! comm [:clear (now)])} + (str "Clear completed (" completed ")")))) + +(defn footer [app count completed comm] + (let [clear-button (make-clear-button completed comm) + sel (-> (zipmap [:all :active :completed] (repeat "")) + (assoc (:showing app) "selected"))] + (dom/footer #js {:className "footer" :style (hidden (empty? (:todos app)))} + (dom/span #js {:className "todo-count"} + (dom/strong nil count) + (str " " (pluralize count "item") " left")) + (dom/ul #js {:className "filters"} + (dom/li nil (dom/a #js {:href "#/" :className (sel :all)} "All")) + (dom/li nil (dom/a #js {:href "#/active" :className (sel :active)} "Active")) + (dom/li nil (dom/a #js {:href "#/completed" :className (sel :completed)} "Completed"))) + clear-button))) + +;; ============================================================================= +;; Todos + +(defn toggle-all [e app] + (let [checked (.. e -target -checked)] + (om/transact! app :todos + (fn [todos] (vec (map #(assoc % :completed checked) todos)))))) + +(defn handle-new-todo-keydown [e app owner] + (when (== (.-which e) ENTER_KEY) + (let [new-field (om/get-node owner "newField")] + (when-not (string/blank? (.. new-field -value trim)) + (let [new-todo {:id (guid) + :title (.-value new-field) + :completed false}] + (om/transact! app :todos + #(conj % new-todo) + [:create new-todo])) + (set! (.-value new-field) ""))) + false)) + +(defn destroy-todo [app {:keys [id]}] + (om/transact! app :todos + (fn [todos] (into [] (remove #(= (:id %) id) todos))) + [:delete id])) + +(defn edit-todo [app {:keys [id]}] (om/update! app :editing id)) + +(defn save-todos [app] (om/update! app :editing nil)) + +(defn cancel-action [app] (om/update! app :editing nil)) + +(defn clear-completed [app] + (om/transact! app :todos + (fn [todos] (into [] (remove :completed todos))))) + +(defn handle-event [type app val] + (case type + :destroy (destroy-todo app val) + :edit (edit-todo app val) + :save (save-todos app) + :clear (clear-completed app) + :cancel (cancel-action app) + nil)) + +(def render-start nil) + +(defn todo-app [{:keys [todos] :as app} owner] + (reify + om/IWillMount + (will-mount [_] + (let [comm (chan)] + (om/set-state! owner :comm comm) + (go (while true + (let [[type value] (! put!]] + [todomvc.utils :refer [now hidden]] + [clojure.string :as string] + [om.core :as om] + [om.dom :as dom])) + +(def ESCAPE_KEY 27) +(def ENTER_KEY 13) + +;; ============================================================================= +;; Todo Item + +;; ----------------------------------------------------------------------------- +;; Event Handlers + +(defn submit [e todo owner comm] + (when-let [edit-text (om/get-state owner :edit-text)] + (if-not (string/blank? (.trim edit-text)) + (do + (om/update! todo :title edit-text) + (put! comm [:save todo])) + (put! comm [:destroy todo]))) + false) + +(defn edit [e todo owner comm] + (let [node (om/get-node owner "editField")] + (put! comm [:edit todo]) + (doto owner + (om/set-state! :needs-focus true) + (om/set-state! :edit-text (:title todo))))) + +(defn key-down [e todo owner comm] + (condp == (.-keyCode e) + ESCAPE_KEY (do + (om/set-state! owner :edit-text (:title todo)) + (put! comm [:cancel todo])) + ENTER_KEY (submit e todo owner comm) + nil)) + +(defn change [e todo owner] + (om/set-state! owner :edit-text (.. e -target -value))) + +;; ----------------------------------------------------------------------------- +;; Todo Item + +(defn todo-item [todo owner] + (reify + om/IInitState + (init-state [_] + {:edit-text (:title todo)}) + om/IDidUpdate + (did-update [_ _ _] + (when (and (:editing todo) + (om/get-state owner :needs-focus)) + (let [node (om/get-node owner "editField") + len (.. node -value -length)] + (.focus node) + (.setSelectionRange node len len)) + (om/set-state! owner :needs-focus nil))) + om/IRenderState + (render-state [_ {:keys [comm] :as state}] + (let [class (cond-> "" + (:completed todo) (str "completed ") + (:editing todo) (str "editing"))] + (dom/li #js {:className class :style (hidden (:hidden todo))} + (dom/div #js {:className "view"} + (dom/input + #js {:className "toggle" :type "checkbox" + :checked (and (:completed todo) "checked") + :onChange (fn [_] (om/transact! todo :completed #(not %)))}) + (dom/label + #js {:onDoubleClick #(edit % todo owner comm)} + (:title todo)) + (dom/button + #js {:className "destroy" + :onClick (fn [_] (put! comm [:destroy todo]))})) + (dom/input + #js {:ref "editField" :className "edit" + :value (om/get-state owner :edit-text) + :onBlur #(submit % todo owner comm) + :onChange #(change % todo owner) + :onKeyDown #(key-down % todo owner comm)})))))) diff --git a/implementations/om-1.0.0-alpha/src/todomvc/utils.cljs b/implementations/om-1.0.0-alpha/src/todomvc/utils.cljs new file mode 100644 index 000000000..8da106ebd --- /dev/null +++ b/implementations/om-1.0.0-alpha/src/todomvc/utils.cljs @@ -0,0 +1,29 @@ +(ns todomvc.utils + (:require [cljs.reader :as reader]) + (:import [goog.ui IdGenerator])) + +(defn guid [] + (.getNextUniqueId (.getInstance IdGenerator))) + +(defn now [] + (js/Date.)) + +(defn pluralize [n word] + (if (== n 1) + word + (str word "s"))) + +(defn store + ([ns] (store ns nil)) + ([ns edn] + (if-not (nil? edn) + (.setItem js/localStorage ns (str edn)) + (let [s (.getItem js/localStorage ns)] + (if-not (nil? s) + (reader/read-string s) + []))))) + +(defn hidden [is-hidden] + (if is-hidden + #js {:display "none"} + #js {})) diff --git a/index.html b/index.html index a5a6fec8e..48d620871 100644 --- a/index.html +++ b/index.html @@ -44,6 +44,7 @@

Methodology Notes

impl('React', '15.3.1', false, 'react-15.3.1/index.html'), impl('Angular', '1.5.8', false, 'angular-1.5.8/index.html'), impl('Angular', '2', false, 'angular-2/index.html'), + impl('Om', '1.0.0-alpha', false, 'om-1.0.0-alpha/index.html'), impl('Elm', '0.16', false, 'elm-0.16/index.html'), impl('Elm', '0.17', false, 'elm-0.17/index.html'), impl('React', '15.3.1', true, 'react-15.3.1-optimized/index.html'),