<commit_before>(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
/*
Mithril v0.2.1
http://mithril.js.org
(c) 2014-2015 <NAME>
License: MIT
*/
!function(a,b){"use strict";var c=b("undefined"!=typeof window?window:{});"object"==typeof module&&null!=module&&module.exports?module.exports=c:"function"==typeof define&&define.amd?define(function(){return c}):a.m=c}(this,function(a,b){"use strict";function c(a){return"function"==typeof a}function d(a){return"[object Object]"===bc.call(a)}function e(a){return"[object String]"===bc.call(a)}function f(){}function g(a,b){for(var c=0;c<a.length;c++)b(a[c],c)}function h(a,b){for(var c in a)cc.call(a,c)&&b(a[c],c)}function i(a){Zb=a.document,$b=a.location,ac=a.cancelAnimationFrame||a.clearTimeout,_b=a.requestAnimationFrame||a.setTimeout}function j(a){function b(){return arguments.length&&(a=arguments[0]),a}return b.toJSON=function(){return a},b}function k(a){return null!=a&&(d(a)||c(a))&&c(a.then)}function l(a,b){return a.then?a.then(b):b()}function m(a){var b=r.prop();return a.then(b),b.then=function(c,d){return a.then(function(){return c(b())},d)},b.catch=function(c){return a.then(function(){return b()},c)},b.finally=function(b){return a.then(function(a){return l(b(),function(){return a})},function(a){return l(b(),function(){throw a})})},b}function n(a){return null!=a&&d(a)&&!("tag"in a||"view"in a||"subtree"in a)}function o(a,b){for(var c,d=[],e=/(?:(^|#|\.)([^#\.\[\]]+))|(\[.+?\])/g;null!=(c=e.exec(a));)if(""===c[1]&&null!=c[2])b.tag=c[2];else if("#"===c[1])b.attrs.id=c[2];else if("."===c[1])d.push(c[2]);else if("["===c[3][0]){var f=/\[(.+?)(?:=("|'|)(.*?)\2)?\]/.exec(c[3]);b.attrs[f[1]]=f[3]||(f[2]?"":!0)}return d}function p(a,b,c,d){var e=!1;if(cc.call(b,c)){var f=b[c];null!=f&&""!==f&&(e=!0,d.push(f))}h(b,function(b,d){a[d]=d===c&&e?"":b}),d.length&&(a[c]=d.join(" "))}function q(a){function b(){return g.apply(this,d)||this}function c(b){for(var c=[b].concat(d),e=1;e<arguments.length;e++)c.push(arguments[e]);return h.apply(a,c)}for(var d=[],e=1;e<arguments.length;e++)d.push(arguments[e]);var g=a.controller||f;g!==f&&(b.prototype=g.prototype);var h=a.view||f;c.$original=h;var i={controller:b,view:c};return d[0]&&null!=d[0].key&&(i.attrs={key:d[0].key}),i}function r(a,b){if(d(a))return q.apply(null,arguments);if(!e(a))throw new TypeError("selector in m(selector, attrs, children) should be a string");if(!a)throw new TypeError("selector cannot be an empty string");for(var c=n(b),f=[],g=c?2:1;g<arguments.length;g++)f.push(arguments[g]);var h;h=1===f.length&&dc(f[0])?f[0]:f;var i={tag:"div",attrs:{},children:h};return p(i.attrs,c?b:{},c&&"class"in b?"class":"className",o(a,i)),i}function s(a,b){for(var c=0;c<a.length;c++){var d=a[c];if(d=d&&d.attrs,d&&null!=d.key&&b(d,c))break}}function t(a){try{if(null!=a&&null!=a.toString())return a}catch(b){}return""}function u(a){for(var b=0;b<a.length;b++)dc(a[b])&&(a=a.concat.apply([],a),b--);return a}function v(a,b,c){a.insertBefore(b,a.childNodes[c]||null)}function w(a,b,c,d,e,f,g,h,i,j,k){return{parent:a,pTag:b,pCache:c,pIndex:d,data:e,cached:f,reattach:g,index:h,editable:i,ns:j,cfgs:k}}function x(a){return a.data=t(a.data),"retain"===a.data.subtree?a.cached:(y(a),dc(a.data)?B(a):null!=a.data&&d(a.data)?H(a):c(a.data)?a.cached:_(a))}function y(a){if(null!=a.cached){if(bc.call(a.cached)===bc.call(a.data))return;if(a.pCache&&a.pCache.nodes){var b=a.index-a.pIndex,c=b+(dc(a.data)?a.data:a.cached.nodes).length;nb(a.pCache.nodes.slice(b,c),a.pCache.slice(b,c))}else a.cached.nodes&&nb(a.cached.nodes,a.cached)}a.cached=new a.data.constructor,a.cached.tag&&(a.cached={}),a.cached.nodes=[]}function z(a){var b=0;s(a,function(){return g(a,function(a){a=a&&a.attrs,a&&null==a.key&&(a.key="__mithril__"+b++)}),!0})}function A(a,b,c,d){return x(w(a.parent,a.pTag,a.cached,a.index,b,c,a.reattach,a.index+d||d,a.editable,a.ns,a.cfgs))}function B(a){a.data=u(a.data);var c=[],d=a.cached.length===a.data.length,e=0,f={},g=!1;s(a.cached,function(a,b){g=!0,f[a.key]={action:ec,index:b}}),z(a.data),g&&C(a,f);for(var h=0,i=0,j=a.data.length;j>i;i++){var k=A(a,a.data[i],a.cached[h],e);k!==b&&(d=d&&k.nodes.intact,e+=gb(k),a.cached[h++]=k)}return d||E(a,c),a.cached}function C(a,b){var c=a.data.length!==a.cached.length;c||s(a.data,function(b,d){var e=a.cached[d];return c=e&&e.attrs&&e.attrs.key!==b.key}),c&&D(a,b)}function D(a,b){var c=a.cached.nodes;s(a.data,function(a,d){a=a.key,b[a]=b[a]?{action:gc,index:d,from:b[a].index,element:c[b[a].index]||Zb.createElement("div")}:{action:fc,index:d}});var d=[];h(b,function(a){d.push(a)});var e=d.sort(hb),f=new Array(a.cached.length);f.nodes=a.cached.nodes.slice(),g(e,function(b){var c=b.index;switch(b.action){case ec:nb(a.cached[c].nodes,a.cached[c]),f.splice(c,1);break;case fc:var d=Zb.createElement("div");d.key=a.data[c].attrs.key,v(a.parent,d,c),f.splice(c,0,{attrs:{key:a.data[c].attrs.key},nodes:[d]}),f.nodes[c]=d;break;case gc:var e=b.element;a.parent.childNodes[c]!==e&&a.parent.insertBefore(e,a.parent.childNodes[c]||null),f[c]=a.cached[b.from],f.nodes[c]=e}}),a.cached=f}function E(a,b){for(var c=0,d=a.data.length;d>c;c++){var e=a.cached[c];null!=e&&b.push.apply(b,e.nodes)}g(a.cached.nodes,function(c,d){null!=c.parentNode&&b.indexOf(c)<0&&nb([c],[a.cached[d]])}),a.data.length<a.cached.length&&(a.cached.length=a.data.length),a.cached.nodes=b}function F(a){var b=a.data.attrs=a.data.attrs||{};a.cached.attrs=a.cached.attrs||{};var c=Object.keys(a.data.attrs);return N(a,c),c.length>+("key"in b)}function G(a){var b=a.data;return b.attrs.xmlns?b.attrs.xmlns:"svg"===b.tag?"http://www.w3.org/2000/svg":"math"===b.tag?"http://www.w3.org/1998/Math/MathML":a.ns}function H(a){var b=[],c=[];if(I(a,b,c),!a.data.tag&&c.length)throw new Error("Component template must return a virtual element, not an array, string, etc.");var d=F(a);return e(a.data.tag)?R({builder:a,hasKeys:d,views:b,controllers:c,ns:G(a)}):void 0}function I(a,b,c){for(var d=a.cached&&a.cached.controllers;null!=a.data.view;)J(a,d,c,b)}function J(a,b,c,d){var e=a.data.view.$original||a.data.view,f=M(a.cached.views,e,b,a.data.controller),g=+(a.data&&a.data.attrs&&a.data.attrs.key);return a.data=0===ic||hc||b&&b.indexOf(f)>-1?a.data.view(f):{tag:"placeholder"},"retain"===a.data.subtree?a.cached:(g===g&&((a.data.attrs=a.data.attrs||{}).key=g),void L(d,c,e,f))}function K(a,b){a.ctrls.splice(a.ctrls.indexOf(a.ctrl),1),a.views.splice(a.views.indexOf(a.view),1),a.ctrl&&c(a.ctrl.onunload)&&a.ctrl.onunload(b)}function L(a,b,c,d){a.push(c),jc[b.push(d)-1]={views:a,view:c,ctrl:d,ctrls:b}}function M(a,b,d,e){var f="diff"===lc()&&a?a.indexOf(b):-1;return f>-1?d[f]:c(e)?new e:{}}function N(a,b){P(a,b)&&(a.cached.nodes.length&&nb(a.cached.nodes),a.cached.cfgCtx&&c(a.cached.cfgCtx.onunload)&&a.cached.cfgCtx.onunload(),a.cached.controllers&&g(a.cached.controllers,function(a){a.unload&&a.onunload({preventDefault:f})}))}function O(a,c){var d=a.length;if(d!==c.length)return!1;for(var e=0,f=Object.create(null);d>e;)f[c[e]]=e++;for(;0!==e;)if(f[a[--e]]===b)return!1;return!0}function P(a,b){var c=a.data,d=a.cached;return c.tag!==d.tag?!0:O(b,Object.keys(d.attrs))?c.attrs.id!==d.attrs.id?!0:c.attrs.key!==d.attrs.key?!0:"all"===lc()?!d.cfgCtx||d.cfgCtx.retain!==!0:"diff"===lc()?d.cfgCtx&&d.cfgCtx.retain===!1:!1:!0}function Q(a){var b=S(a);return a.builder.cached=W(a,b,T(a,b),V(a,b)),b}function R(a){var b=a.builder,c=0===b.cached.nodes.length,d=c?Q(a):Z(a);return(c||b.reattach&&null!=d)&&v(b.parent,d,b.index),$(b,d,c),b.cached}function S(a){var c=a.builder.data;return a.ns===b?c.attrs.is?Zb.createElement(c.tag,c.attrs.is):Zb.createElement(c.tag):c.attrs.is?Zb.createElementNS(a.ns,c.tag,c.attrs.is):Zb.createElementNS(a.ns,c.tag)}function T(a,b){var c=a.builder.data;return a.hasKeys?lb(b,c.tag,c.attrs,{},a.ns):c.attrs}function U(a,c,d){var e=a.builder;return x(w(c,e.data.tag,b,b,e.data.children,e.cached.children,d,0,e.data.attrs.contenteditable?c:e.editable,a.ns,e.cfgs))}function V(a,b){var c=a.builder.data.children;return null!=c&&c.length?U(a,b,!0):c}function W(a,b,c,d){var e=a.builder.data,f={tag:e.tag,attrs:c,children:d,nodes:[b]};return Y(a,f),f.children&&!f.children.nodes&&(f.children.nodes=[]),"select"===e.tag&&"value"in e.attrs&&lb(b,e.tag,{value:e.attrs.value},{},a.ns),f}function X(a){if(a.onunload&&a.onunload.$old&&(a.onunload=a.onunload.$old),ic&&a.onunload){var b=a.onunload;a.onunload=f,a.onunload.$old=b}}function Y(a,b){a.controllers.length&&(b.views=a.views,b.controllers=a.controllers,g(a.controllers,X))}function Z(a){var b=a.builder.cached,c=b.nodes[0];return a.hasKeys&&lb(c,a.builder.data.tag,a.builder.data.attrs,b.attrs,a.ns),b.children=U(a,c,!1),b.nodes.intact=!0,a.controllers.length&&(b.views=a.views,b.controllers=a.controllers),c}function $(a,b,d){var e=a.data,f=a.cached,g=e.attrs.config;if(c(g)){var h=f.cfgCtx=f.cfgCtx||{};a.cfgs.push(function(){return g.call(e,b,!d,h,f)})}}function _(a){return 0===a.cached.nodes.length?bb(a):a.cached.valueOf()!==a.data.valueOf()||a.reattach?cb(a):(a.cached.nodes.intact=!0,a.cached)}function ab(a){return!/^(AREA|BASE|BR|COL|COMMAND|EMBED|HR|IMG|INPUT|KEYGEN|LINK|META|PARAM|SOURCE|TRACK|WBR)$/.test(a)}function bb(a){var b;a.data.$trusted?b=pb(a.parent,a.index,a.data):(b=[Zb.createTextNode(a.data)],ab(a.parent.nodeName)&&v(a.parent,b[0],a.index));var c;return c="string"==typeof a.data||"number"==typeof a.data||"boolean"==typeof a.data?new a.data.constructor(a.data):a.data,c.nodes=b,c}function cb(a){var b=a.cached.nodes;return a.editable&&a.editable===Zb.activeElement||(a.data.$trusted?(nb(b,a.cached),b=pb(a.parent,a.index,a.data)):"textarea"===a.pTag?a.parent.value=a.data:a.editable?a.editable.innerHTML=a.data:((1===b[0].nodeType||b.length>1||b[0].nodeValue.trim&&!b[0].nodeValue.trim())&&(nb(a.cached.nodes,a.cached),b=[Zb.createTextNode(a.data)]),db(a,b[0]))),a.cached=new a.data.constructor(a.data),a.cached.nodes=b,a.cached}function db(a,b){try{v(a.parent,b,a.index),b.nodeValue=a.data}catch(c){}}function eb(){ic++}function fb(){ic>1?ic--:(ic=0,r.redraw())}function gb(a){if(!a.$trusted)return dc(a)?a.length:1;var b=a.match(/<[^\/]|\>\s*[^<]/g);return null!=b?b.length:void 0}function hb(a,b){return a.action-b.action||a.index-b.index}function ib(a){return!/^(list|style|form|type|width|height)$/.test(a)}function jb(a,b,e,f,g,i){if("config"!==a&&"key"!==a)if(c(b)&&"on"===a.slice(0,2))f[a]=qb(b,f);else if("style"===a&&null!=b&&d(b)){h(b,function(a,b){(null==e||e[b]!==a)&&(f.style[b]=a)});for(var j in e)cc.call(e,j)&&(cc.call(b,j)||(f.style[j]=""))}else null!=g?"href"===a?f.setAttributeNS("http://www.w3.org/1999/xlink","href",b):f.setAttribute("className"===a?"class":a,b):a in f&&ib(a)?("input"!==i||f[a]!==b)&&(f[a]=b):f.setAttribute(a,b)}function kb(a,b,c,d,e,f){try{jb(a,b,c,d,e,f)}catch(g){if(/\bInvalid argument\b/.test(g.message))throw g}}function lb(a,b,c,d,e){return h(c,function(c,f){var g=d[f];f in d&&g===c?"value"===f&&"input"===b&&a.value!=c&&(a.value=c):(d[f]=c,kb(f,c,g,a,e,b))}),d}function mb(a){try{a.parentNode.removeChild(a)}catch(b){}}function nb(a,b){if(a.length){b=[].concat(b);for(var c=a.length-1;c>=0;c--){var d=a[c];null!=d&&d.parentNode&&(mb(d),b[c]&&ob(b[c]))}a.length&&(a.length=0)}}function ob(a){a.cfgCtx&&c(a.cfgCtx.onunload)&&(a.cfgCtx.onunload(),a.cfgCtx.onunload=null),a.controllers&&g(a.controllers,function(a){c(a.onunload)&&a.onunload({preventDefault:f})}),a.children&&(dc(a.children)?g(a.children,ob):a.children.tag&&ob(a.children))}function pb(a,b,c){var d=a.childNodes[b];if(d)if(1!==d.nodeType){var e=Zb.createElement("span");a.insertBefore(e,d||null),e.insertAdjacentHTML("beforebegin",c),a.removeChild(e)}else d.insertAdjacentHTML("beforebegin",c);else mc(a,c);for(var f=[];a.childNodes[b]!==d;)f.push(a.childNodes[b++]);return f}function qb(a,b){return function(c){lc("diff"),eb();try{return a.call(b,c||event)}finally{zb()}}}function rb(a){var b=oc.indexOf(a);return 0>b?oc.push(a)-1:b}function sb(a,b,c,d){var e=null===a;if(!d){lc("all"),eb(),rc[c]=b,a=qc=a||{controller:f};var g=new(a.controller||f);return a===qc&&(tc[c]=g,sc[c]=a),zb(),e&&ub(b,c),tc[c]}e&&ub(b,c)}function tb(a,b){if(!a)throw new Error("Please ensure the DOM element exists before rendering a template into it.");var d=rc.indexOf(a);0>d&&(d=rc.length);var e=!1,f={preventDefault:function(){e=!0,uc=vc=null}};return g(jc,function(a){null!=a.ctrl&&(K(a,f),a.ctrl.onunload=null)}),e?g(jc,function(a){a.ctrl.onunload=function(b){K(a,b)}}):jc=[],tc[d]&&c(tc[d].onunload)&&tc[d].onunload(f),sb(b,a,d,e)}function ub(a,b){rc.splice(b,1),tc.splice(b,1),sc.splice(b,1),Ob(a),oc.splice(rb(a),1)}function vb(){0!==xc&&ac(xc),xc=_b(yb,wc)}function wb(){xc=0}function xb(a){xc&&!a?zc():(yb(),xc=_b(wb,wc))}function yb(){uc&&(uc(),uc=null);for(var a=0;a<rc.length;a++){var b=rc[a],c=sc[a],d=tc[a];null!=d&&r.render(b,c.view?c.view(d,[d]):"")}vc&&(vc(),vc=null),xc=null,yc=new Date,lc("diff")}function zb(){"none"===lc()?(ic--,lc("diff")):fb()}function Ab(){var a=$b[Hb.mode];"pathname"===Hb.mode&&(a+=$b.search),Bc!==Ib(a)&&Dc(a)}function Bb(b){a[b]=Ab,uc=Lb,a[b]()}function Cb(){return("pathname"===Hb.mode?"":$b.pathname)+Cc[Hb.mode]}function Db(){a.history.pushState(null,Zb.title,Cc[Hb.mode]+Bc)}function Eb(){a.history.replaceState(null,Zb.title,Cc[Hb.mode]+Bc)}function Fb(b){a.history.pushState?(uc=Lb,vc=b?Eb:Db,Dc(Cc[Hb.mode]+Bc)):($b[Hb.mode]=Bc,Dc(Cc[Hb.mode]+Bc))}function Gb(a,b,c){arguments.length<3&&"object"!=typeof b&&(c=b,b=null);var d=Bc;Bc=a;var e,f,g=b||{},i=Bc.indexOf("?");if(i>=0){var j=Nb(Bc.slice(i+1));h(g,function(a,b){j[b]=g[b]}),e=Mb(j),f=Bc.slice(0,i)}else e=Mb(b),f=Bc;if(e){var k=-1===f.indexOf("?")?"?":"&";Bc=f+k+e}return Fb(c||d===a)}function Hb(a,b,c,d){if(0===arguments.length)return Bc;if(3===arguments.length&&e(b))Dc=function(d){var e=Bc=Ib(d);if(!Jb(a,c,e)){if(Ec)throw new Error("Ensure the default route matches one of the routes defined in m.route");Ec=!0,Hb(b,!0),Ec=!1}},Bb("hash"===Hb.mode?"onhashchange":"onpopstate");else if(a.addEventListener||a.attachEvent)a.href=Cb()+d.attrs.href,a.addEventListener?(a.removeEventListener("click",Kb),a.addEventListener("click",Kb)):(a.detachEvent("onclick",Kb),a.attachEvent("onclick",Kb));else if(e(a))return Gb.apply(null,arguments)}function Ib(a){return a.slice(Cc[Hb.mode].length)}function Jb(a,b,c){var d=c.indexOf("?");d>=0?(Ac=Nb(c.substr(d+1,c.length)),c=c.substr(0,d)):Ac={};var e=Object.keys(b),f=e.indexOf(c);if(f>=0)return tb(a,b[e[f]]),!0;for(var h in b)if(cc.call(b,h)){if(h===c)return tb(a,b[h]),!0;var i=new RegExp("^"+h.replace(/:[^\/]+?\.{3}/g,"(.*?)").replace(/:[^\/]+/g,"([^\\/]+)")+"/?$");if(i.test(c))return c.replace(i,function(){for(var a=[],b=1,c=arguments.length-2;c>b;)a.push(arguments[b++]);var d=h.match(/:[^\/]+/g)||[];g(d,function(b,c){b=b.replace(/:|\./g,""),Ac[b]=decodeURIComponent(a[c])})}),tb(a,b[h]),!0}}function Kb(a){if(a=a||event,!a.ctrlKey&&!a.metaKey&&2!==a.which){a.preventDefault?a.preventDefault():a.returnValue=!1;var b,c=a.currentTarget||a.srcElement;for(b="pathname"===Hb.mode&&c.search?Nb(c.search.slice(1)):{};c&&"A"!==c.nodeName.toUpperCase();)c=c.parentNode;ic=0,Hb(c[Hb.mode].slice(Cc[Hb.mode].length),b)}}function Lb(){"hash"!==Hb.mode&&$b.hash?$b.hash=$b.hash:a.scrollTo(0,0)}function Mb(a,c){var e={},f=[];return h(a,function(a,h){var i=c?c+"["+h+"]":h;if(null===a)f.push(encodeURIComponent(i));else if(d(a))f.push(Mb(a,i));else if(dc(a)){var j=[];e[i]=e[i]||{},g(a,function(a){e[i][a]||(e[i][a]=!0,j.push(encodeURIComponent(i)+"="+encodeURIComponent(a)))}),f.push(j.join("&"))}else a!==b&&f.push(encodeURIComponent(i)+"="+encodeURIComponent(a))}),f.join("&")}function Nb(a){if(!a)return{};"?"===a[0]&&(a=a.slice(1));var b=a.split("&"),c={};return g(b,function(a){var b=a.split("="),d=decodeURIComponent(b[0]),e=2===b.length?decodeURIComponent(b[1]):null;null!=c[d]?(dc(c[d])||(c[d]=[c[d]]),c[d].push(e)):c[d]=e}),c}function Ob(a){var c=rb(a);nb(a.childNodes,pc[c]),pc[c]=b}function Pb(a,b,c){return k(a)?a.then(function(a){Pb(a,b,c)},function(a){Pb(a,c,c)}):b(a)}function Qb(a,d){function e(a){r=a}function f(a){a.resolve(r)}function h(a){a.reject(r)}function i(a){return u!==h&&a(r),a}function j(a){t.push(a)}function l(a,b){var c=Rb().resolve(a()).promise;return b!==h&&c(r),c.then(b)}function m(a){u=a,g(t,a),n=q=null}function n(a,b){Pb(a,function(a){r=a,m(b===Hc?f:h)},function(a){r=a,m(h)})}function o(a,b){var c=0;try{return a.then(function(a){c++||q(Fc,a,b)},function(a){c++||q(Gc,a,b)})}catch(d){return Rb.onerror(d),q(Gc,d,b)}}function p(b,e,f){try{e===Fc&&c(a)?b=a(b):e===Gc&&c(d)&&(b=d(b),e=Fc)}catch(g){return Rb.onerror(g),n(g,Ic)}return b===f?n(TypeError(),Ic):n(b,e===Fc?Hc:Ic)}function q(a,b,c){var d;try{d=k(b)}catch(e){return Rb.onerror(e),q(Gc,e,c)}return a===Gc&&Rb.onerror(b),d?o(b,c):p(b,a,c)}var r,s=this,t=[],u=j;s.resolve=function(a){return u===j&&q(Fc,a,s),s},s.reject=function(a){return u===j&&q(Gc,a,s),s},s.promise=function(a){return arguments.length&&Pb(a,e,e),u!==h?r:b},s.promise.then=function(a,b){var c=new Qb(a,b);return u(c),i(c.promise)},s.promise.catch=function(a){return s.promise.then(null,a)},s.promise.finally=function(a){return s.promise.then(function(){return l(a,function(){return r})},function(){return l(a,function(){throw r})})}}function Rb(){return new Qb}function Sb(a){return a instanceof EvalError||a instanceof RangeError||a instanceof ReferenceError||a instanceof SyntaxError||a instanceof TypeError||a instanceof URIError}function Tb(){return"mithril_callback_"+(new Date).getTime()+"_"+Math.round(1e16*Math.random()).toString(36)}function Ub(c){var d=Tb(),e=Zb.createElement("script");a[d]=function(f){e.parentNode.removeChild(e),c.onload({success:!0,target:{responseText:f}}),a[d]=b},e.onerror=function(){return e.parentNode.removeChild(e),c.onerror({success:!1,target:{status:500,responseText:'{"error": "Error making jsonp request"}'}}),a[d]=b,!1},e.onload=function(){return!1},e.src=c.url+(c.url.indexOf("?")>0?"&":"?")+(c.callbackKey||"callback")+"="+d+"&"+Mb(c.data||{}),Zb.body.appendChild(e)}function Vb(b){var d=new a.XMLHttpRequest;if(d.open(b.method,b.url,!0,b.user,b.password),d.onreadystatechange=function(){4===this.readyState&&(this.status>=200&&this.status<300?b.onload({success:!0,target:this}):b.onerror({success:!1,target:this}))},b.serialize===JSON.stringify&&b.data&&"GET"!==b.method&&d.setRequestHeader("Content-Type","application/json; charset=utf-8"),b.deserialize===JSON.parse&&d.setRequestHeader("Accept","application/json, text/*"),c(b.config)){var f=b.config(d,b);null!=f&&(d=f)}var g;if(g="GET"!==b.method&&b.data?b.data:"",g&&!e(g)&&!(g instanceof a.FormData))throw new Error("Request data should be either be a string or FormData. Check the `serialize` option in `m.request`");return d.send(g),d}function Wb(a){return a.dataType&&"JSONP"===a.dataType.toUpperCase()?Ub(a):Vb(a)}function Xb(a,b,c){if("GET"===a.method&&"jsonp"!==a.dataType){var d=a.url.indexOf("?")<0?"?":"&",e=Mb(b);a.url+=e?d+e:""}else a.data=c(b);return a}function Yb(a,b){var c=a.match(/:[a-z]\w+/gi);return c&&b&&g(c,function(c){var d=c.slice(1);a=a.replace(c,b[d]),delete b[d]}),a}r.version=function(){return"v0.2.1"};var Zb,$b,_b,ac,bc={}.toString,cc={}.hasOwnProperty,dc=Array.isArray||function(a){return"[object Array]"===bc.call(a)};i(a),r.deps=function(b){return i(a=b||a),a},r.prop=function(a){return k(a)?m(a):j(a)},r.component=q;var ec=1,fc=2,gc=3,hc=!1,ic=0,jc=[],kc=!1;r.redraw=function(a){if(!kc){kc=!0,a&&(hc=!0);try{xb(a)}finally{kc=hc=!1}}};var lc=r.redraw.strategy=r.prop();r.startComputation=eb,r.endComputation=fb;var mc=function(){try{return Zb.createRange().createContextualFragment("x"),function(a,b){a.appendChild(Zb.createRange().createContextualFragment(b))}}catch(a){return function(a,b){a.insertAdjacentHTML("beforeend",b)}}}(),nc={appendChild:function(a){Zb.documentElement&&Zb.documentElement!==a?Zb.replaceChild(a,Zb.documentElement):Zb.appendChild(a),this.childNodes=Zb.childNodes},insertBefore:function(a){this.appendChild(a)},childNodes:[]},oc=[],pc={};r.render=function(a,c,d){if(!a)throw new Error("Ensure the DOM element being passed to m.route/m.mount/m.render exists.");var e,f=[],h=rb(a),i=a===Zb;e=i||a===Zb.documentElement?nc:a,i&&"html"!==c.tag&&(c={tag:"html",attrs:{},children:c}),pc[h]===b&&nb(e.childNodes),d===!0&&Ob(a),pc[h]=x(w(e,null,b,b,c,pc[h],!1,0,null,b,f)),g(f,function(a){a()})},r.trust=function(a){return a=new String(a),a.$trusted=!0,a};var qc,rc=[],sc=[],tc=[],uc=null,vc=null,wc=16;r.mount=r.module=tb;var xc=0,yc=0,zc=_b===a.requestAnimationFrame?vb:function(){+new Date-yc>wc&&vb()};r.withAttr=function(a,b,c){return function(d){d=d||event;var e,f=d.currentTarget||this;e=a in f?f[a]:f.getAttribute(a),b.call(c||this,e)}};var Ac,Bc,Cc={pathname:"",hash:"#",search:"?"},Dc=f,Ec=!1;r.route=Hb,Hb.param=function(a){if(!Ac)throw new Error("You must call m.route(element, defaultRoute, routes) before calling mroute.param()");return a?Ac[a]:Ac},Hb.mode="search",Hb.buildQueryString=Mb,Hb.parseQueryString=Nb;var Fc=1,Gc=2,Hc=3,Ic=4;return r.deferred=Rb,Rb.prototype=Qb.prototype,Rb.prototype.constructor=Rb,Rb.onerror=function(a){if(Sb(a))throw ic=0,a},r.sync=function(a){function b(a,b){return e[a]=b,0===--d&&(c.promise(e),c[f](e)),b}var c=new Qb,d=a.length,e=new Array(d),f="resolve";return a.length>0?g(a,function(a,c){a.then(function(a){return b(c,a)},function(a){return f="reject",b(c,a)})}):c.resolve([]),c.promise},r.request=function(a){a.background!==!0&&eb();var b=Rb(),c=function(a){return a},d=c,e=function(a){return a.responseText};return a.dataType&&"JSONP"===a.dataType.toUpperCase()||(c=a.serialize||JSON.stringify,d=a.deserialize||JSON.parse,e=a.extract||function(a){return a.responseText.length||d!==JSON.parse?a.responseText:null}),a.serialize=c,a.deserialize=d,a.method=(a.method||"GET").toUpperCase(),a.url=Yb(a.url,a.data),a=Xb(a,a.data,c),a.onload=a.onerror=function(c){c=c||event;var f,h=c.success;f=h?a.unwrapSuccess:a.unwrapError;try{var i=d(e(c.target,a));f&&(i=f(i,c.target)),h?(dc(i)&&a.type?g(i,function(b,c){i[c]=new a.type(b)}):a.type&&(i=new a.type(i)),b.resolve(i)):b.reject(i)}catch(j){b.reject(j)}finally{a.background!==!0&&fb()}},Wb(a),b.promise(a.initialValue),b.promise},r});

},{}],2:[function(require,module,exports){
"use strict";
var m, todo;

m = require("./..\\bower_components\\mithril\\mithril.min.js");

todo = require("./modules/todo/index.coffee");

m.route(document.body, "/", {
  "/": todo
});


},{"./..\\bower_components\\mithril\\mithril.min.js":1,"./modules/todo/index.coffee":8}],3:[function(require,module,exports){
"use strict";
var TodoController;

module.exports = TodoController = function(vm) {
  return function() {};
};


},{}],4:[function(require,module,exports){
"use strict";
var TodoListModel;

module.exports = TodoListModel = Array;


},{}],5:[function(require,module,exports){
"use strict";
var TodoModel, m;

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

TodoModel = (function() {
  function TodoModel(data) {
    this.data = data;
    this.description = m.prop(this.data.description);
    this.done = m.prop(false);
  }

  return TodoModel;

})();

module.exports = TodoModel;


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":1}],6:[function(require,module,exports){
"use strict";
var TodoView, m;

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

module.exports = TodoView = function(vm) {
  return function() {
    return m("html", m("head", m("meta[name=viewport][content='width=device-width'][maximum-scale=1.0]"), m("link[rel=stylesheet][href='dist/picnic.min.css']"), m("link[rel=stylesheet][href='dist/plugins.min.css']"), m("link[rel=stylesheet][href='dist/index.css']")), m("body", m("article[class=card row two-third]", m("header", m("h2", "Todo")), m("input", {
      onchange: m.withAttr("value", vm.description),
      value: vm.description()
    }), m("button", {
      onclick: vm.add
    }, "Add"), m("div", vm.list.map(function(task, index) {
      var checkboxStyle;
      checkboxStyle = {
        style: {
          textDecoration: task.done() ? "line-through" : "none"
        }
      };
      return m("div[class=row one]", m("label", m("input[type=checkbox]", {
        onclick: m.withAttr("checked", task.done),
        checked: task.done()
      }), m("span[class=checkable]", checkboxStyle, task.description())));
    })))));
  };
};


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":1}],7:[function(require,module,exports){
"use strict";
var TodoListModel, TodoModel, TodoViewModel, m,
  bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

TodoModel = require("./TodoModel.coffee");

TodoListModel = require("./TodoListModel.coffee");

TodoViewModel = (function() {
  function TodoViewModel() {
    this.add = bind(this.add, this);
    this.list = new TodoListModel();
    this.description = m.prop("");
  }

  TodoViewModel.prototype.add = function() {
    if (this.description()) {
      this.list.push(new TodoModel({
        description: this.description()
      }));
      return this.description("");
    }
  };

  return TodoViewModel;

})();

module.exports = TodoViewModel;


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":1,"./TodoListModel.coffee":4,"./TodoModel.coffee":5}],8:[function(require,module,exports){
var TodoController, TodoView, TodoViewModel, m, vm;

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

TodoViewModel = require("./TodoViewModel.coffee");

TodoController = require("./TodoController.coffee");

TodoView = require("./TodoView.coffee");

vm = new TodoViewModel();

m.mount(document, {
  controller: TodoController(vm),
  view: TodoView(vm)
});


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":1,"./TodoController.coffee":3,"./TodoView.coffee":6,"./TodoViewModel.coffee":7}]},{},[2]);<commit_msg>Publishing<commit_after>(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
/* ========================================================================
 * infect.js v0.4.5
 * Dependency injection for any web project
 *
 * Copyright (c) 2013 <NAME> (amwmedia.com)
 * https://github.com/amwmedia/infect.js
 *
 * Author: <NAME>
 * Website: amwmedia.com
 *
 * Released under the MIT license
 * https://github.com/amwmedia/infect.js/blob/master/LICENSE
 * ------------------------------------------------------------------------ */

(function (root, factory) {
	'use strict';

	if (typeof define === 'function' && define.amd) {
		// AMD. Register as an anonymous module.
		define(factory);
	} else if (typeof exports === 'object') {
		// Node.js
		module.exports = factory();
	} else {
		// Browser globals
		root.infect = factory();
	}
}(this, function () {
	'use strict';

	var strains = {},
		op = '$',
		preErr = ' == infect.js => ';

	/**
	 * Type checking for any type
	 *
	 * @method type
	 * @param {Anything} obj: object to be type checked
	 * @return {String} string equiv of the type passed in
	 *			example: string, number, date, object, etc
	 */
	function type(obj) {
		return (/ (.*)]/).exec(Object.prototype.toString.call(obj))[1];
	}

	/**
	 * failure function to handle when incorrect params are passed
	 *
	 * @method fail
	 * @param {String} funcName: function name that was incorrectly called
	 * @param {Anything} *: All additional parameters are the params that were
	 *						passed to the failed function (funcName)
	 * @return {Throw} thows an error, no return
	 */
	function fail(funcName) {
		var params = [].slice.call(arguments, 1),
			pText = '', i;

		for (i=0; i<params.length; i++) {
			pText += (pText.length > 0) ? ', ' + type(params[i]) : type(params[i]);
		}

		throw preErr + 'Invalid call to infect.' + funcName + '(' + pText + ')';
	}

	/**
	 * Set a new strain (dependency) in the system for injection
	 *
	 * @method set
	 * @param {String} name: the key used to reference this dependency
	 * @param {Mutable Object} value: the dependency to store for injection
	 */
	function set(name, value) {
		if (type(name) === 'String' && type(value) !== 'Undefined' && value instanceof Object) {
			name = name.indexOf(op) === 0 ? name.substr(op.length) : name;
			strains[name] = value;
			return value;
		} else { fail('set', name, value); return undefined; }
	}

	/**
	 * retrieve a dependency from the store
	 *
	 * @method get
	 * @param {String} name: key that was used to set this dependency
	 * @return {Mutable Object} the dependency from the store
	 */
	function get(name) {
		if (type(name) === 'String') {
			name = name.indexOf(op) === 0 ? name.substr(op.length) : name;
			return strains[name] || undefined;
		} else { fail('get', name); }
	}

	/**
	 * inject an object with a set of dependencies
	 *
	 * @method obj
	 * @param {Object} object: the object to be injected
	 * @param {Array} list: array of keys (strings) that correspond to dependencies
	 * @return {Object} the injected object
	 */
	function obj(object, list) {
		var key, i;
		if (type(object) === 'Object' && list instanceof Array) {
			// assign parameters to more logical names
			i = list.length;
			for (; i-- ;) {
				key = list[i];
				key = key.indexOf(op) === 0 ? key.substr(op.length) : key;
				object[op + key] = get(key);
			}
			return object;
		} else { fail('obj', object, list); }
	}

	/**
	 * inject function or class with dependencies
	 *
	 * @method func
	 * @param {Function} func: the function to be injected
	 * @param {Object} scope: if the function is not used as a constructor
	 *				this object is used as this inside the Injected function
	 * @return {Function} the injected function
	 */
	function func(fnc, scope) {
		var i, key, args, argCount, Infected, $infect;

		if (type(fnc) === 'Array') {
			$infect = fnc;
			fnc = $infect.pop();
			fnc.$infect = $infect;
		}

		if (type(fnc) === 'Function') {
			scope = scope || {};

			// pull the function's parameters as a string
			args = /\(([^)]+)/.exec(fnc.toString());
			// make sure there are parameters provided
			args = (args !== null) ? args[1] : '';
			// if we have parameters, split them into an array
			// while removing whitespace from both ends
			if (args) { args = args.split(/\s*,\s*/); }

			// store the total number of original arguments provided
			// so we know what we should expect when the function is executed
			i = argCount = args.length;
			for (; i-- ;) {
				key = args[i];
				// if the param isn't prefixed with $
				if (key.indexOf(op) !== 0) {
					// set args to the values that should be injected
					// when we execute the injected function
					args = args.slice(i+1);
					// don't process any more
					break;
				}
				// try to pull the dependency now, if it doesn't
				// exist yet, fill with the key and we'll try again
				// on execution
				args[i] = get(key) || key;
			}

			Infected = function () {
				// if the function was compiled, the $infect property can
				// be attached in order to force injection
				args = (Infected.$infect && Infected.$infect.length > 0 && !args.length) ? Infected.$infect : args;

				// convert the parameters passed to the injected
				// function to a proper array
				var _args = [].slice.call(arguments),
					// the total number of params we have for execution
					len = _args.length + args.length,
					_scope = scope;

				if (this instanceof Infected) {
					// if this function is being used as a constructor
					// use the current this object as scope for execution
					_scope = this;
				}

				for (; len < argCount; len++) {
					// stick undefined in for params that are not 
					// provided when the function was called
					_args.push(undefined);
				}

				// spin over all the injected args and check for
				// keys that have not been injected yet, try to inject
				i = args.length;
				for (; i-- ;) {
					if (type(args[i]) === 'String') {
						args[i] = get(args[i]);
					}
				}

				// we cannot handle more arguments than the function was originally
				// declared with, throw an error
				if (len > argCount) { throw preErr + 'Too many parameters! I expected ' +
											(argCount - args.length) + ' (or less) but got ' + _args.length; }

				// combine the injected params and actual params
				_args = _args.concat(args);

				// execute the injected function
				return fnc.apply(_scope, _args);
			};

			// make the injected function an instance of fnc so it will work as
			// a constructor properly
			Infected.prototype = fnc.prototype;
			Infected.prototype.constructor = Infected;

			// pass the $infect property through to the infected function
			// in case it was applied to the original function
			Infected.$infect = fnc.$infect;

			return Infected;
		} else { fail('func', fnc, scope); }
	}

	return {
		'set': set,
		'get': get,
		'obj': obj,
		'func': func,
		'funk': func
	};
}));
},{}],2:[function(require,module,exports){
/*
Mithril v0.2.1
http://mithril.js.org
(c) 2014-2015 <NAME>
License: MIT
*/
!function(a,b){"use strict";var c=b("undefined"!=typeof window?window:{});"object"==typeof module&&null!=module&&module.exports?module.exports=c:"function"==typeof define&&define.amd?define(function(){return c}):a.m=c}(this,function(a,b){"use strict";function c(a){return"function"==typeof a}function d(a){return"[object Object]"===bc.call(a)}function e(a){return"[object String]"===bc.call(a)}function f(){}function g(a,b){for(var c=0;c<a.length;c++)b(a[c],c)}function h(a,b){for(var c in a)cc.call(a,c)&&b(a[c],c)}function i(a){Zb=a.document,$b=a.location,ac=a.cancelAnimationFrame||a.clearTimeout,_b=a.requestAnimationFrame||a.setTimeout}function j(a){function b(){return arguments.length&&(a=arguments[0]),a}return b.toJSON=function(){return a},b}function k(a){return null!=a&&(d(a)||c(a))&&c(a.then)}function l(a,b){return a.then?a.then(b):b()}function m(a){var b=r.prop();return a.then(b),b.then=function(c,d){return a.then(function(){return c(b())},d)},b.catch=function(c){return a.then(function(){return b()},c)},b.finally=function(b){return a.then(function(a){return l(b(),function(){return a})},function(a){return l(b(),function(){throw a})})},b}function n(a){return null!=a&&d(a)&&!("tag"in a||"view"in a||"subtree"in a)}function o(a,b){for(var c,d=[],e=/(?:(^|#|\.)([^#\.\[\]]+))|(\[.+?\])/g;null!=(c=e.exec(a));)if(""===c[1]&&null!=c[2])b.tag=c[2];else if("#"===c[1])b.attrs.id=c[2];else if("."===c[1])d.push(c[2]);else if("["===c[3][0]){var f=/\[(.+?)(?:=("|'|)(.*?)\2)?\]/.exec(c[3]);b.attrs[f[1]]=f[3]||(f[2]?"":!0)}return d}function p(a,b,c,d){var e=!1;if(cc.call(b,c)){var f=b[c];null!=f&&""!==f&&(e=!0,d.push(f))}h(b,function(b,d){a[d]=d===c&&e?"":b}),d.length&&(a[c]=d.join(" "))}function q(a){function b(){return g.apply(this,d)||this}function c(b){for(var c=[b].concat(d),e=1;e<arguments.length;e++)c.push(arguments[e]);return h.apply(a,c)}for(var d=[],e=1;e<arguments.length;e++)d.push(arguments[e]);var g=a.controller||f;g!==f&&(b.prototype=g.prototype);var h=a.view||f;c.$original=h;var i={controller:b,view:c};return d[0]&&null!=d[0].key&&(i.attrs={key:d[0].key}),i}function r(a,b){if(d(a))return q.apply(null,arguments);if(!e(a))throw new TypeError("selector in m(selector, attrs, children) should be a string");if(!a)throw new TypeError("selector cannot be an empty string");for(var c=n(b),f=[],g=c?2:1;g<arguments.length;g++)f.push(arguments[g]);var h;h=1===f.length&&dc(f[0])?f[0]:f;var i={tag:"div",attrs:{},children:h};return p(i.attrs,c?b:{},c&&"class"in b?"class":"className",o(a,i)),i}function s(a,b){for(var c=0;c<a.length;c++){var d=a[c];if(d=d&&d.attrs,d&&null!=d.key&&b(d,c))break}}function t(a){try{if(null!=a&&null!=a.toString())return a}catch(b){}return""}function u(a){for(var b=0;b<a.length;b++)dc(a[b])&&(a=a.concat.apply([],a),b--);return a}function v(a,b,c){a.insertBefore(b,a.childNodes[c]||null)}function w(a,b,c,d,e,f,g,h,i,j,k){return{parent:a,pTag:b,pCache:c,pIndex:d,data:e,cached:f,reattach:g,index:h,editable:i,ns:j,cfgs:k}}function x(a){return a.data=t(a.data),"retain"===a.data.subtree?a.cached:(y(a),dc(a.data)?B(a):null!=a.data&&d(a.data)?H(a):c(a.data)?a.cached:_(a))}function y(a){if(null!=a.cached){if(bc.call(a.cached)===bc.call(a.data))return;if(a.pCache&&a.pCache.nodes){var b=a.index-a.pIndex,c=b+(dc(a.data)?a.data:a.cached.nodes).length;nb(a.pCache.nodes.slice(b,c),a.pCache.slice(b,c))}else a.cached.nodes&&nb(a.cached.nodes,a.cached)}a.cached=new a.data.constructor,a.cached.tag&&(a.cached={}),a.cached.nodes=[]}function z(a){var b=0;s(a,function(){return g(a,function(a){a=a&&a.attrs,a&&null==a.key&&(a.key="__mithril__"+b++)}),!0})}function A(a,b,c,d){return x(w(a.parent,a.pTag,a.cached,a.index,b,c,a.reattach,a.index+d||d,a.editable,a.ns,a.cfgs))}function B(a){a.data=u(a.data);var c=[],d=a.cached.length===a.data.length,e=0,f={},g=!1;s(a.cached,function(a,b){g=!0,f[a.key]={action:ec,index:b}}),z(a.data),g&&C(a,f);for(var h=0,i=0,j=a.data.length;j>i;i++){var k=A(a,a.data[i],a.cached[h],e);k!==b&&(d=d&&k.nodes.intact,e+=gb(k),a.cached[h++]=k)}return d||E(a,c),a.cached}function C(a,b){var c=a.data.length!==a.cached.length;c||s(a.data,function(b,d){var e=a.cached[d];return c=e&&e.attrs&&e.attrs.key!==b.key}),c&&D(a,b)}function D(a,b){var c=a.cached.nodes;s(a.data,function(a,d){a=a.key,b[a]=b[a]?{action:gc,index:d,from:b[a].index,element:c[b[a].index]||Zb.createElement("div")}:{action:fc,index:d}});var d=[];h(b,function(a){d.push(a)});var e=d.sort(hb),f=new Array(a.cached.length);f.nodes=a.cached.nodes.slice(),g(e,function(b){var c=b.index;switch(b.action){case ec:nb(a.cached[c].nodes,a.cached[c]),f.splice(c,1);break;case fc:var d=Zb.createElement("div");d.key=a.data[c].attrs.key,v(a.parent,d,c),f.splice(c,0,{attrs:{key:a.data[c].attrs.key},nodes:[d]}),f.nodes[c]=d;break;case gc:var e=b.element;a.parent.childNodes[c]!==e&&a.parent.insertBefore(e,a.parent.childNodes[c]||null),f[c]=a.cached[b.from],f.nodes[c]=e}}),a.cached=f}function E(a,b){for(var c=0,d=a.data.length;d>c;c++){var e=a.cached[c];null!=e&&b.push.apply(b,e.nodes)}g(a.cached.nodes,function(c,d){null!=c.parentNode&&b.indexOf(c)<0&&nb([c],[a.cached[d]])}),a.data.length<a.cached.length&&(a.cached.length=a.data.length),a.cached.nodes=b}function F(a){var b=a.data.attrs=a.data.attrs||{};a.cached.attrs=a.cached.attrs||{};var c=Object.keys(a.data.attrs);return N(a,c),c.length>+("key"in b)}function G(a){var b=a.data;return b.attrs.xmlns?b.attrs.xmlns:"svg"===b.tag?"http://www.w3.org/2000/svg":"math"===b.tag?"http://www.w3.org/1998/Math/MathML":a.ns}function H(a){var b=[],c=[];if(I(a,b,c),!a.data.tag&&c.length)throw new Error("Component template must return a virtual element, not an array, string, etc.");var d=F(a);return e(a.data.tag)?R({builder:a,hasKeys:d,views:b,controllers:c,ns:G(a)}):void 0}function I(a,b,c){for(var d=a.cached&&a.cached.controllers;null!=a.data.view;)J(a,d,c,b)}function J(a,b,c,d){var e=a.data.view.$original||a.data.view,f=M(a.cached.views,e,b,a.data.controller),g=+(a.data&&a.data.attrs&&a.data.attrs.key);return a.data=0===ic||hc||b&&b.indexOf(f)>-1?a.data.view(f):{tag:"placeholder"},"retain"===a.data.subtree?a.cached:(g===g&&((a.data.attrs=a.data.attrs||{}).key=g),void L(d,c,e,f))}function K(a,b){a.ctrls.splice(a.ctrls.indexOf(a.ctrl),1),a.views.splice(a.views.indexOf(a.view),1),a.ctrl&&c(a.ctrl.onunload)&&a.ctrl.onunload(b)}function L(a,b,c,d){a.push(c),jc[b.push(d)-1]={views:a,view:c,ctrl:d,ctrls:b}}function M(a,b,d,e){var f="diff"===lc()&&a?a.indexOf(b):-1;return f>-1?d[f]:c(e)?new e:{}}function N(a,b){P(a,b)&&(a.cached.nodes.length&&nb(a.cached.nodes),a.cached.cfgCtx&&c(a.cached.cfgCtx.onunload)&&a.cached.cfgCtx.onunload(),a.cached.controllers&&g(a.cached.controllers,function(a){a.unload&&a.onunload({preventDefault:f})}))}function O(a,c){var d=a.length;if(d!==c.length)return!1;for(var e=0,f=Object.create(null);d>e;)f[c[e]]=e++;for(;0!==e;)if(f[a[--e]]===b)return!1;return!0}function P(a,b){var c=a.data,d=a.cached;return c.tag!==d.tag?!0:O(b,Object.keys(d.attrs))?c.attrs.id!==d.attrs.id?!0:c.attrs.key!==d.attrs.key?!0:"all"===lc()?!d.cfgCtx||d.cfgCtx.retain!==!0:"diff"===lc()?d.cfgCtx&&d.cfgCtx.retain===!1:!1:!0}function Q(a){var b=S(a);return a.builder.cached=W(a,b,T(a,b),V(a,b)),b}function R(a){var b=a.builder,c=0===b.cached.nodes.length,d=c?Q(a):Z(a);return(c||b.reattach&&null!=d)&&v(b.parent,d,b.index),$(b,d,c),b.cached}function S(a){var c=a.builder.data;return a.ns===b?c.attrs.is?Zb.createElement(c.tag,c.attrs.is):Zb.createElement(c.tag):c.attrs.is?Zb.createElementNS(a.ns,c.tag,c.attrs.is):Zb.createElementNS(a.ns,c.tag)}function T(a,b){var c=a.builder.data;return a.hasKeys?lb(b,c.tag,c.attrs,{},a.ns):c.attrs}function U(a,c,d){var e=a.builder;return x(w(c,e.data.tag,b,b,e.data.children,e.cached.children,d,0,e.data.attrs.contenteditable?c:e.editable,a.ns,e.cfgs))}function V(a,b){var c=a.builder.data.children;return null!=c&&c.length?U(a,b,!0):c}function W(a,b,c,d){var e=a.builder.data,f={tag:e.tag,attrs:c,children:d,nodes:[b]};return Y(a,f),f.children&&!f.children.nodes&&(f.children.nodes=[]),"select"===e.tag&&"value"in e.attrs&&lb(b,e.tag,{value:e.attrs.value},{},a.ns),f}function X(a){if(a.onunload&&a.onunload.$old&&(a.onunload=a.onunload.$old),ic&&a.onunload){var b=a.onunload;a.onunload=f,a.onunload.$old=b}}function Y(a,b){a.controllers.length&&(b.views=a.views,b.controllers=a.controllers,g(a.controllers,X))}function Z(a){var b=a.builder.cached,c=b.nodes[0];return a.hasKeys&&lb(c,a.builder.data.tag,a.builder.data.attrs,b.attrs,a.ns),b.children=U(a,c,!1),b.nodes.intact=!0,a.controllers.length&&(b.views=a.views,b.controllers=a.controllers),c}function $(a,b,d){var e=a.data,f=a.cached,g=e.attrs.config;if(c(g)){var h=f.cfgCtx=f.cfgCtx||{};a.cfgs.push(function(){return g.call(e,b,!d,h,f)})}}function _(a){return 0===a.cached.nodes.length?bb(a):a.cached.valueOf()!==a.data.valueOf()||a.reattach?cb(a):(a.cached.nodes.intact=!0,a.cached)}function ab(a){return!/^(AREA|BASE|BR|COL|COMMAND|EMBED|HR|IMG|INPUT|KEYGEN|LINK|META|PARAM|SOURCE|TRACK|WBR)$/.test(a)}function bb(a){var b;a.data.$trusted?b=pb(a.parent,a.index,a.data):(b=[Zb.createTextNode(a.data)],ab(a.parent.nodeName)&&v(a.parent,b[0],a.index));var c;return c="string"==typeof a.data||"number"==typeof a.data||"boolean"==typeof a.data?new a.data.constructor(a.data):a.data,c.nodes=b,c}function cb(a){var b=a.cached.nodes;return a.editable&&a.editable===Zb.activeElement||(a.data.$trusted?(nb(b,a.cached),b=pb(a.parent,a.index,a.data)):"textarea"===a.pTag?a.parent.value=a.data:a.editable?a.editable.innerHTML=a.data:((1===b[0].nodeType||b.length>1||b[0].nodeValue.trim&&!b[0].nodeValue.trim())&&(nb(a.cached.nodes,a.cached),b=[Zb.createTextNode(a.data)]),db(a,b[0]))),a.cached=new a.data.constructor(a.data),a.cached.nodes=b,a.cached}function db(a,b){try{v(a.parent,b,a.index),b.nodeValue=a.data}catch(c){}}function eb(){ic++}function fb(){ic>1?ic--:(ic=0,r.redraw())}function gb(a){if(!a.$trusted)return dc(a)?a.length:1;var b=a.match(/<[^\/]|\>\s*[^<]/g);return null!=b?b.length:void 0}function hb(a,b){return a.action-b.action||a.index-b.index}function ib(a){return!/^(list|style|form|type|width|height)$/.test(a)}function jb(a,b,e,f,g,i){if("config"!==a&&"key"!==a)if(c(b)&&"on"===a.slice(0,2))f[a]=qb(b,f);else if("style"===a&&null!=b&&d(b)){h(b,function(a,b){(null==e||e[b]!==a)&&(f.style[b]=a)});for(var j in e)cc.call(e,j)&&(cc.call(b,j)||(f.style[j]=""))}else null!=g?"href"===a?f.setAttributeNS("http://www.w3.org/1999/xlink","href",b):f.setAttribute("className"===a?"class":a,b):a in f&&ib(a)?("input"!==i||f[a]!==b)&&(f[a]=b):f.setAttribute(a,b)}function kb(a,b,c,d,e,f){try{jb(a,b,c,d,e,f)}catch(g){if(/\bInvalid argument\b/.test(g.message))throw g}}function lb(a,b,c,d,e){return h(c,function(c,f){var g=d[f];f in d&&g===c?"value"===f&&"input"===b&&a.value!=c&&(a.value=c):(d[f]=c,kb(f,c,g,a,e,b))}),d}function mb(a){try{a.parentNode.removeChild(a)}catch(b){}}function nb(a,b){if(a.length){b=[].concat(b);for(var c=a.length-1;c>=0;c--){var d=a[c];null!=d&&d.parentNode&&(mb(d),b[c]&&ob(b[c]))}a.length&&(a.length=0)}}function ob(a){a.cfgCtx&&c(a.cfgCtx.onunload)&&(a.cfgCtx.onunload(),a.cfgCtx.onunload=null),a.controllers&&g(a.controllers,function(a){c(a.onunload)&&a.onunload({preventDefault:f})}),a.children&&(dc(a.children)?g(a.children,ob):a.children.tag&&ob(a.children))}function pb(a,b,c){var d=a.childNodes[b];if(d)if(1!==d.nodeType){var e=Zb.createElement("span");a.insertBefore(e,d||null),e.insertAdjacentHTML("beforebegin",c),a.removeChild(e)}else d.insertAdjacentHTML("beforebegin",c);else mc(a,c);for(var f=[];a.childNodes[b]!==d;)f.push(a.childNodes[b++]);return f}function qb(a,b){return function(c){lc("diff"),eb();try{return a.call(b,c||event)}finally{zb()}}}function rb(a){var b=oc.indexOf(a);return 0>b?oc.push(a)-1:b}function sb(a,b,c,d){var e=null===a;if(!d){lc("all"),eb(),rc[c]=b,a=qc=a||{controller:f};var g=new(a.controller||f);return a===qc&&(tc[c]=g,sc[c]=a),zb(),e&&ub(b,c),tc[c]}e&&ub(b,c)}function tb(a,b){if(!a)throw new Error("Please ensure the DOM element exists before rendering a template into it.");var d=rc.indexOf(a);0>d&&(d=rc.length);var e=!1,f={preventDefault:function(){e=!0,uc=vc=null}};return g(jc,function(a){null!=a.ctrl&&(K(a,f),a.ctrl.onunload=null)}),e?g(jc,function(a){a.ctrl.onunload=function(b){K(a,b)}}):jc=[],tc[d]&&c(tc[d].onunload)&&tc[d].onunload(f),sb(b,a,d,e)}function ub(a,b){rc.splice(b,1),tc.splice(b,1),sc.splice(b,1),Ob(a),oc.splice(rb(a),1)}function vb(){0!==xc&&ac(xc),xc=_b(yb,wc)}function wb(){xc=0}function xb(a){xc&&!a?zc():(yb(),xc=_b(wb,wc))}function yb(){uc&&(uc(),uc=null);for(var a=0;a<rc.length;a++){var b=rc[a],c=sc[a],d=tc[a];null!=d&&r.render(b,c.view?c.view(d,[d]):"")}vc&&(vc(),vc=null),xc=null,yc=new Date,lc("diff")}function zb(){"none"===lc()?(ic--,lc("diff")):fb()}function Ab(){var a=$b[Hb.mode];"pathname"===Hb.mode&&(a+=$b.search),Bc!==Ib(a)&&Dc(a)}function Bb(b){a[b]=Ab,uc=Lb,a[b]()}function Cb(){return("pathname"===Hb.mode?"":$b.pathname)+Cc[Hb.mode]}function Db(){a.history.pushState(null,Zb.title,Cc[Hb.mode]+Bc)}function Eb(){a.history.replaceState(null,Zb.title,Cc[Hb.mode]+Bc)}function Fb(b){a.history.pushState?(uc=Lb,vc=b?Eb:Db,Dc(Cc[Hb.mode]+Bc)):($b[Hb.mode]=Bc,Dc(Cc[Hb.mode]+Bc))}function Gb(a,b,c){arguments.length<3&&"object"!=typeof b&&(c=b,b=null);var d=Bc;Bc=a;var e,f,g=b||{},i=Bc.indexOf("?");if(i>=0){var j=Nb(Bc.slice(i+1));h(g,function(a,b){j[b]=g[b]}),e=Mb(j),f=Bc.slice(0,i)}else e=Mb(b),f=Bc;if(e){var k=-1===f.indexOf("?")?"?":"&";Bc=f+k+e}return Fb(c||d===a)}function Hb(a,b,c,d){if(0===arguments.length)return Bc;if(3===arguments.length&&e(b))Dc=function(d){var e=Bc=Ib(d);if(!Jb(a,c,e)){if(Ec)throw new Error("Ensure the default route matches one of the routes defined in m.route");Ec=!0,Hb(b,!0),Ec=!1}},Bb("hash"===Hb.mode?"onhashchange":"onpopstate");else if(a.addEventListener||a.attachEvent)a.href=Cb()+d.attrs.href,a.addEventListener?(a.removeEventListener("click",Kb),a.addEventListener("click",Kb)):(a.detachEvent("onclick",Kb),a.attachEvent("onclick",Kb));else if(e(a))return Gb.apply(null,arguments)}function Ib(a){return a.slice(Cc[Hb.mode].length)}function Jb(a,b,c){var d=c.indexOf("?");d>=0?(Ac=Nb(c.substr(d+1,c.length)),c=c.substr(0,d)):Ac={};var e=Object.keys(b),f=e.indexOf(c);if(f>=0)return tb(a,b[e[f]]),!0;for(var h in b)if(cc.call(b,h)){if(h===c)return tb(a,b[h]),!0;var i=new RegExp("^"+h.replace(/:[^\/]+?\.{3}/g,"(.*?)").replace(/:[^\/]+/g,"([^\\/]+)")+"/?$");if(i.test(c))return c.replace(i,function(){for(var a=[],b=1,c=arguments.length-2;c>b;)a.push(arguments[b++]);var d=h.match(/:[^\/]+/g)||[];g(d,function(b,c){b=b.replace(/:|\./g,""),Ac[b]=decodeURIComponent(a[c])})}),tb(a,b[h]),!0}}function Kb(a){if(a=a||event,!a.ctrlKey&&!a.metaKey&&2!==a.which){a.preventDefault?a.preventDefault():a.returnValue=!1;var b,c=a.currentTarget||a.srcElement;for(b="pathname"===Hb.mode&&c.search?Nb(c.search.slice(1)):{};c&&"A"!==c.nodeName.toUpperCase();)c=c.parentNode;ic=0,Hb(c[Hb.mode].slice(Cc[Hb.mode].length),b)}}function Lb(){"hash"!==Hb.mode&&$b.hash?$b.hash=$b.hash:a.scrollTo(0,0)}function Mb(a,c){var e={},f=[];return h(a,function(a,h){var i=c?c+"["+h+"]":h;if(null===a)f.push(encodeURIComponent(i));else if(d(a))f.push(Mb(a,i));else if(dc(a)){var j=[];e[i]=e[i]||{},g(a,function(a){e[i][a]||(e[i][a]=!0,j.push(encodeURIComponent(i)+"="+encodeURIComponent(a)))}),f.push(j.join("&"))}else a!==b&&f.push(encodeURIComponent(i)+"="+encodeURIComponent(a))}),f.join("&")}function Nb(a){if(!a)return{};"?"===a[0]&&(a=a.slice(1));var b=a.split("&"),c={};return g(b,function(a){var b=a.split("="),d=decodeURIComponent(b[0]),e=2===b.length?decodeURIComponent(b[1]):null;null!=c[d]?(dc(c[d])||(c[d]=[c[d]]),c[d].push(e)):c[d]=e}),c}function Ob(a){var c=rb(a);nb(a.childNodes,pc[c]),pc[c]=b}function Pb(a,b,c){return k(a)?a.then(function(a){Pb(a,b,c)},function(a){Pb(a,c,c)}):b(a)}function Qb(a,d){function e(a){r=a}function f(a){a.resolve(r)}function h(a){a.reject(r)}function i(a){return u!==h&&a(r),a}function j(a){t.push(a)}function l(a,b){var c=Rb().resolve(a()).promise;return b!==h&&c(r),c.then(b)}function m(a){u=a,g(t,a),n=q=null}function n(a,b){Pb(a,function(a){r=a,m(b===Hc?f:h)},function(a){r=a,m(h)})}function o(a,b){var c=0;try{return a.then(function(a){c++||q(Fc,a,b)},function(a){c++||q(Gc,a,b)})}catch(d){return Rb.onerror(d),q(Gc,d,b)}}function p(b,e,f){try{e===Fc&&c(a)?b=a(b):e===Gc&&c(d)&&(b=d(b),e=Fc)}catch(g){return Rb.onerror(g),n(g,Ic)}return b===f?n(TypeError(),Ic):n(b,e===Fc?Hc:Ic)}function q(a,b,c){var d;try{d=k(b)}catch(e){return Rb.onerror(e),q(Gc,e,c)}return a===Gc&&Rb.onerror(b),d?o(b,c):p(b,a,c)}var r,s=this,t=[],u=j;s.resolve=function(a){return u===j&&q(Fc,a,s),s},s.reject=function(a){return u===j&&q(Gc,a,s),s},s.promise=function(a){return arguments.length&&Pb(a,e,e),u!==h?r:b},s.promise.then=function(a,b){var c=new Qb(a,b);return u(c),i(c.promise)},s.promise.catch=function(a){return s.promise.then(null,a)},s.promise.finally=function(a){return s.promise.then(function(){return l(a,function(){return r})},function(){return l(a,function(){throw r})})}}function Rb(){return new Qb}function Sb(a){return a instanceof EvalError||a instanceof RangeError||a instanceof ReferenceError||a instanceof SyntaxError||a instanceof TypeError||a instanceof URIError}function Tb(){return"mithril_callback_"+(new Date).getTime()+"_"+Math.round(1e16*Math.random()).toString(36)}function Ub(c){var d=Tb(),e=Zb.createElement("script");a[d]=function(f){e.parentNode.removeChild(e),c.onload({success:!0,target:{responseText:f}}),a[d]=b},e.onerror=function(){return e.parentNode.removeChild(e),c.onerror({success:!1,target:{status:500,responseText:'{"error": "Error making jsonp request"}'}}),a[d]=b,!1},e.onload=function(){return!1},e.src=c.url+(c.url.indexOf("?")>0?"&":"?")+(c.callbackKey||"callback")+"="+d+"&"+Mb(c.data||{}),Zb.body.appendChild(e)}function Vb(b){var d=new a.XMLHttpRequest;if(d.open(b.method,b.url,!0,b.user,b.password),d.onreadystatechange=function(){4===this.readyState&&(this.status>=200&&this.status<300?b.onload({success:!0,target:this}):b.onerror({success:!1,target:this}))},b.serialize===JSON.stringify&&b.data&&"GET"!==b.method&&d.setRequestHeader("Content-Type","application/json; charset=utf-8"),b.deserialize===JSON.parse&&d.setRequestHeader("Accept","application/json, text/*"),c(b.config)){var f=b.config(d,b);null!=f&&(d=f)}var g;if(g="GET"!==b.method&&b.data?b.data:"",g&&!e(g)&&!(g instanceof a.FormData))throw new Error("Request data should be either be a string or FormData. Check the `serialize` option in `m.request`");return d.send(g),d}function Wb(a){return a.dataType&&"JSONP"===a.dataType.toUpperCase()?Ub(a):Vb(a)}function Xb(a,b,c){if("GET"===a.method&&"jsonp"!==a.dataType){var d=a.url.indexOf("?")<0?"?":"&",e=Mb(b);a.url+=e?d+e:""}else a.data=c(b);return a}function Yb(a,b){var c=a.match(/:[a-z]\w+/gi);return c&&b&&g(c,function(c){var d=c.slice(1);a=a.replace(c,b[d]),delete b[d]}),a}r.version=function(){return"v0.2.1"};var Zb,$b,_b,ac,bc={}.toString,cc={}.hasOwnProperty,dc=Array.isArray||function(a){return"[object Array]"===bc.call(a)};i(a),r.deps=function(b){return i(a=b||a),a},r.prop=function(a){return k(a)?m(a):j(a)},r.component=q;var ec=1,fc=2,gc=3,hc=!1,ic=0,jc=[],kc=!1;r.redraw=function(a){if(!kc){kc=!0,a&&(hc=!0);try{xb(a)}finally{kc=hc=!1}}};var lc=r.redraw.strategy=r.prop();r.startComputation=eb,r.endComputation=fb;var mc=function(){try{return Zb.createRange().createContextualFragment("x"),function(a,b){a.appendChild(Zb.createRange().createContextualFragment(b))}}catch(a){return function(a,b){a.insertAdjacentHTML("beforeend",b)}}}(),nc={appendChild:function(a){Zb.documentElement&&Zb.documentElement!==a?Zb.replaceChild(a,Zb.documentElement):Zb.appendChild(a),this.childNodes=Zb.childNodes},insertBefore:function(a){this.appendChild(a)},childNodes:[]},oc=[],pc={};r.render=function(a,c,d){if(!a)throw new Error("Ensure the DOM element being passed to m.route/m.mount/m.render exists.");var e,f=[],h=rb(a),i=a===Zb;e=i||a===Zb.documentElement?nc:a,i&&"html"!==c.tag&&(c={tag:"html",attrs:{},children:c}),pc[h]===b&&nb(e.childNodes),d===!0&&Ob(a),pc[h]=x(w(e,null,b,b,c,pc[h],!1,0,null,b,f)),g(f,function(a){a()})},r.trust=function(a){return a=new String(a),a.$trusted=!0,a};var qc,rc=[],sc=[],tc=[],uc=null,vc=null,wc=16;r.mount=r.module=tb;var xc=0,yc=0,zc=_b===a.requestAnimationFrame?vb:function(){+new Date-yc>wc&&vb()};r.withAttr=function(a,b,c){return function(d){d=d||event;var e,f=d.currentTarget||this;e=a in f?f[a]:f.getAttribute(a),b.call(c||this,e)}};var Ac,Bc,Cc={pathname:"",hash:"#",search:"?"},Dc=f,Ec=!1;r.route=Hb,Hb.param=function(a){if(!Ac)throw new Error("You must call m.route(element, defaultRoute, routes) before calling mroute.param()");return a?Ac[a]:Ac},Hb.mode="search",Hb.buildQueryString=Mb,Hb.parseQueryString=Nb;var Fc=1,Gc=2,Hc=3,Ic=4;return r.deferred=Rb,Rb.prototype=Qb.prototype,Rb.prototype.constructor=Rb,Rb.onerror=function(a){if(Sb(a))throw ic=0,a},r.sync=function(a){function b(a,b){return e[a]=b,0===--d&&(c.promise(e),c[f](e)),b}var c=new Qb,d=a.length,e=new Array(d),f="resolve";return a.length>0?g(a,function(a,c){a.then(function(a){return b(c,a)},function(a){return f="reject",b(c,a)})}):c.resolve([]),c.promise},r.request=function(a){a.background!==!0&&eb();var b=Rb(),c=function(a){return a},d=c,e=function(a){return a.responseText};return a.dataType&&"JSONP"===a.dataType.toUpperCase()||(c=a.serialize||JSON.stringify,d=a.deserialize||JSON.parse,e=a.extract||function(a){return a.responseText.length||d!==JSON.parse?a.responseText:null}),a.serialize=c,a.deserialize=d,a.method=(a.method||"GET").toUpperCase(),a.url=Yb(a.url,a.data),a=Xb(a,a.data,c),a.onload=a.onerror=function(c){c=c||event;var f,h=c.success;f=h?a.unwrapSuccess:a.unwrapError;try{var i=d(e(c.target,a));f&&(i=f(i,c.target)),h?(dc(i)&&a.type?g(i,function(b,c){i[c]=new a.type(b)}):a.type&&(i=new a.type(i)),b.resolve(i)):b.reject(i)}catch(j){b.reject(j)}finally{a.background!==!0&&fb()}},Wb(a),b.promise(a.initialValue),b.promise},r});

},{}],3:[function(require,module,exports){
var Module, infect,
  bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };

infect = require("./..\\bower_components\\infect\\infect.js");

Module = (function() {
  function Module() {
    this.infect = bind(this.infect, this);
    this.init = bind(this.init, this);
    this.viewModel = bind(this.viewModel, this);
    this.view = bind(this.view, this);
  }

  Module.prototype.view = function(viewName, viewClass) {
    var klass, name;
    this.viewName = viewName;
    this.viewClass = viewClass;
    infect.set(this.viewName, this.viewClass);
    name = !!this.viewName;
    klass = !!this.viewClass;
    if (!name && !klass) {
      return this.view;
    } else if (!name || !klass) {
      throw new Error("Missing argument");
    } else {
      return this;
    }
  };

  Module.prototype.viewModel = function(viewModelName, viewModelClass) {
    var klass, name;
    this.viewModelName = viewModelName;
    this.viewModelClass = viewModelClass;
    infect.set(this.viewModelName, this.viewModelClass);
    name = !!this.viewModelName;
    klass = !!this.viewModelClass;
    if (!name && !klass) {
      return this.viewModel;
    } else if (!name || !klass) {
      throw new Error("Missing argument");
    } else {
      return this;
    }
  };

  Module.prototype.init = function() {
    this.viewModel = new this.viewModelClass();
    this.view = new this.viewClass(this.viewModel);
    return this;
  };

  Module.prototype.infect = function(name, infectable) {
    infect.set(name, infectable);
    return this;
  };

  return Module;

})();

module.exports = Module;


},{"./..\\bower_components\\infect\\infect.js":1}],4:[function(require,module,exports){
"use strict";
var infect, m;

m = require("./..\\bower_components\\mithril\\mithril.min.js");

infect = require("./..\\bower_components\\infect\\infect.js");

infect.set("Module", require("./Module.coffee"));

m.route.mode = "search";

m.route(document, "/todo", {
  "/todo": require("./modules/todo/TodoModule.coffee")
});


},{"./..\\bower_components\\infect\\infect.js":1,"./..\\bower_components\\mithril\\mithril.min.js":2,"./Module.coffee":3,"./modules/todo/TodoModule.coffee":7}],5:[function(require,module,exports){
"use strict";
var TodoListModel;

module.exports = TodoListModel = Array;


},{}],6:[function(require,module,exports){
"use strict";
var TodoModel, m;

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

TodoModel = (function() {
  function TodoModel(data) {
    this.data = data;
    this.description = m.prop(this.data.description);
    this.done = m.prop(false);
  }

  return TodoModel;

})();

module.exports = TodoModel;


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":2}],7:[function(require,module,exports){
var Module, infect;

infect = require("./..\\..\\..\\bower_components\\infect\\infect.js");

Module = require("../../Module.coffee");

module.exports = new Module().viewModel("TodoViewModel", require("./TodoViewModel.coffee")).view("TodoView", require("./TodoView.coffee")).infect("TodoModel", require("./TodoModel.coffee")).infect("TodoListModel", require("./TodoListModel.coffee")).init();


},{"../../Module.coffee":3,"./..\\..\\..\\bower_components\\infect\\infect.js":1,"./TodoListModel.coffee":5,"./TodoModel.coffee":6,"./TodoView.coffee":8,"./TodoViewModel.coffee":9}],8:[function(require,module,exports){
"use strict";
var TodoView, m;

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

TodoView = (function() {
  function TodoView(vm) {
    return function() {
      return m("html", m("head", m("meta[name=viewport][content='width=device-width'][maximum-scale=1.0]"), m("link[rel=stylesheet][href='dist/picnic.min.css']"), m("link[rel=stylesheet][href='dist/plugins.min.css']"), m("link[rel=stylesheet][href='dist/index.css']")), m("body", m("article[class=card row two-third]", m("header", m("h2", "Todo")), m("input", {
        onchange: m.withAttr("value", vm.description),
        value: vm.description()
      }), m("button", {
        onclick: vm.add
      }, "Add"), m("div", vm.list.map(function(task, index) {
        var decor, style;
        decor = task.done() ? "line-through" : "none";
        style = {
          style: {
            textDecoration: decor
          }
        };
        return m("div[class=row one]", m("label", m("input[type=checkbox]", {
          onclick: m.withAttr("checked", task.done),
          checked: task.done()
        }), m("span[class=checkable]", style, task.description())));
      })))));
    };
  }

  return TodoView;

})();

module.exports = TodoView;


},{"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":2}],9:[function(require,module,exports){
"use strict";
var Klass, TodoViewModel, infect, m,
  bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };

m = require("./..\\..\\..\\bower_components\\mithril\\mithril.min.js");

infect = require("./..\\..\\..\\bower_components\\infect\\infect.js");

Klass = (function() {
  function Klass($TodoModel, $TodoListModel) {
    this.$TodoModel = $TodoModel;
    this.$TodoListModel = $TodoListModel;
    this.add = bind(this.add, this);
    this.list = new this.$TodoListModel();
    this.description = m.prop("");
  }

  Klass.prototype.add = function() {
    if (this.description()) {
      this.list.push(new this.$TodoModel({
        description: this.description()
      }));
      return this.description("");
    }
  };

  return Klass;

})();

TodoViewModel = infect.func(Klass);

TodoViewModel.$infect = ["TodoModel, TodoViewModel"];

module.exports = TodoViewModel;


},{"./..\\..\\..\\bower_components\\infect\\infect.js":1,"./..\\..\\..\\bower_components\\mithril\\mithril.min.js":2}]},{},[4]);
{'fraction_non_alphanumeric': 0.2789760914760915, 'fraction_numerical': 0.008234797297297296, 'mean_word_length': 7.660711773807849, 'pattern_counts': {'":': 54, '<': 39, '<?xml version=': 0, '>': 51, 'https://': 2, 'lorem ipsum': 0, 'www.': 6, 'xml': 4}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3979247', 'n_tokens_mistral': 26849, 'n_tokens_neox': 26104, 'n_words': 2371}