From fafd1ee17b9981a1337804fe3f921f314865b490 Mon Sep 17 00:00:00 2001
From: Mike van Rossum
Date: Sun, 14 Jan 2018 00:39:54 +0100
Subject: [PATCH] recompile UI for 0.5.12
---
web/vue/dist/build.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/web/vue/dist/build.js b/web/vue/dist/build.js
index a56e8a504..79238b555 100644
--- a/web/vue/dist/build.js
+++ b/web/vue/dist/build.js
@@ -13,4 +13,4 @@ var C=function(t){function e(){var t=this.$options;t.store?this.$store=t.store:t
* (c) 2017 Evan You
* @license MIT
*/
-function n(t,e){if(!t)throw new Error("[vue-router] "+e)}function r(e,n){"production"===t.env.NODE_ENV||e||"undefined"!=typeof console&&console.warn("[vue-router] "+n)}function i(t){return Object.prototype.toString.call(t).indexOf("Error")>-1}function o(e,n){switch(typeof n){case"undefined":return;case"object":return n;case"function":return n(e);case"boolean":return n?e.params:void 0;default:"production"!==t.env.NODE_ENV&&r(!1,'props in "'+e.path+'" is a '+typeof n+", expecting an object, function or boolean.")}}function a(e,n,i){void 0===n&&(n={});var o,a=i||s;try{o=a(e||"")}catch(e){"production"!==t.env.NODE_ENV&&r(!1,e.message),o={}}for(var u in n){var c=n[u];o[u]=Array.isArray(c)?c.slice():c}return o}function s(t){var e={};return(t=t.trim().replace(/^(\?|#|&)/,""))?(t.split("&").forEach(function(t){var n=t.replace(/\+/g," ").split("="),r=Pt(n.shift()),i=n.length>0?Pt(n.join("=")):null;void 0===e[r]?e[r]=i:Array.isArray(e[r])?e[r].push(i):e[r]=[e[r],i]}),e):e}function u(t){var e=t?Object.keys(t).map(function(e){var n=t[e];if(void 0===n)return"";if(null===n)return Dt(e);if(Array.isArray(n)){var r=[];return n.forEach(function(t){void 0!==t&&(null===t?r.push(Dt(e)):r.push(Dt(e)+"="+Dt(t)))}),r.join("&")}return Dt(e)+"="+Dt(n)}).filter(function(t){return t.length>0}).join("&"):null;return e?"?"+e:""}function c(t,e,n,r){var i=r&&r.options.stringifyQuery,o={name:e.name||t&&t.name,meta:t&&t.meta||{},path:e.path||"/",hash:e.hash||"",query:e.query||{},params:e.params||{},fullPath:f(e,i),matched:t?l(t):[]};return n&&(o.redirectedFrom=f(n,i)),Object.freeze(o)}function l(t){for(var e=[];t;)e.unshift(t),t=t.parent;return e}function f(t,e){var n=t.path,r=t.query;void 0===r&&(r={});var i=t.hash;void 0===i&&(i="");var o=e||u;return(n||"/")+o(r)+i}function d(t,e){return e===It?t===e:!!e&&(t.path&&e.path?t.path.replace(Mt,"")===e.path.replace(Mt,"")&&t.hash===e.hash&&p(t.query,e.query):!(!t.name||!e.name)&&(t.name===e.name&&t.hash===e.hash&&p(t.query,e.query)&&p(t.params,e.params)))}function p(t,e){void 0===t&&(t={}),void 0===e&&(e={});var n=Object.keys(t),r=Object.keys(e);return n.length===r.length&&n.every(function(n){var r=t[n],i=e[n];return"object"==typeof r&&"object"==typeof i?p(r,i):String(r)===String(i)})}function h(t,e){return 0===t.path.replace(Mt,"/").indexOf(e.path.replace(Mt,"/"))&&(!e.hash||t.hash===e.hash)&&v(t.query,e.query)}function v(t,e){for(var n in e)if(!(n in t))return!1;return!0}function m(t){if(!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey||t.defaultPrevented||void 0!==t.button&&0!==t.button)){if(t.currentTarget&&t.currentTarget.getAttribute){if(/\b_blank\b/i.test(t.currentTarget.getAttribute("target")))return}return t.preventDefault&&t.preventDefault(),!0}}function g(t){if(t)for(var e,n=0;n=0&&(e=t.slice(r),t=t.slice(0,r));var i=t.indexOf("?");return i>=0&&(n=t.slice(i+1),t=t.slice(0,i)),{path:t,query:n,hash:e}}function x(t){return t.replace(/\/\//g,"/")}function w(t,e){for(var n,r=[],i=0,o=0,a="",s=e&&e.delimiter||"/";null!=(n=Gt.exec(t));){var u=n[0],c=n[1],l=n.index;if(a+=t.slice(o,l),o=l+u.length,c)a+=c[1];else{var f=t[o],d=n[2],p=n[3],h=n[4],v=n[5],m=n[6],g=n[7];a&&(r.push(a),a="");var _=null!=d&&null!=f&&f!==d,y="+"===m||"*"===m,b="?"===m||"*"===m,x=n[2]||s,w=h||v;r.push({name:p||i++,prefix:d||"",delimiter:x,optional:b,repeat:y,partial:_,asterisk:!!g,pattern:w?$(w):g?".*":"[^"+A(x)+"]+?"})}}return o-1&&(a.params[f]=n.params[f]);if(u)return a.path=M(u.path,a.params,'named route "'+s+'"'),l(u,a,o)}else if(a.path){a.params={};for(var v=0;v=t.length?n():t[i]?e(t[i],function(){r(i+1)}):r(i+1)};r(0)}function st(e){return function(n,o,a){var s=!1,u=0,c=null;ut(e,function(e,n,o,l){if("function"==typeof e&&void 0===e.cid){s=!0,u++;var f,d=lt(function(t){t.__esModule&&t.default&&(t=t.default),e.resolved="function"==typeof t?t:St.extend(t),o.components[l]=t,--u<=0&&a()}),p=lt(function(e){var n="Failed to resolve async component "+l+": "+e;"production"!==t.env.NODE_ENV&&r(!1,n),c||(c=i(e)?e:new Error(n),a(c))});try{f=e(d,p)}catch(t){p(t)}if(f)if("function"==typeof f.then)f.then(d,p);else{var h=f.component;h&&"function"==typeof h.then&&h.then(d,p)}}}),s||a()}}function ut(t,e){return ct(t.map(function(t){return Object.keys(t.components).map(function(n){return e(t.components[n],t.instances[n],t,n)})}))}function ct(t){return Array.prototype.concat.apply([],t)}function lt(t){var e=!1;return function(){for(var n=[],r=arguments.length;r--;)n[r]=arguments[r];if(!e)return e=!0,t.apply(this,n)}}function ft(t){if(!t)if(Vt){var e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^https?:\/\/[^\/]+/,"")}else t="/";return"/"!==t.charAt(0)&&(t="/"+t),t.replace(/\/$/,"")}function dt(t,e){var n,r=Math.max(t.length,e.length);for(n=0;n=0?e.slice(0,n):e;window.location.replace(r+"#"+t)}function At(t,e){return t.push(e),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function $t(t,e,n){var r="hash"===n?"#"+e:e;return t?x(t+"/"+r):r}var St,jt={name:"router-view",functional:!0,props:{name:{type:String,default:"default"}},render:function(t,e){var n=e.props,r=e.children,i=e.parent,a=e.data;a.routerView=!0;for(var s=i.$createElement,u=n.name,c=i.$route,l=i._routerViewCache||(i._routerViewCache={}),f=0,d=!1;i&&i._routerRoot!==i;)i.$vnode&&i.$vnode.data.routerView&&f++,i._inactive&&(d=!0),i=i.$parent;if(a.routerViewDepth=f,d)return s(l[u],a,r);var p=c.matched[f];if(!p)return l[u]=null,s();var h=l[u]=p.components[u];return a.registerRouteInstance=function(t,e){var n=p.instances[u];(e&&n!==t||!e&&n===t)&&(p.instances[u]=e)},(a.hook||(a.hook={})).prepatch=function(t,e){p.instances[u]=e.componentInstance},a.props=o(c,p.props&&p.props[u]),s(h,a,r)}},Tt=/[!'()*]/g,Nt=function(t){return"%"+t.charCodeAt(0).toString(16)},Rt=/%2C/g,Dt=function(t){return encodeURIComponent(t).replace(Tt,Nt).replace(Rt,",")},Pt=decodeURIComponent,Mt=/\/?$/,It=c(null,{path:"/"}),Ft=[String,Object],Lt=[String,Array],zt={name:"router-link",props:{to:{type:Ft,required:!0},tag:{type:String,default:"a"},exact:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,event:{type:Lt,default:"click"}},render:function(t){var e=this,n=this.$router,r=this.$route,i=n.resolve(this.to,r,this.append),o=i.location,a=i.route,s=i.href,u={},l=n.options.linkActiveClass,f=n.options.linkExactActiveClass,p=null==l?"router-link-active":l,v=null==f?"router-link-exact-active":f,_=null==this.activeClass?p:this.activeClass,y=null==this.exactActiveClass?v:this.exactActiveClass,b=o.path?c(null,o,null,n):a;u[y]=d(r,b),u[_]=this.exact?u[y]:h(r,b);var x=function(t){m(t)&&(e.replace?n.replace(o):n.push(o))},w={click:m};Array.isArray(this.event)?this.event.forEach(function(t){w[t]=x}):w[this.event]=x;var k={class:u};if("a"===this.tag)k.on=w,k.attrs={href:s};else{var C=g(this.$slots.default);if(C){C.isStatic=!1;var E=St.util.extend;(C.data=E({},C.data)).on=w;(C.data.attrs=E({},C.data.attrs)).href=s}else k.on=w}return t(this.tag,k,this.$slots.default)}},Vt="undefined"!=typeof window,Ut=Array.isArray||function(t){return"[object Array]"==Object.prototype.toString.call(t)},qt=P,Ht=w,Wt=k,Bt=O,Yt=D,Gt=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");qt.parse=Ht,qt.compile=Wt,qt.tokensToFunction=Bt,qt.tokensToRegExp=Yt;var Kt=Object.create(null),Xt=Object.create(null),Jt=Vt&&function(){var t=window.navigator.userAgent;return(-1===t.indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone"))&&(window.history&&"pushState"in window.history)}(),Zt=Vt&&window.performance&&window.performance.now?window.performance:Date,Qt=et(),te=function(t,e){this.router=t,this.base=ft(e),this.current=It,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[]};te.prototype.listen=function(t){this.cb=t},te.prototype.onReady=function(t,e){this.ready?t():(this.readyCbs.push(t),e&&this.readyErrorCbs.push(e))},te.prototype.onError=function(t){this.errorCbs.push(t)},te.prototype.transitionTo=function(t,e,n){var r=this,i=this.router.match(t,this.current);this.confirmTransition(i,function(){r.updateRoute(i),e&&e(i),r.ensureURL(),r.ready||(r.ready=!0,r.readyCbs.forEach(function(t){t(i)}))},function(t){n&&n(t),t&&!r.ready&&(r.ready=!0,r.readyErrorCbs.forEach(function(e){e(t)}))})},te.prototype.confirmTransition=function(t,e,n){var o=this,a=this.current,s=function(t){i(t)&&(o.errorCbs.length?o.errorCbs.forEach(function(e){e(t)}):(r(!1,"uncaught error during route navigation:"),console.error(t))),n&&n(t)};if(d(t,a)&&t.matched.length===a.matched.length)return this.ensureURL(),s();var u=dt(this.current.matched,t.matched),c=u.updated,l=u.deactivated,f=u.activated,p=[].concat(vt(l),this.router.beforeHooks,mt(c),f.map(function(t){return t.beforeEnter}),st(f));this.pending=t;var h=function(e,n){if(o.pending!==t)return s();try{e(t,a,function(t){!1===t||i(t)?(o.ensureURL(!0),s(t)):"string"==typeof t||"object"==typeof t&&("string"==typeof t.path||"string"==typeof t.name)?(s(),"object"==typeof t&&t.replace?o.replace(t):o.push(t)):n(t)})}catch(t){s(t)}};at(p,h,function(){var n=[];at(_t(f,n,function(){return o.current===t}).concat(o.router.resolveHooks),h,function(){if(o.pending!==t)return s();o.pending=null,e(t),o.router.app&&o.router.app.$nextTick(function(){n.forEach(function(t){t()})})})})},te.prototype.updateRoute=function(t){var e=this.current;this.current=t,this.cb&&this.cb(t),this.router.afterHooks.forEach(function(n){n&&n(t,e)})};var ee=function(t){function e(e,n){var r=this;t.call(this,e,n);var i=e.options.scrollBehavior;i&&B(),window.addEventListener("popstate",function(t){var n=r.current;r.transitionTo(xt(r.base),function(t){i&&Y(e,t,n,!0)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.go=function(t){window.history.go(t)},e.prototype.push=function(t,e,n){var r=this,i=this,o=i.current;this.transitionTo(t,function(t){it(x(r.base+t.fullPath)),Y(r.router,t,o,!1),e&&e(t)},n)},e.prototype.replace=function(t,e,n){var r=this,i=this,o=i.current;this.transitionTo(t,function(t){ot(x(r.base+t.fullPath)),Y(r.router,t,o,!1),e&&e(t)},n)},e.prototype.ensureURL=function(t){if(xt(this.base)!==this.current.fullPath){var e=x(this.base+this.current.fullPath);t?it(e):ot(e)}},e.prototype.getCurrentLocation=function(){return xt(this.base)},e}(te),ne=function(t){function e(e,n,r){t.call(this,e,n),r&&wt(this.base)||kt()}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.setupListeners=function(){var t=this;window.addEventListener("hashchange",function(){kt()&&t.transitionTo(Ct(),function(t){Ot(t.fullPath)})})},e.prototype.push=function(t,e,n){this.transitionTo(t,function(t){Et(t.fullPath),e&&e(t)},n)},e.prototype.replace=function(t,e,n){this.transitionTo(t,function(t){Ot(t.fullPath),e&&e(t)},n)},e.prototype.go=function(t){window.history.go(t)},e.prototype.ensureURL=function(t){var e=this.current.fullPath;Ct()!==e&&(t?Et(e):Ot(e))},e.prototype.getCurrentLocation=function(){return Ct()},e}(te),re=function(t){function e(e,n){t.call(this,e,n),this.stack=[],this.index=-1}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.push=function(t,e,n){var r=this;this.transitionTo(t,function(t){r.stack=r.stack.slice(0,r.index+1).concat(t),r.index++,e&&e(t)},n)},e.prototype.replace=function(t,e,n){var r=this;this.transitionTo(t,function(t){r.stack=r.stack.slice(0,r.index).concat(t),e&&e(t)},n)},e.prototype.go=function(t){var e=this,n=this.index+t;if(!(n<0||n>=this.stack.length)){var r=this.stack[n];this.confirmTransition(r,function(){e.index=n,e.updateRoute(r)})}},e.prototype.getCurrentLocation=function(){var t=this.stack[this.stack.length-1];return t?t.fullPath:"/"},e.prototype.ensureURL=function(){},e}(te),ie=function(e){void 0===e&&(e={}),this.app=null,this.apps=[],this.options=e,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=q(e.routes||[],this);var r=e.mode||"hash";switch(this.fallback="history"===r&&!Jt&&!1!==e.fallback,this.fallback&&(r="hash"),Vt||(r="abstract"),this.mode=r,r){case"history":this.history=new ee(this,e.base);break;case"hash":this.history=new ne(this,e.base,this.fallback);break;case"abstract":this.history=new re(this,e.base);break;default:"production"!==t.env.NODE_ENV&&n(!1,"invalid mode: "+r)}},oe={currentRoute:{}};ie.prototype.match=function(t,e,n){return this.matcher.match(t,e,n)},oe.currentRoute.get=function(){return this.history&&this.history.current},ie.prototype.init=function(e){var r=this;if("production"!==t.env.NODE_ENV&&n(_.installed,"not installed. Make sure to call `Vue.use(VueRouter)` before creating root instance."),this.apps.push(e),!this.app){this.app=e;var i=this.history;if(i instanceof ee)i.transitionTo(i.getCurrentLocation());else if(i instanceof ne){var o=function(){i.setupListeners()};i.transitionTo(i.getCurrentLocation(),o,o)}i.listen(function(t){r.apps.forEach(function(e){e._route=t})})}},ie.prototype.beforeEach=function(t){return At(this.beforeHooks,t)},ie.prototype.beforeResolve=function(t){return At(this.resolveHooks,t)},ie.prototype.afterEach=function(t){return At(this.afterHooks,t)},ie.prototype.onReady=function(t,e){this.history.onReady(t,e)},ie.prototype.onError=function(t){this.history.onError(t)},ie.prototype.push=function(t,e,n){this.history.push(t,e,n)},ie.prototype.replace=function(t,e,n){this.history.replace(t,e,n)},ie.prototype.go=function(t){this.history.go(t)},ie.prototype.back=function(){this.go(-1)},ie.prototype.forward=function(){this.go(1)},ie.prototype.getMatchedComponents=function(t){var e=t?t.matched?t:this.resolve(t).route:this.currentRoute;return e?[].concat.apply([],e.matched.map(function(t){return Object.keys(t.components).map(function(e){return t.components[e]})})):[]},ie.prototype.resolve=function(t,e,n){var r=V(t,e||this.history.current,n,this),i=this.match(r,e),o=i.redirectedFrom||i.fullPath;return{location:r,route:i,href:$t(this.history.base,o,this.mode),normalizedTo:r,resolved:i}},ie.prototype.addRoutes=function(t){this.matcher.addRoutes(t),this.history.current!==It&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(ie.prototype,oe),ie.install=_,ie.version="2.7.0",Vt&&window.Vue&&window.Vue.use(ie),e.a=ie}).call(e,n(9))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(130),i=n.n(r),o=n(129),a=n.n(o),s=n(131),u=n.n(s);e.default={name:"app",components:{top:i.a,bottom:a.a,modal:u.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(125),i=n.n(r),o=n(20),a=n.n(o),s=n(18),u=n.n(s),c=n(3),l=n.n(c),f=n(2);e.default={created:function(){var t=this;n.i(f.a)("configPart/performanceAnalyzer",function(e,n){t.performanceAnalyzer=toml.parse(n.part),t.performanceAnalyzer.enabled=!0})},data:function(){return{dataset:{},strat:{},paperTrader:{},performanceAnalyzer:{}}},components:{stratPicker:a.a,datasetPicker:i.a,paperTrader:u.a},computed:{market:function(){return this.dataset.exchange?{exchange:this.dataset.exchange,currency:this.dataset.currency,asset:this.dataset.asset}:{}},range:function(){return this.dataset.exchange?{from:this.dataset.from,to:this.dataset.to}:{}},config:function(){var t={};return Object.assign(t,{watch:this.market},{paperTrader:this.paperTrader},this.strat,{backtest:{daterange:this.range}},{performanceAnalyzer:this.performanceAnalyzer}),t.valid=this.validConfig(t),t}},methods:{validConfig:function(t){if(!t.backtest)return!1;if(!t.backtest.daterange)return!1;if(l.a.isEmpty(t.backtest.daterange))return!1;if(!t.watch)return!1;if(!t.tradingAdvisor)return!1;var e=t.tradingAdvisor.method;if(l.a.isEmpty(t[e]))return!1;if(t.tradingAdvisor){if(l.a.isNaN(t.tradingAdvisor.candleSize))return!1;if(0==t.tradingAdvisor.candleSize)return!1}return!0},updateDataset:function(t){this.dataset=t,this.$emit("config",this.config)},updateStrat:function(t){this.strat=t,this.$emit("config",this.config)},updatePaperTrader:function(t){this.paperTrader=t,this.paperTrader.enabled=!0,this.$emit("config",this.config)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(119),i=n.n(r),o=n(120),a=n.n(o),s=n(2),u=n(5),c=n.n(u);e.default={data:function(){return{backtestable:!1,backtestState:"idle",backtestResult:!1,config:!1}},methods:{check:function(t){if(this.config=t,!t.valid)return this.backtestable=!1;this.backtestable=!0},run:function(){var t=this;this.backtestState="fetching";var e={gekkoConfig:this.config,data:{candleProps:["close","start"],indicatorResults:!0,report:!0,roundtrips:!0,trades:!0}};n.i(s.b)("backtest",e,function(e,n){t.backtestState="fetched",t.backtestResult=n})}},components:{configBuilder:i.a,result:a.a,spinner:c.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(68),i=n(69);e.default={props:["data","height"],data:function(){return{isClicked:!1}},watch:{data:function(){this.render()}},created:function(){setTimeout(this.render,100)},beforeDestroy:function(){this.remove()},methods:{click:function(){this.isClicked=!0},render:function(){this.remove(),_.size(this.data.candles)<4?n.i(i.a)("Not enough data to spawn chart"):n.i(r.a)(this.data.candles,this.data.trades,this.height)},remove:function(){d3.select("#chart").html("")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(121),i=n.n(r),o=n(10),a=n.n(o),s=n(16),u=n.n(s);e.default={props:["result"],data:function(){return{}},methods:{},components:{roundtripTable:u.a,resultSummary:i.a,chart:a.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["roundtrips"],data:function(){return{}},methods:{diff:function(t){return moment.duration(t).humanize()},humanizeDuration:function(t){return window.humanizeDuration(t)},fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},round:function(t){return(+t).toFixed(3)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(21),i=n.n(r);e.default={props:["report"],components:{paperTradeSummary:i.a},methods:{round:function(t){return(+t).toFixed(5)}},computed:{profitClass:function(){return this.report.relativeProfit>0?"profit":"loss"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(126),i=n.n(r),o=n(3),a=(n.n(o),n(2));e.default={data:function(){return{exchange:!1,credentials:{}}},components:{exchangePicker:i.a},computed:{apiKeySets:function(){return this.$store.state.apiKeys},exchanges:function(){return this.$store.state.exchanges},requires:function(){return this.exchanges&&this.exchange?this.exchanges[this.exchange].requires:[]},config:function(){return{exchange:this.exchange,values:this.credentials}}},watch:{credentials:function(){this.emitConfig()}},methods:{updateExchange:function(t){this.credentials={},this.exchange=t,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)},upload:function(){var t=this,e=this.config.exchange;this.exchanges&&this.apiKeySets.includes(e)&&!confirm("You already have API keys for "+e+" defined, do you want to overwrite them?")||n.i(a.b)("addApiKey",this.config,function(e,n){if(e)return alert(e);t.credentials={}})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(122),i=n.n(r),o=n(2);e.default={components:{apiConfigBuilder:i.a},data:function(){return{addApiToggle:!1}},methods:{openAddApi:function(){this.addApiToggle=!0},removeApiKey:function(t){confirm("Are you sure you want to delete these API keys?")&&n.i(o.b)("removeApiKey",{exchange:t},function(t,e){if(t)return alert(t)})}},computed:{apiKeySets:function(){return this.$store.state.apiKeys}},watch:{apiKeySets:function(){this.addApiToggle=!1}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(5),i=n.n(r),o=n(8),a=n(13),s=n.i(o.a)("\n\n## Local data\n\nGekko needs local market data in order to backtest strategies. The local\ndata can also be used in a warmup period when running a strategy against a\nlive market.\n\n");e.default={mixins:[a.a],components:{spinner:i.a},data:function(){return{intro:s,viewUnscannable:!1}},methods:{toggleUnscannable:function(){this.viewUnscannable=!0},humanizeDuration:function(t){return window.humanizeDuration(t)},fmt:function(t){return t.format("YYYY-MM-DD HH:mm")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),i=n.n(r),o=n(11),a=n.n(o),s=n(3);n.n(s);e.default={data:function(){return{market:{},range:{}}},components:{marketPicker:i.a,rangeCreator:a.a},computed:{config:function(){var t={};return Object.assign(t,this.market,{importer:{daterange:this.range}},{candleWriter:{enabled:!0}}),t}},methods:{updateMarketConfig:function(t){this.market=t,this.emitConfig()},updateRange:function(t){this.range=t,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2),i=n(5),o=n.n(i),a=n(123),s=n.n(a),u=n(8),c=n.i(u.a)("\n\n## Import data\n\nThe importer can download historical market data directly from the exchange.\n\n");e.default={components:{importConfigBuilder:s.a,spinner:o.a},data:function(){return{intro:c,config:{}}},computed:{imports:function(){return this.$store.state.imports}},methods:{daysApart:function(t){var e=moment(t.to),n=moment(t.from);return e.diff(n,"days")},updateConfig:function(t){this.config=t},run:function(){var t=this;if(this.daysApart(this.config.importer.daterange)<1)return alert("You can only import at least one day of data..");n.i(r.b)("import",this.config,function(e,n){if(e)return alert(e);t.$store.commit("addImport",n),t.$router.push({path:"/data/importer/import/"+n.id})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(128),a=n.n(o),s=n(5),u=n.n(s);e.default={components:{progressBar:a.a,spinner:u.a},computed:{data:function(){return i.a.find(this.$store.state.imports,{id:this.$route.params.id})},initialized:function(){if(this.data&&this.latest.isValid())return!0},latest:function(){if(this.data)return this.mom(this.data.latest)},fromEndMs:function(){if(this.data)return this.to.diff(this.latest)},fromEnd:function(){return this.latest?humanizeDuration(this.fromEndMs):"LOADING"},from:function(){if(this.data)return this.mom(this.data.from)},to:function(){if(this.data)return this.mom(this.data.to)},timespan:function(){if(this.data)return this.to.diff(this.from)},progress:function(){if(this.data){return 100*(this.timespan-this.fromEndMs)/this.timespan}}},methods:{fmt:function(t){return t.format("YYYY-MM-DD HH:mm:ss")},mom:function(t){return moment.utc(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),i=n.n(r),o=n(127),a=n.n(o),s=n(20),u=n.n(s),c=n(18),l=n.n(c),f=n(2),d=n(3),p=n.n(d);e.default={created:function(){var t=this;n.i(f.a)("configPart/candleWriter",function(e,n){t.candleWriter=toml.parse(n.part)}),n.i(f.a)("configPart/performanceAnalyzer",function(e,n){t.performanceAnalyzer=toml.parse(n.part),t.performanceAnalyzer.enabled=!0})},data:function(){return{market:{},range:{},type:"",strat:{},paperTrader:{},candleWriter:{},performanceAnalyzer:{}}},components:{marketPicker:i.a,typePicker:a.a,stratPicker:u.a,paperTrader:l.a},computed:{isTradebot:function(){return"tradebot"===this.type},config:function(){var t={};return Object.assign(t,this.market,this.strat,{paperTrader:this.paperTrader},{candleWriter:this.candleWriter},{type:this.type},{performanceAnalyzer:this.performanceAnalyzer}),this.isTradebot&&(delete t.paperTrader,t.trader={enabled:!0}),t.valid=this.validConfig(t),t}},methods:{validConfig:function(t){if("market watcher"===t.type)return!0;if(!t.tradingAdvisor)return!1;if(p.a.isNaN(t.tradingAdvisor.candleSize))return!1;if(0==t.tradingAdvisor.candleSize)return!1;var e=t.tradingAdvisor.method;return!p.a.isEmpty(t[e])},updateMarketConfig:function(t){this.market=t,this.emitConfig()},updateType:function(t){this.type=t,this.emitConfig()},updateStrat:function(t){this.strat=t,this.emitConfig()},updatePaperTrader:function(t){this.paperTrader=t,this.paperTrader.enabled=!0,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)}}}},function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(e,"__esModule",{value:!0});var i,o=n(8),a=n.i(o.a)("\n\n## Live Gekko\n\nRun your strategy against the live market!\n\n");e.default=(i={data:function(){return{text:a}},created:function(){var t=this;this.timer=setInterval(function(){t.now=moment()},1e3)},destroyed:function(){clearTimeout(this.timer)}},r(i,"data",function(){return{text:a,timer:!1,now:moment()}}),r(i,"computed",{stratrunners:function(){return this.$store.state.stratrunners},watchers:function(){return this.$store.state.watchers}}),r(i,"methods",{humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},round:function(t){return(+t).toFixed(3)},timespan:function(t,e){return this.humanizeDuration(this.moment(t).diff(this.moment(e)))}}),i)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(4),a=n(2),s=n(124),u=n.n(s);e.default={components:{gekkoConfigBuilder:u.a},data:function(){return{pendingStratrunner:!1,config:{}}},computed:{watchers:function(){return this.$store.state.watchers},stratrunners:function(){return this.$store.state.stratrunners},watchConfig:function(){var t=i.a.pick(this.config,"watch","candleWriter"),e=o.a.util.extend({},t);return e.type="market watcher",e.mode="realtime",e},requiredHistoricalData:function(){if(this.config.tradingAdvisor&&this.config.valid){var t=this.config.tradingAdvisor;return t.candleSize*t.historySize}},gekkoConfig:function(){var t;if(this.existingMarketWatcher){if(this.requiredHistoricalData){var e=moment().utc().startOf("minute").subtract(this.requiredHistoricalData,"minutes").unix(),n=moment.utc(this.existingMarketWatcher.firstCandle.start).unix();t=moment.unix(Math.max(e,n)).utc().format()}else t=moment().utc().startOf("minute").format();return o.a.util.extend({market:{type:"leech",from:t},mode:"realtime"},this.config)}},existingMarketWatcher:function(){var t=o.a.util.extend({},this.watchConfig.watch);return i.a.find(this.watchers,{watch:t})},exchange:function(){return this.watchConfig.watch.exchange},existingTradebot:function(){return i.a.find(this.stratrunners.filter(function(t){return"tradebot"===t.trader}),{watch:{exchange:this.exchange}})},availableApiKeys:function(){return this.$store.state.apiKeys}},watch:{existingMarketWatcher:function(t,e){var n=this;this.pendingStratrunner&&t&&t.firstCandle&&t.lastCandle&&(this.pendingStratrunner=!1,this.startGekko(function(t,e){n.$router.push({path:"/live-gekkos/stratrunner/"+e.id})}))}},methods:{updateConfig:function(t){this.config=t},start:function(){var t=this;if("tradebot"===this.config.type){if(this.existingTradebot){var e="You already have a tradebot running on this exchange";return e+=", you can only run one tradebot per exchange.",alert(e)}if(!this.availableApiKeys.includes(this.exchange))return alert("Please first configure API keys for this exchange in the config page.")}"market watcher"===this.config.type?this.existingMarketWatcher?(alert("This market is already being watched, redirecting you now..."),this.$router.push({path:"/live-gekkos/watcher/"+this.existingMarketWatcher.id})):this.startWatcher(function(e,n){t.$router.push({path:"/live-gekkos/watcher/"+n.id})}):this.existingMarketWatcher?this.startGekko(this.routeToGekko):this.startWatcher(function(e,n){t.pendingStratrunner=!0})},routeToGekko:function(t,e){if(t||e.error)return console.error(t,e.error);this.$router.push({path:"/live-gekkos/stratrunner/"+e.id})},startWatcher:function(t){n.i(a.b)("startGekko",this.watchConfig,t)},startGekko:function(t){n.i(a.b)("startGekko",this.gekkoConfig,t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(4),i=n(3),o=n.n(i),a=n(2),s=n(5),u=n.n(s),c=n(10),l=n.n(c),f=n(16),d=n.n(f),p=n(21),h=n.n(p);e.default={created:function(){this.isLoading||this.getCandles()},components:{spinner:u.a,chart:l.a,paperTradeSummary:h.a,roundtrips:d.a},data:function(){return{candleFetch:"idle",candles:!1}},computed:{stratrunners:function(){return this.$store.state.stratrunners},data:function(){return o.a.find(this.stratrunners,{id:this.$route.params.id})},chartData:function(){return{candles:this.candles,trades:this.trades}},trades:function(){return this.data?this.data.trades:[]},report:function(){if(this.data)return this.data.report},stratName:function(){if(this.data)return this.data.strat.tradingAdvisor.method},stratParams:function(){if(!this.data)return"";var t=r.a.util.extend({},this.data.strat.params);return delete t.__empty,o.a.isEmpty(t)?"No parameters":JSON.stringify(t,null,4)},isLoading:function(){return!this.data||(!o.a.isObject(this.data.firstCandle)||!o.a.isObject(this.data.lastCandle))},watchers:function(){return this.$store.state.watchers},watcher:function(){var t=r.a.util.extend({},this.data.watch);return o.a.find(this.watchers,{watch:t})}},watch:{"data.lastCandle.start":function(){this.candleFetch="dirty"},data:function(t,e){this.isLoading||"fetched"!==this.candleFetch&&this.getCandles()}},methods:{round:function(t){return(+t).toFixed(5)},humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},getCandles:function(){var t=this;this.candleFetch="fetching";var e=this.data.lastCandle.start,r=this.data.firstCandle.start,i=this.data.strat.tradingAdvisor.candleSize,s={watch:this.data.watch,daterange:{to:e,from:r},candleSize:i};n.i(a.b)("getCandles",s,function(e,n){t.candleFetch="fetched",n&&!n.error&&o.a.isArray(n)||console.log(n),t.candles=n.map(function(t){return t.start=moment.unix(t.start).utc().format(),t})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2),i=n(3),o=n.n(i),a=n(5),s=n.n(a),u=(n(4),n(10)),c=n.n(u);e.default={created:function(){this.isLoading||this.getCandles()},components:{spinner:s.a,chart:c.a},data:function(){return{candleFetch:"idle",candles:[]}},computed:{watchers:function(){return this.$store.state.watchers},data:function(){return o.a.find(this.watchers,{id:this.$route.params.id})},chartData:function(){return{candles:this.candles,trades:[]}},isLoading:function(){return!this.data||(!o.a.isObject(this.data.firstCandle)||!o.a.isObject(this.data.lastCandle))}},watch:{"data.lastCandle.start":function(){this.candleFetch="dirty"},data:function(t,e){t&&t.firstCandle&&t.lastCandle&&"fetched"!==this.candleFetch&&this.getCandles()}},methods:{humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},getCandles:function(){var t=this;this.candleFetch="fetching";var e=moment.utc(this.data.lastCandle.start).unix(),i=Math.max(moment.utc(this.data.firstCandle.start).unix(),moment.utc(e).subtract(7,"days").unix()),o=e-i,a=60;o<86400&&(a=o<43200?1:5),i=moment.unix(i).utc().format(),e=moment.unix(e).utc().format();var s={watch:this.data.watch,daterange:{to:e,from:i},candleSize:a};n.i(r.b)("getCandles",s,function(e,n){t.candleFetch="fetched",t.candles=n.map(function(t){return t.start=moment.unix(t.start).utc().format(),t})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(4)),o=(n(2),n(5)),a=n.n(o),s=n(13);e.default={components:{spinner:a.a},data:function(){return{setIndex:-1,customTo:!1,customFrom:!1,rangeVisible:!1,set:!1}},mixins:[s.a],methods:{humanizeDuration:function(t){return window.humanizeDuration(t,{largest:4})},fmt:function(t){return t.utc().format("YYYY-MM-DD HH:mm")},openRange:function(){if(-1===this.setIndex)return alert("Select a dataset to adjust range");this.updateCustomRange(),this.rangeVisible=!0},updateCustomRange:function(){this.customTo=this.fmt(this.set.to),this.customFrom=this.fmt(this.set.from)},emitSet:function(t){if(t){var e=void 0;this.customTo?(e=i.a.util.extend({},t),e.to=moment.utc(this.customTo,"YYYY-MM-DD HH:mm").format(),e.from=moment.utc(this.customFrom,"YYYY-MM-DD HH:mm").format()):e=t,this.$emit("dataset",e)}}},watch:{setIndex:function(){this.set=this.datasets[this.setIndex],this.updateCustomRange(),this.emitSet(this.set)},customTo:function(){this.emitSet(this.set)},customFrom:function(){this.emitSet(this.set)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(19),a=(n.n(o),n(11));n.n(a),n(2);e.default={props:["onlyTradable","onlyImportable"],data:function(){return{exchange:"poloniex"}},created:function(){this.emitExchange()},computed:{exchanges:function(){var t=Object.assign({},this.$store.state.exchanges);return!i.a.isEmpty(t)&&(this.onlyTradable&&i.a.each(t,function(e,n){e.tradable||delete t[n]}),this.onlyImportable&&i.a.each(t,function(e,n){e.importable||delete t[n]}),t)}},watch:{exchanges:function(){this.emitExchange()},exchange:function(){this.emitExchange()}},methods:{emitExchange:function(){this.$emit("exchange",this.exchange)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(19),a=(n.n(o),n(11));n.n(a),n(2);e.default={props:["onlyTradable","onlyImportable"],data:function(){return{exchange:"poloniex",currency:"USDT",asset:"BTC"}},created:function(){this.emitConfig()},computed:{exchanges:function(){var t=Object.assign({},this.$store.state.exchanges);return!i.a.isEmpty(t)&&(this.onlyTradable&&i.a.each(t,function(e,n){e.tradable||delete t[n]}),this.onlyImportable&&i.a.each(t,function(e,n){e.importable||delete t[n]}),t)},markets:function(){return this.exchanges?this.exchanges[this.exchange]:null},assets:function(){return this.exchanges?this.exchanges[this.exchange].markets[this.currency]:null},currencies:function(){return this.exchanges?i.a.keys(this.exchanges[this.exchange].markets):null},watchConfig:function(){return{watch:{exchange:this.exchange,currency:this.currency,asset:this.asset}}}},watch:{currency:function(){this.emitConfig()},asset:function(){this.emitConfig()},market:function(){this.emitConfig()},exchanges:function(){this.emitConfig()},exchange:function(){this.emitConfig()}},methods:{emitConfig:function(){this.$emit("market",this.watchConfig)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(2));e.default={created:function(){var t=this;n.i(i.a)("configPart/paperTrader",function(e,n){t.rawPaperTraderParams=n.part})},data:function(){return{rawPaperTraderParams:"",rawPaperTraderParamsError:!1,paperTraderParams:{},toggle:"closed"}},watch:{rawPaperTraderParams:function(){this.emitConfig()}},methods:{switchToggle:function(){"open"===this.toggle?this.toggle="closed":this.toggle="open"},emitConfig:function(){this.parseParams(),this.$emit("settings",this.paperTraderParams)},parseParams:function(){try{this.paperTraderParams=toml.parse(this.rawPaperTraderParams),this.paperTraderParams.reportRoundtrips=!0,this.rawPaperTraderParamsError=!1}catch(t){this.rawPaperTraderParamsError=t,this.paperTraderParams={}}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3);n.n(r),n(2);e.default={data:function(){return{from:"",to:""}},created:function(){var t=moment().startOf("minute"),e=t.clone().subtract(3,"months");this.to=this.fmt(t),this.from=this.fmt(e),this.emitRange()},methods:{fmtTs:function(t){return moment.unix(t).utc()},fmt:function(t){return t.utc().format("YYYY-MM-DD HH:mm")},emitRange:function(){this.$emit("range",{from:this.fmtTs(this.from),to:this.fmtTs(this.to)})},emitManualEntry:function(){if(this.from.length<"4"||this.from.length<"4")return this.$emit("range",{});var t=moment.utc(this.from),e=moment.utc(this.to);t.isValid()&&e.isValid()?this.$emit("range",{from:this.fmt(t),to:this.fmt(e)}):this.$emit("range",{})}},watch:{from:function(){this.emitManualEntry()},to:function(){this.emitManualEntry()},config:function(){this.scanned=!1},tab:function(){this.scanned=!1,this.$emit("range",{})},selectedRangeIndex:function(){var t=this.ranges[this.selectedRangeIndex];t&&this.emitRange(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(2));e.default={props:["config"],data:function(){return{scanned:!1,ranges:[],selectedRangeIndex:-1,tab:"scan",from:"",to:""}},methods:{scan:function(){var t=this;this.scanned="fetching",this.selectedRangeIndex=-1,n.i(i.b)("scan",this.config,function(e,n){t.scanned=!0,t.ranges=n,t.selectedRangeIndex=0})},printRange:function(t){var e=function(t){return t.format("YYYY-MM-DD HH:mm")},n=moment.unix(t.from),r=moment.unix(t.to),i=moment.duration(r.diff(n)).humanize();return e(n)+" to "+e(r)+" ("+i+")"},fmtTs:function(t){return moment.unix(t).utc()},fmt:function(t){return t.utc().format()},emitRange:function(t){this.$emit("range",{from:this.fmtTs(t.from),to:this.fmtTs(t.to)})},emitManualEntry:function(){if(this.from.length<"4"||this.from.length<"4")return this.$emit("range",{});var t=moment.utc(this.from),e=moment.utc(this.to);t.isValid()&&e.isValid()?this.$emit("range",{from:this.fmt(t),to:this.fmt(e)}):this.$emit("range",{})},reset:function(){this.scanned=!1,this.$emit("range",{})}},watch:{from:function(){this.emitManualEntry()},to:function(){this.emitManualEntry()},config:function(){this.reset()},tab:function(){this.reset()},selectedRangeIndex:function(){var t=this.ranges[this.selectedRangeIndex];t&&this.emitRange(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(2);e.default={data:function(){return{strategies:[],candleSizeUnit:"hours",rawCandleSize:1,strategy:"MACD",historySize:10,rawStratParams:"",rawStratParamsError:!1,emptyStrat:!1,stratParams:{}}},created:function(){var t=this;n.i(o.a)("strategies",function(e,n){t.strategies=n,i.a.each(t.strategies,function(t){t.empty=""===t.params}),t.rawStratParams=i.a.find(t.strategies,{name:t.strategy}).params,t.emptyStrat=i.a.find(t.strategies,{name:t.strategy}).empty,t.emitConfig()})},watch:{strategy:function(t){t=i.a.find(this.strategies,{name:t}),this.rawStratParams=t.params,this.emptyStrat=t.empty,this.emitConfig()},candleSize:function(){this.emitConfig()},historySize:function(){this.emitConfig()},rawStratParams:function(){this.emitConfig()}},computed:{candleSize:function(){return"minutes"===this.candleSizeUnit?this.rawCandleSize:"hours"===this.candleSizeUnit?60*this.rawCandleSize:"days"===this.candleSizeUnit?60*this.rawCandleSize*24:void 0},singularCandleSizeUnit:function(){return this.candleSizeUnit.slice(0,-1)},config:function(){var t={tradingAdvisor:{enabled:!0,method:this.strategy,candleSize:+this.candleSize,historySize:+this.historySize}};return this.emptyStrat?t[this.strategy]={__empty:!0}:t[this.strategy]=this.stratParams,t}},methods:{humanizeDuration:function(t){return window.humanizeDuration(t)},emitConfig:function(){this.parseParams(),this.$emit("stratConfig",this.config)},parseParams:function(){try{this.stratParams=toml.parse(this.rawStratParams),this.rawStratParamsError=!1}catch(t){this.rawStratParamsError=t,this.stratParams={}}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={created:function(){this.emitType()},data:function(){return{types:["paper trader","market watcher","tradebot"],selectedTypeIndex:0}},methods:{emitType:function(){this.$emit("type",this.type)}},watch:{type:function(){this.emitType()}},computed:{type:function(){return this.types[this.selectedTypeIndex]}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["report"],methods:{round2:function(t){return(+t).toFixed(2)},round:function(t){return(+t).toFixed(5)}},computed:{profitClass:function(){return this.report.relativeProfit>0?"profit":"loss"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["progress"],methods:{round:function(t){return(+t).toFixed(2)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(112),i=n(113);e.default={data:function(){return{version:{gekko:r.version,ui:i.version}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8),i=n.i(r.a)("\n\n## Gekko\n\nGekko is a Bitcoin trading bot and backtesting platform that\nconnects to popular Bitcoin exchanges. It is written in javascript\nand runs on nodejs.\n\n[Find out more](https://gekko.wizb.it/).\n\n*Gekko is 100% open source and free, if you paid for this you have been scammed.*\n\n");e.default={data:function(){return{left:i}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8),i={disconnected:n.i(r.a)("\n\n## Disconnected\n\nSomething happened to either Gekko or the connection.\nPlease check the terminal where Gekko is running or\nyour network connection.\n\n ")};e.default={computed:{active:function(){return!this.$store.state.warnings.connected},content:function(){return this.$store.state.warnings.connected?"":i.disconnected}}}},function(t,e,n){"use strict";var r=n(3),i=n.n(r),o=function(){function t(t,e){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e,n){function r(){if(!d3.event.sourceEvent||"zoom"!==d3.event.sourceEvent.type){var t=d3.event.selection||y.range();_.domain(t.map(y.invert,y)),a(_.domain()),d.select(".axis--y").call(C),T.attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}),S.select(".line").attr("d",A),S.select(".axis--x").call(w),d.select(".zoom").call(O.transform,d3.zoomIdentity.scale(m/(t[1]-t[0])).translate(-t[0],0))}}function a(t){var e=o(t,2),n=e[0],r=e[1],a=i.a.sortedIndex(l,n),s=i.a.sortedIndex(l,r),u=f.slice(a,s);b.domain([.9995*d3.min(u),1.0005*d3.max(u)])}function s(){if(!d3.event.sourceEvent||"brush"!==d3.event.sourceEvent.type){var t=d3.event.transform;a(t.rescaleX(y).domain()),d.select(".axis--y").call(C),_.domain(t.rescaleX(y).domain()),S.select(".line").attr("d",A),T.attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}),S.select(".axis--x").call(w),j.select(".brush").call(E.move,_.range().map(t.invertX,t))}}var u=e.map(function(t){return{price:t.price,date:moment.utc(t.date).toDate(),action:t.action}}),c=t.map(function(t){return{price:t.close,date:moment.utc(t.start).toDate()}}),l=c.map(function(t){return+t.date}),f=c.map(function(t){return+t.price}),d=d3.select("#chart");d.attr("width",window.innerWidth-20);var p={top:20,right:20,bottom:110,left:40},h=n-p.top-p.bottom,v={top:n-70,right:20,bottom:30,left:40},m=+d.attr("width")-p.left-p.right,g=n-v.top-v.bottom,_=d3.scaleUtc().range([0,m]),y=d3.scaleUtc().range([0,m]),b=d3.scaleLinear().range([h,0]),x=d3.scaleLinear().range([g,0]),w=d3.axisBottom(_),k=d3.axisBottom(y),C=d3.axisLeft(b).ticks(n/50),E=d3.brushX().extent([[0,0],[m,g]]).on("brush end",r),O=d3.zoom().scaleExtent([1,100]).translateExtent([[0,0],[m,h]]).extent([[0,0],[m,h]]).on("zoom",s),A=d3.line().x(function(t){return _(t.date)}).y(function(t){return b(t.price)}),$=d3.line().x(function(t){return y(t.date)}).y(function(t){return x(t.price)});d.append("defs").append("clipPath").attr("id","clip").append("rect").attr("width",m).attr("height",h);var S=d.append("g").attr("class","focus").attr("transform","translate("+p.left+","+p.top+")"),j=d.append("g").attr("class","context").attr("transform","translate("+v.left+","+v.top+")");_.domain(d3.extent(c,function(t){return t.date})),b.domain([.99*d3.min(f),1.01*d3.max(f)]),y.domain(_.domain()),x.domain(b.domain()),S.append("path").datum(c).attr("class","line price").attr("d",A),S.append("g").attr("class","axis axis--x").attr("transform","translate(0,"+h+")").call(w),S.append("g").attr("class","axis axis--y").call(C),j.append("path").datum(c).attr("class","line").attr("d",$),j.append("g").attr("class","axis axis--x").attr("transform","translate(0,"+g+")").call(k);var T=d.append("g").attr("transform","translate("+p.left+","+p.top+")").selectAll("circle").data(u).enter().append("circle").attr("class",function(t){return t.action}).attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}).attr("r",5);j.append("g").selectAll("circle").data(u).enter().append("circle").attr("class",function(t){return t.action}).attr("cx",function(t){return y(t.date)}).attr("cy",function(t){return x(t.price)}).attr("r",3);j.append("g").attr("class","brush").call(E).call(E.move,_.range()),d.append("rect").attr("class","zoom").attr("width",m).attr("height",h).attr("transform","translate("+p.left+","+p.top+")").call(O)}},function(t,e,n){"use strict";n.d(e,"a",function(){return r});var r=function(t){d3.select("#chart").append("text").attr("class","message").attr("x",150).attr("y",150).text(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t){var e=n(4),r=n(23),i=n.n(r),o=n(34),a=n(7),s=n(24),u=n.n(s),c=n(33),l=n.n(c),f=n(26),d=n.n(f),p=n(27),h=n.n(p),v=n(28),m=n.n(v),g=n(25),_=n.n(g),y=n(29),b=n.n(y),x=n(30),w=n.n(x),k=n(31),C=n.n(k),E=n(32),O=n.n(E),A=n(6);e.a.use(o.a);var $=new o.a({mode:"hash",base:t,routes:[{path:"/",redirect:"/home"},{path:"/home",component:l.a},{path:"/backtest",component:u.a},{path:"/config",component:_.a},{path:"/data",component:d.a},{path:"/data/importer",component:h.a},{path:"/data/importer/import/:id",component:m.a},{path:"/live-gekkos",component:b.a},{path:"/live-gekkos/new",component:w.a},{path:"/live-gekkos/stratrunner/:id",component:C.a},{path:"/live-gekkos/watcher/:id",component:O.a}]});n.i(A.a)(),new e.a({router:$,store:a.a,el:"#app",render:function(t){return t(i.a)}})}.call(e,"/")},function(t,e,n){"use strict";var r=(n(4),n(22),n(75)),i=n(81),o=n(79),a=n(77),s=n(73);e.a=function(){n.i(r.a)(),n.i(i.a)(),n.i(o.a)(),n.i(a.a)(),n.i(s.a)()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"syncApiKeys",function(){return i}),n.d(e,"syncExchanges",function(){return o});var r=n(4),i=function(t,e){return r.a.set(t,"apiKeys",e),t},o=function(t,e){return r.a.set(t,"exchanges",e),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=function(){function t(t,e){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(t){var e=t,n={};return e.forEach(function(t){n[t.slug]=n[t.slug]||{markets:{}},t.markets.forEach(function(e){var r=a(e.pair,2),i=r[0],o=r[1];n[t.slug].markets[i]=n[t.slug].markets[i]||[],n[t.slug].markets[i].push(o)}),n[t.slug].importable=!!t.providesFullHistory,n[t.slug].tradable=!!t.tradable,n[t.slug].requires=t.requires}),n},u=function(){n.i(r.a)("apiKeys",function(t,e){i.a.commit("syncApiKeys",e)}),n.i(r.a)("exchanges",function(t,e){i.a.commit("syncExchanges",s(e))})},c=function(){o.b.$on("apiKeys",function(t){i.a.commit("syncApiKeys",t.exchanges)})};e.a=function(){u(),c()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addImport",function(){return i}),n.d(e,"syncImports",function(){return o}),n.d(e,"updateImport",function(){return a});var r=n(4),i=function(t,e){return t.imports.push(e),t},o=function(t,e){return t.imports=e,t},a=function(t,e){var n=t.imports.findIndex(function(t){return t.id===e.import_id}),i=t.imports[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.imports,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=function(){n.i(r.a)("imports",function(t,e){i.a.commit("syncImports",e)})},s=function(){o.b.$on("import_update",function(t){i.a.commit("updateImport",t)})};e.a=function(){a(),s()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"setGlobalWarning",function(){return i});var r=(n(4),n(3)),i=(n.n(r),function(t,e){return t.warnings[e.key]=e.value,t})},function(t,e,n){"use strict";var r=n(7),i=n(6),o=function(){i.b.$on("WS_STATUS_CHANGE",function(t){return r.a.commit("setGlobalWarning",{key:"connected",value:t.connected})})};e.a=function(){o()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addStratrunner",function(){return i}),n.d(e,"syncStratrunners",function(){return o}),n.d(e,"updateStratrunner",function(){return a}),n.d(e,"addTradeToStratrunner",function(){return s}),n.d(e,"addRoundtripToStratrunner",function(){return u});var r=n(4),i=function(t,e){return t.stratrunners.push(e),t},o=function(t,e){return t.stratrunners=e,t},a=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.stratrunners,n,o),t},s=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend({},i);return o.trades.push(e.trade),r.a.set(t.stratrunners,n,o),t},u=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend({},i);return o.roundtrips.push(e.roundtrip),r.a.set(t.stratrunners,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=n(3),s=n.n(a),u=function(){n.i(r.a)("gekkos",function(t,e){var n=s.a.filter(e,{type:"leech"});i.a.commit("syncStratrunners",n)})},c=function(){o.b.$on("new_gekko",function(t){"leech"===t.gekko.type&&i.a.commit("addStratrunner",t.gekko)});var t=function(t){i.a.commit("updateStratrunner",t)},e=function(t){i.a.commit("addTradeToStratrunner",t)},n=function(t){i.a.commit("addRoundtripToStratrunner",t)};o.b.$on("report",t),o.b.$on("trade",e),o.b.$on("update",t),o.b.$on("startAt",t),o.b.$on("lastCandle",t),o.b.$on("firstCandle",t),o.b.$on("roundtrip",n)};e.a=function(){u(),c()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addWatcher",function(){return i}),n.d(e,"syncWatchers",function(){return o}),n.d(e,"updateWatcher",function(){return a});var r=n(4),i=function(t,e){return t.watchers.push(e),t},o=function(t,e){return t.watchers=e,t},a=function(t,e){var n=t.watchers.findIndex(function(t){return t.id===e.gekko_id}),i=t.watchers[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.watchers,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=n(3),s=n.n(a),u=function(){n.i(r.a)("gekkos",function(t,e){var n=s.a.filter(e,{type:"watcher"});i.a.commit("syncWatchers",n)})},c=function(){o.b.$on("new_gekko",function(t){"watcher"===t.gekko.type&&i.a.commit("addWatcher",t.gekko)});var t=function(t){i.a.commit("updateWatcher",t)};o.b.$on("update",t),o.b.$on("startAt",t),o.b.$on("lastCandle",t),o.b.$on("firstCandle",t)};e.a=function(){u(),c()}},function(t,e,n){function r(t){if(t)return i(t)}function i(t){for(var e in r.prototype)t[e]=r.prototype[e];return t}t.exports=r,r.prototype.on=r.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+t]=this._callbacks["$"+t]||[]).push(e),this},r.prototype.once=function(t,e){function n(){this.off(t,n),e.apply(this,arguments)}return n.fn=e,this.on(t,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n=this._callbacks["$"+t];if(!n)return this;if(1==arguments.length)return delete this._callbacks["$"+t],this;for(var r,i=0;i4?t:document.documentMode}()},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#chartWrapper.clickable{position:relative}#chartWrapper.clickable .shield{cursor:zoom-in;position:absolute;top:0;bottom:0;left:0;right:0;background:grey;opacity:.1}#chart{background-color:#eee;width:100%}#chart circle{clip-path:url(#clip)}#chart .zoom{cursor:move;fill:none;pointer-events:all}#chart .line{fill:none;stroke:#4682b4;stroke-width:1.5px;clip-path:url(#clip)}#chart circle.buy{fill:#7fff00}#chart circle.sell{fill:red}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".scan-btn{margin-top:80px;margin-bottom:30px}.radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".progressbarWrapper p{text-align:center;font-size:20px}.progressbar{background-color:hsla(0,0%,85%,.99);border-radius:13px;padding:0}@keyframes shimmer{0%{background-position:0 0}to{background-position:960px 0}}.progressbar>div{height:20px;border-radius:10px;background-color:orange;animation-duration:1.5s;animation-fill-mode:forwards;animation-iteration-count:infinite;animation-name:shimmer;animation-timing-function:linear;background:#f6f7f8;background:linear-gradient(90deg,orange 10%,#ffce77 25%,orange 40%);background-size:960px 50px;background-position:0;position:relative}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".summary td{text-align:right}.big{font-size:1.3em}.big,.summary table{width:80%}.price.profit{color:#7fff00}.price.loss{color:red}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".summary td{text-align:right}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".scan-btn{margin-top:80px;margin-bottom:30px}.radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".clickable{cursor:pointer}table.full{width:100%}table.full td{padding:.5rem 0}table.full.data th{text-align:left;padding:.5rem 0}.warning p{margin:0;padding:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".menu{display:flex;width:100%;flex-direction:row;margin-top:0;margin-bottom:2rem}.menu a{flex:1 1 100%;display:block;text-align:center;text-decoration:none;color:inherit}.menu .router-link-active{background-color:hsla(0,0%,98%,.99)}.menu a:hover{text-decoration:underline}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".contain{max-width:900px;margin-left:auto;margin-right:auto}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".spinner{margin:20px auto 100px;width:50px;height:40px;text-align:center;font-size:10px}.spinner>div{background-color:#333;height:100%;width:6px;display:inline-block;margin-right:4px;-webkit-animation:sk-stretchdelay 1.2s infinite ease-in-out;animation:sk-stretchdelay 1.2s infinite ease-in-out}.spinner .rect2{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.spinner .rect3{-webkit-animation-delay:-1s;animation-delay:-1s}.spinner .rect4{-webkit-animation-delay:-.9s;animation-delay:-.9s}.spinner .rect5{-webkit-animation-delay:-.8s;animation-delay:-.8s}@-webkit-keyframes sk-stretchdelay{0%,40%,to{-webkit-transform:scaleY(.4)}20%{-webkit-transform:scaleY(1)}}@keyframes sk-stretchdelay{0%,40%,to{transform:scaleY(.4);-webkit-transform:scaleY(.4)}20%{transform:scaleY(1);-webkit-transform:scaleY(1)}}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#app{display:flex;min-height:100vh;flex-direction:column}.fill{flex:1}.text{max-width:500px}input{background:none;margin-top:.5em}.params{min-height:235px;line-height:1.3em}.hr{margin-top:2rem;margin-bottom:2rem;height:10px;background-color:hsla(0,0%,98%,.99)}.btn--primary{display:inline-block;margin-right:12px;margin-bottom:12px;height:40px;padding:0 18px;border-radius:4px;text-shadow:0 1px 3px rgba(36,180,126,.4);box-shadow:0 4px 6px rgba(50,50,93,.11),0 1px 3px rgba(0,0,0,.08);line-height:40px;transition:transform .25s}.btn--primary,.btn--primary:hover{background-color:#3498db;color:#fff;text-decoration:none}.btn--primary:hover{transform:translateY(-1px);box-shadow:0 7px 14px rgba(50,50,93,.1),0 3px 6px rgba(0,0,0,.08)}.btn--primary:active,.btn--primary:focus{background-color:#3498db;color:#fff;text-decoration:none}.btn--primary:active{transform:translateY(1px)}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"table.clickable{border-collapse:separate}tr.clickable td:first-child{padding-left:5px}tr.clickable{cursor:pointer}tr.clickable:hover{background:hsla(0,0%,85%,.99)}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"td.radio{width:45px}td label{display:inline;font-size:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#modal-background{position:fixed;top:0;bottom:0;left:0;right:0;background-color:#000;opacity:.5}.modal{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:600px;min-height:300px;background-color:#fff}.modal-guts{position:absolute;top:0;left:0;width:100%;height:100%;padding:20px 50px 20px 20px;overflow:auto}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".align .custom-select select{padding:.4em 1.2em .3em .8em}.label-like{display:block;font-size:.9em;color:#777}.align{padding-left:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".align .custom-select select{padding:.4em 1.2em .3em .8em}.label-like{display:block;font-size:.9em;color:#777}.align{padding-left:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".roundtrips{margin-top:50px;margin-bottom:50px}.roundtrips table{width:100%}.roundtrips table td,.roundtrips table th{border:1px solid #c6cbd1;padding:8px 12px}.roundtrips table td.loss{color:red;text-align:right}.roundtrips table td.profit{color:green;text-align:right}.roundtrips table tr:nth-child(2n){background-color:#f6f8fa}",""])},function(t,e){t.exports={name:"gekko",version:"0.5.11",description:"A bitcoin trading bot for auto trading at various exchanges",keywords:["trading","bot","bitcoin","TA","finance"],scripts:{test:"./node_modules/.bin/mocha test/*.js --recursive test -u tdd --reporter spec",start:"node ./gekko --config config.js --ui"},author:"Mike van Rossum ",dependencies:{"@slack/client":"^3.10.0",async:"2.1.2",binance:"^1.0.2","bitcoin-co-id":"0.0.1",bitexthai:"^0.1.0","bitfinex-api-node":"^1.2.0",bitstamp:"^1.0.3",bitx:"^1.5.0","btc-china-fork":"0.0.6","btc-markets":"0.0.10",cexio:"0.0.x","co-fs":"^1.2.0",commander:"^2.9.0",gdax:"^0.4.2",gekko:"0.0.9","gemini-exchange-coffee-api":"2.0.6","humanize-duration":"^3.10.0",koa:"^1.2.0","koa-bodyparser":"^2.2.0","koa-cors":"0.0.16","koa-logger":"^1.3.0","koa-router":"^5.4.0","koa-static":"^2.0.0","kraken-api-es5":"^1.0.0",lakebtc_nodejs:"0.1.x",lodash:"2.x",moment:"2.19.3","node-wex":"^1.0.3","node.bittrex.api":"^0.4.3","okcoin-china":"0.0.7",opn:"^4.0.2","poloniex.js":"0.0.7","promisify-node":"^0.4.0","prompt-lite":"0.1.1",pushbullet:"1.4.3",quadrigacx:"0.0.7",relieve:"^2.1.3",retry:"^0.10.1",semver:"5.4.1",sqlite3:"^3.1.8","stats-lite":"^2.0.4","tiny-promisify":"^0.1.1",toml:"^2.3.0",twitter:"^1.7.1","zaif.jp":"^0.1.4"},devDependencies:{chai:"^2.0.0",mocha:"^2.1.1",proxyquire:"^1.7.10",sinon:"^1.12.2"},engines:{node:">=6.0"},license:"MIT",repository:{type:"git",url:"https://github.com/askmike/gekko.git"}}},function(t,e){t.exports={name:"vue",version:"0.2.0",description:"The frontend for the Gekko UI",author:"Mike van Rossum ",scripts:{dev:"cross-env NODE_ENV=development webpack-dev-server --open --inline --hot",build:"cross-env NODE_ENV=production webpack --progress --hide-modules"},devDependencies:{"babel-core":"^6.0.0","babel-loader":"^6.0.0","babel-preset-es2015":"^6.0.0","cross-env":"^3.0.0","css-loader":"^0.25.0","file-loader":"^0.9.0","json-loader":"^0.5.4",marked:"^0.3.6",superagent:"^2.3.0","superagent-no-cache":"uditalias/superagent-no-cache",vue:"^2.0.1","vue-loader":"^9.7.0","vue-router":"^2.0.3",vuex:"^2.2.1",webpack:"^2.1.0-beta.25","webpack-dev-server":"^2.1.0-beta.0"},dependencies:{jade:"^1.11.0"}}},function(t,e,n){(function(e){(function(){function e(t){this.tokens=[],this.tokens.links={},this.options=t||l.defaults,this.rules=f.normal,this.options.gfm&&(this.options.tables?this.rules=f.tables:this.rules=f.gfm)}function n(t,e){if(this.options=e||l.defaults,this.links=t,this.rules=d.normal,this.renderer=this.options.renderer||new r,this.renderer.options=this.options,!this.links)throw new Error("Tokens array requires a `links` property.");this.options.gfm?this.options.breaks?this.rules=d.breaks:this.rules=d.gfm:this.options.pedantic&&(this.rules=d.pedantic)}function r(t){this.options=t||{}}function i(t){this.tokens=[],this.token=null,this.options=t||l.defaults,this.options.renderer=this.options.renderer||new r,this.renderer=this.options.renderer,this.renderer.options=this.options}function o(t,e){return t.replace(e?/&/g:/&(?!#?\w+;)/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}function a(t){return t.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/g,function(t,e){return e=e.toLowerCase(),"colon"===e?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""})}function s(t,e){return t=t.source,e=e||"",function n(r,i){return r?(i=i.source||i,i=i.replace(/(^|[^\[])\^/g,"$1"),t=t.replace(r,i),n):new RegExp(t,e)}}function u(){}function c(t){for(var e,n,r=1;rAn error occured:
"+o(t.message+"",!0)+"
";throw t}}var f={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:u,hr:/^( *[-*_]){3,} *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,nptable:u,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,blockquote:/^( *>[^\n]+(\n(?!def)[^\n]+)*\n*)+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:/^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,def:/^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,table:u,paragraph:/^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,text:/^[^\n]+/};f.bullet=/(?:[*+-]|\d+\.)/,f.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,f.item=s(f.item,"gm")(/bull/g,f.bullet)(),f.list=s(f.list)(/bull/g,f.bullet)("hr","\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))")("def","\\n+(?="+f.def.source+")")(),f.blockquote=s(f.blockquote)("def",f.def)(),f._tag="(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b",f.html=s(f.html)("comment",//)("closed",/<(tag)[\s\S]+?<\/\1>/)("closing",/])*?>/)(/tag/g,f._tag)(),f.paragraph=s(f.paragraph)("hr",f.hr)("heading",f.heading)("lheading",f.lheading)("blockquote",f.blockquote)("tag","<"+f._tag)("def",f.def)(),f.normal=c({},f),f.gfm=c({},f.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),f.gfm.paragraph=s(f.paragraph)("(?!","(?!"+f.gfm.fences.source.replace("\\1","\\2")+"|"+f.list.source.replace("\\1","\\3")+"|")(),f.tables=c({},f.gfm,{nptable:/^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,table:/^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/}),e.rules=f,e.lex=function(t,n){return new e(n).lex(t)},e.prototype.lex=function(t){return t=t.replace(/\r\n|\r/g,"\n").replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,"\n"),this.token(t,!0)},e.prototype.token=function(t,e,n){for(var r,i,o,a,s,u,c,l,d,t=t.replace(/^ +$/gm,"");t;)if((o=this.rules.newline.exec(t))&&(t=t.substring(o[0].length),o[0].length>1&&this.tokens.push({type:"space"})),o=this.rules.code.exec(t))t=t.substring(o[0].length),o=o[0].replace(/^ {4}/gm,""),this.tokens.push({type:"code",text:this.options.pedantic?o:o.replace(/\n+$/,"")});else if(o=this.rules.fences.exec(t))t=t.substring(o[0].length),this.tokens.push({type:"code",lang:o[2],text:o[3]||""});else if(o=this.rules.heading.exec(t))t=t.substring(o[0].length),this.tokens.push({type:"heading",depth:o[1].length,text:o[2]});else if(e&&(o=this.rules.nptable.exec(t))){for(t=t.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/\n$/,"").split("\n")},l=0;l ?/gm,""),this.token(o,e,!0),this.tokens.push({type:"blockquote_end"});else if(o=this.rules.list.exec(t)){for(t=t.substring(o[0].length),a=o[2],this.tokens.push({type:"list_start",ordered:a.length>1}),o=o[0].match(this.rules.item),r=!1,d=o.length,l=0;l1&&s.length>1||(t=o.slice(l+1).join("\n")+t,l=d-1)),i=r||/\n\n(?!\s*$)/.test(u),l!==d-1&&(r="\n"===u.charAt(u.length-1),i||(i=r)),this.tokens.push({type:i?"loose_item_start":"list_item_start"}),this.token(u,!1,n),this.tokens.push({type:"list_item_end"});this.tokens.push({type:"list_end"})}else if(o=this.rules.html.exec(t))t=t.substring(o[0].length),this.tokens.push({type:this.options.sanitize?"paragraph":"html",pre:!this.options.sanitizer&&("pre"===o[1]||"script"===o[1]||"style"===o[1]),text:o[0]});else if(!n&&e&&(o=this.rules.def.exec(t)))t=t.substring(o[0].length),this.tokens.links[o[1].toLowerCase()]={href:o[2],title:o[3]};else if(e&&(o=this.rules.table.exec(t))){for(t=t.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/(?: *\| *)?\n$/,"").split("\n")},l=0;l])/,autolink:/^<([^ >]+(@|:\/)[^ >]+)>/,url:u,tag:/^|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,link:/^!?\[(inside)\]\(href\)/,reflink:/^!?\[(inside)\]\s*\[([^\]]*)\]/,nolink:/^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,strong:/^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,em:/^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,code:/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,br:/^ {2,}\n(?!\s*$)/,del:u,text:/^[\s\S]+?(?=[\\?(?:\s+['"]([\s\S]*?)['"])?\s*/,d.link=s(d.link)("inside",d._inside)("href",d._href)(),d.reflink=s(d.reflink)("inside",d._inside)(),d.normal=c({},d),d.pedantic=c({},d.normal,{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/}),d.gfm=c({},d.normal,{escape:s(d.escape)("])","~|])")(),url:/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,del:/^~~(?=\S)([\s\S]*?\S)~~/,text:s(d.text)("]|","~]|")("|","|https?://|")()}),d.breaks=c({},d.gfm,{br:s(d.br)("{2,}","*")(),text:s(d.gfm.text)("{2,}","*")()}),n.rules=d,n.output=function(t,e,r){return new n(e,r).output(t)},n.prototype.output=function(t){for(var e,n,r,i,a="";t;)if(i=this.rules.escape.exec(t))t=t.substring(i[0].length),a+=i[1];else if(i=this.rules.autolink.exec(t))t=t.substring(i[0].length),"@"===i[2]?(n=":"===i[1].charAt(6)?this.mangle(i[1].substring(7)):this.mangle(i[1]),r=this.mangle("mailto:")+n):(n=o(i[1]),r=n),a+=this.renderer.link(r,null,n);else if(this.inLink||!(i=this.rules.url.exec(t))){if(i=this.rules.tag.exec(t))!this.inLink&&/^/i.test(i[0])&&(this.inLink=!1),t=t.substring(i[0].length),a+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):o(i[0]):i[0];else if(i=this.rules.link.exec(t))t=t.substring(i[0].length),this.inLink=!0,a+=this.outputLink(i,{href:i[2],title:i[3]}),this.inLink=!1;else if((i=this.rules.reflink.exec(t))||(i=this.rules.nolink.exec(t))){if(t=t.substring(i[0].length),e=(i[2]||i[1]).replace(/\s+/g," "),!(e=this.links[e.toLowerCase()])||!e.href){a+=i[0].charAt(0),t=i[0].substring(1)+t;continue}this.inLink=!0,a+=this.outputLink(i,e),this.inLink=!1}else if(i=this.rules.strong.exec(t))t=t.substring(i[0].length),a+=this.renderer.strong(this.output(i[2]||i[1]));else if(i=this.rules.em.exec(t))t=t.substring(i[0].length),a+=this.renderer.em(this.output(i[2]||i[1]));else if(i=this.rules.code.exec(t))t=t.substring(i[0].length),a+=this.renderer.codespan(o(i[2],!0));else if(i=this.rules.br.exec(t))t=t.substring(i[0].length),a+=this.renderer.br();else if(i=this.rules.del.exec(t))t=t.substring(i[0].length),a+=this.renderer.del(this.output(i[1]));else if(i=this.rules.text.exec(t))t=t.substring(i[0].length),a+=this.renderer.text(o(this.smartypants(i[0])));else if(t)throw new Error("Infinite loop on byte: "+t.charCodeAt(0))}else t=t.substring(i[0].length),n=o(i[1]),r=n,a+=this.renderer.link(r,null,n);return a},n.prototype.outputLink=function(t,e){var n=o(e.href),r=e.title?o(e.title):null;return"!"!==t[0].charAt(0)?this.renderer.link(n,r,this.output(t[1])):this.renderer.image(n,r,o(t[1]))},n.prototype.smartypants=function(t){return this.options.smartypants?t.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014\/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014\/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…"):t},n.prototype.mangle=function(t){if(!this.options.mangle)return t;for(var e,n="",r=t.length,i=0;i.5&&(e="x"+e.toString(16)),n+=""+e+";";return n},r.prototype.code=function(t,e,n){if(this.options.highlight){var r=this.options.highlight(t,e);null!=r&&r!==t&&(n=!0,t=r)}return e?''+(n?t:o(t,!0))+"\n
\n":""+(n?t:o(t,!0))+"\n
"},r.prototype.blockquote=function(t){return"\n"+t+"
\n"},r.prototype.html=function(t){return t},r.prototype.heading=function(t,e,n){return"\n"},r.prototype.hr=function(){return this.options.xhtml?"
\n":"
\n"},r.prototype.list=function(t,e){var n=e?"ol":"ul";return"<"+n+">\n"+t+""+n+">\n"},r.prototype.listitem=function(t){return""+t+"\n"},r.prototype.paragraph=function(t){return""+t+"
\n"},r.prototype.table=function(t,e){return"\n"},r.prototype.tablerow=function(t){return"\n"+t+"
\n"},r.prototype.tablecell=function(t,e){var n=e.header?"th":"td";return(e.align?"<"+n+' style="text-align:'+e.align+'">':"<"+n+">")+t+""+n+">\n"},r.prototype.strong=function(t){return""+t+""},r.prototype.em=function(t){return""+t+""},r.prototype.codespan=function(t){return""+t+"
"},r.prototype.br=function(){return this.options.xhtml?"
":"
"},r.prototype.del=function(t){return""+t+""},r.prototype.link=function(t,e,n){if(this.options.sanitize){try{var r=decodeURIComponent(a(t)).replace(/[^\w:]/g,"").toLowerCase()}catch(t){return""}if(0===r.indexOf("javascript:")||0===r.indexOf("vbscript:"))return""}var i='"+n+""},r.prototype.image=function(t,e,n){var r='":">"},r.prototype.text=function(t){return t},i.parse=function(t,e,n){return new i(e,n).parse(t)},i.prototype.parse=function(t){this.inline=new n(t.links,this.options,this.renderer),this.tokens=t.reverse();for(var e="";this.next();)e+=this.tok();return e},i.prototype.next=function(){return this.token=this.tokens.pop()},i.prototype.peek=function(){return this.tokens[this.tokens.length-1]||0},i.prototype.parseText=function(){for(var t=this.token.text;"text"===this.peek().type;)t+="\n"+this.next().text;return this.inline.output(t)},i.prototype.tok=function(){switch(this.token.type){case"space":return"";case"hr":return this.renderer.hr();case"heading":return this.renderer.heading(this.inline.output(this.token.text),this.token.depth,this.token.text);case"code":return this.renderer.code(this.token.text,this.token.lang,this.token.escaped);case"table":var t,e,n,r,i="",o="";for(n="",t=0;t=300)&&(r=new Error(e.statusText||"Unsuccessful HTTP response"),r.original=t,r.response=e,r.status=e.status)}catch(t){r=t}r?n.callback(r,e):n.callback(null,e)})}function p(t,e){var n=_("DELETE",t);return e&&n.end(e),n}var h;"undefined"!=typeof window?h=window:"undefined"!=typeof self?h=self:(console.warn("Using browser-only version of superagent in non-browser environment"),h=this);var v=n(82),m=n(117),g=n(15),_=t.exports=n(118).bind(null,d);_.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(t){}throw Error("Browser-only verison of superagent could not find XHR")};var y="".trim?function(t){return t.trim()}:function(t){return t.replace(/(^\s*|\s*$)/g,"")};_.serializeObject=i,_.parseString=a,_.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},_.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},_.parse={"application/x-www-form-urlencoded":a,"application/json":JSON.parse},f.prototype.get=function(t){return this.header[t.toLowerCase()]},f.prototype._setHeaderProperties=function(t){var e=this.header["content-type"]||"";this.type=c(e);var n=l(e);for(var r in n)this[r]=n[r]},f.prototype._parseBody=function(t){var e=_.parse[this.type];return!e&&u(this.type)&&(e=_.parse["application/json"]),e&&t&&(t.length||t instanceof Object)?e(t):null},f.prototype._setStatusProperties=function(t){1223===t&&(t=204);var e=t/100|0;this.status=this.statusCode=t,this.statusType=e,this.info=1==e,this.ok=2==e,this.clientError=4==e,this.serverError=5==e,this.error=(4==e||5==e)&&this.toError(),this.accepted=202==t,this.noContent=204==t,this.badRequest=400==t,this.unauthorized=401==t,this.notAcceptable=406==t,this.notFound=404==t,this.forbidden=403==t},f.prototype.toError=function(){var t=this.req,e=t.method,n=t.url,r="cannot "+e+" "+n+" ("+this.status+")",i=new Error(r);return i.status=this.status,i.method=e,i.url=n,i},_.Response=f,v(d.prototype);for(var b in m)d.prototype[b]=m[b];d.prototype.type=function(t){return this.set("Content-Type",_.types[t]||t),this},d.prototype.responseType=function(t){return this._responseType=t,this},d.prototype.accept=function(t){return this.set("Accept",_.types[t]||t),this},d.prototype.auth=function(t,e,n){switch(n||(n={type:"basic"}),n.type){case"basic":var r=btoa(t+":"+e);this.set("Authorization","Basic "+r);break;case"auto":this.username=t,this.password=e}return this},d.prototype.query=function(t){return"string"!=typeof t&&(t=i(t)),t&&this._query.push(t),this},d.prototype.attach=function(t,e,n){return this._getFormData().append(t,e,n||e.name),this},d.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},d.prototype.callback=function(t,e){var n=this._callback;this.clearTimeout(),n(t,e)},d.prototype.crossDomainError=function(){var t=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");t.crossDomain=!0,t.status=this.status,t.method=this.method,t.url=this.url,this.callback(t)},d.prototype._timeoutError=function(){var t=this._timeout,e=new Error("timeout of "+t+"ms exceeded");e.timeout=t,this.callback(e)},d.prototype._appendQueryString=function(){var t=this._query.join("&");t&&(this.url+=~this.url.indexOf("?")?"&"+t:"?"+t)},d.prototype.end=function(t){var e=this,n=this.xhr=_.getXHR(),i=this._timeout,o=this._formData||this._data;this._callback=t||r,n.onreadystatechange=function(){if(4==n.readyState){var t;try{t=n.status}catch(e){t=0}if(0==t){if(e.timedout)return e._timeoutError();if(e._aborted)return;return e.crossDomainError()}e.emit("end")}};var a=function(t,n){n.total>0&&(n.percent=n.loaded/n.total*100),n.direction=t,e.emit("progress",n)};if(this.hasListeners("progress"))try{n.onprogress=a.bind(null,"download"),n.upload&&(n.upload.onprogress=a.bind(null,"upload"))}catch(t){}if(i&&!this._timer&&(this._timer=setTimeout(function(){e.timedout=!0,e.abort()},i)),this._appendQueryString(),this.username&&this.password?n.open(this.method,this.url,!0,this.username,this.password):n.open(this.method,this.url,!0),this._withCredentials&&(n.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof o&&!this._isHost(o)){var s=this._header["content-type"],c=this._serializer||_.serialize[s?s.split(";")[0]:""];!c&&u(s)&&(c=_.serialize["application/json"]),c&&(o=c(o))}for(var l in this.header)null!=this.header[l]&&n.setRequestHeader(l,this.header[l]);return this._responseType&&(n.responseType=this._responseType),this.emit("request",this),n.send(void 0!==o?o:null),this},_.Request=d,_.get=function(t,e,n){var r=_("GET",t);return"function"==typeof e&&(n=e,e=null),e&&r.query(e),n&&r.end(n),r},_.head=function(t,e,n){var r=_("HEAD",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.options=function(t,e,n){var r=_("OPTIONS",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.del=p,_.delete=p,_.patch=function(t,e,n){var r=_("PATCH",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.post=function(t,e,n){var r=_("POST",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.put=function(t,e,n){var r=_("PUT",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r}},function(t,e,n){var r=n(15);e.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},e.parse=function(t){return this._parser=t,this},e.serialize=function(t){return this._serializer=t,this},e.timeout=function(t){return this._timeout=t,this},e.then=function(t,e){if(!this._fullfilledPromise){var n=this;this._fullfilledPromise=new Promise(function(t,e){n.end(function(n,r){n?e(n):t(r)})})}return this._fullfilledPromise.then(t,e)},e.catch=function(t){return this.then(void 0,t)},e.use=function(t){return t(this),this},e.get=function(t){return this._header[t.toLowerCase()]},e.getHeader=e.get,e.set=function(t,e){if(r(t)){for(var n in t)this.set(n,t[n]);return this}return this._header[t.toLowerCase()]=e,this.header[t]=e,this},e.unset=function(t){return delete this._header[t.toLowerCase()],delete this.header[t],this},e.field=function(t,e){if(null===t||void 0===t)throw new Error(".field(name, val) name can not be empty");if(r(t)){for(var n in t)this.field(n,t[n]);return this}if(null===e||void 0===e)throw new Error(".field(name, val) val can not be empty");return this._getFormData().append(t,e),this},e.abort=function(){return this._aborted?this:(this._aborted=!0,this.xhr&&this.xhr.abort(),this.req&&this.req.abort(),this.clearTimeout(),this.emit("abort"),this)},e.withCredentials=function(){return this._withCredentials=!0,this},e.redirects=function(t){return this._maxRedirects=t,this},e.toJSON=function(){return{method:this.method,url:this.url,data:this._data,headers:this._header}},e._isHost=function(t){switch({}.toString.call(t)){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}},e.send=function(t){var e=r(t),n=this._header["content-type"];if(e&&r(this._data))for(var i in t)this._data[i]=t[i];else"string"==typeof t?(n||this.type("form"),n=this._header["content-type"],this._data="application/x-www-form-urlencoded"==n?this._data?this._data+"&"+t:t:(this._data||"")+t):this._data=t;return!e||this._isHost(t)?this:(n||this.type("json"),this)}},function(t,e){function n(t,e,n){return"function"==typeof n?new t("GET",e).end(n):2==arguments.length?new t("GET",e):new t(e,n)}t.exports=n},function(t,e,n){var r,i;n(191),r=n(36);var o=n(163);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(170),r=n(39);var o=n(140);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(169),r=n(41);var o=n(139);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(189),r=n(42);var o=n(161);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(175),r=n(45);var o=n(145);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(190),r=n(48);var o=n(162);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(182),r=n(54);var o=n(154);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;r=n(55);var o=n(151);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(179),r=n(61);var o=n(150);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(167),r=n(63);var o=n(134);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;r=n(64);var o=n(138);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(176),r=n(65);var o=n(146);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(184),r=n(67);var o=n(156);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{class:{clickable:!t.isClicked},attrs:{id:"chartWrapper"}},[n("div",{staticClass:"shield",on:{click:function(e){e.preventDefault(),t.click(e)}}}),n("svg",{attrs:{id:"chart",width:"960",height:t.height}})])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Daterange")]),n("div",[n("label",{attrs:{for:"from"}},[t._v("From")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.from,expression:"from"}],domProps:{value:t.from},on:{input:function(e){e.target.composing||(t.from=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"to"}},[t._v("To")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.to,expression:"to"}],domProps:{value:t.to},on:{input:function(e){e.target.composing||(t.to=e.target.value)}}})])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.progress?n("div",{staticClass:"progressbarWrapper"},[n("p",[n("strong",[t._v(t._s(t.round(t.progress))+"%")])]),n("div",{staticClass:"progressbar"},[n("div",{style:{width:t.progress+"%"}})])]):t._e()},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"mx1"},[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Exchange:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.exchange,expression:"exchange"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.exchange=e.target.multiple?n:n[0]}}},t._l(t.exchanges,function(e,r){return n("option",[t._v(t._s(r))])}))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("label",{attrs:{for:"currency"}},[t._v("Currency:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.currency,expression:"currency"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.currency=e.target.multiple?n:n[0]}}},t._l(t.currencies,function(e){return n("option",[t._v(t._s(e))])}))])]),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("label",{attrs:{for:"asset"}},[t._v("Asset:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.asset,expression:"asset"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.asset=e.target.multiple?n:n[0]}}},t._l(t.assets,function(e){return n("option",[t._v(t._s(e))])}))])])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-3-6"},[n("table",{staticClass:"p1"},[n("tr",[n("th",[t._v("amount of trades")]),n("td",[t._v(t._s(t.report.trades))])]),n("tr",[n("th",[t._v("sharpe ratio")]),n("td",[t._v(t._s(t.round2(t.report.sharpe)))])]),n("tr",[n("th",[t._v("start balance")]),n("td",[t._v(t._s(t.round(t.report.startBalance))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("final balance")]),n("td",[t._v(t._s(t.round(t.report.balance))+" "+t._s(t.report.currency))])]),t._m(0)]),n("div",{staticClass:"big txt--right price",class:t.profitClass},[t._v(t._s(t.round(t.report.relativeProfit))+"%")])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",[n("th",[t._v("simulated profit")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("h2",[t._v("Config")]),n("div",{staticClass:"hr"}),n("h3",[t._v("Available API keys")]),t.apiKeySets.length?t._e():n("p",[n("em",[t._v("You don't have any API keys yet.")])]),n("ul",t._l(t.apiKeySets,function(e){return n("li",[t._v(t._s(e)+" ("),n("a",{attrs:{href:"#"},on:{click:function(n){n.preventDefault(),t.removeApiKey(e)}}},[t._v("remove")]),t._v(")")])})),t.addApiToggle?t._e():n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.openAddApi(e)}}},[t._v("Add an API key")]),t.addApiToggle?[n("div",{staticClass:"hr"}),n("apiConfigBuilder")]:t._e(),n("div",{staticClass:"hr"})],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("footer",{staticClass:"p2 bg--off-white"},[n("div",{staticClass:"contain"},[t._m(0),n("p",[t._v("Using Gekko v"+t._s(t.version.gekko)+" and Gekko UI v"+t._s(t.version.ui)+".")])])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("p",[n("em",[t._v("Use Gekko at your own risk.")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("div",{staticClass:"grd-row summary"},[n("div",{staticClass:"grd-row-col-3-6"},[n("table",{staticClass:"p1"},[n("tr",[n("th",[t._v("start time")]),n("td",[t._v(t._s(t.report.startTime))])]),n("tr",[n("th",[t._v("end time")]),n("td",[t._v(t._s(t.report.endTime))])]),n("tr",[n("th",[t._v("timespan")]),n("td",[t._v(t._s(t.report.timespan))])]),n("tr",[n("th",[t._v("start price")]),n("td",[t._v(t._s(t.round(t.report.startPrice))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("end price")]),n("td",[t._v(t._s(t.round(t.report.endPrice))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("market")]),n("td",[t._v(t._s(t.round(t.report.market))+"%")])])])]),n("paperTradeSummary",{attrs:{report:t.report}})],1)])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"hr contain"}),t._m(0),n("result-summary",{attrs:{report:t.result.report}}),n("div",{staticClass:"hr contain"}),n("chart",{attrs:{data:t.result,height:"500"}}),n("div",{staticClass:"hr contain"}),n("roundtripTable",{attrs:{roundtrips:t.result.roundtrips}})],1)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("h3",[t._v("Backtest result")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[n("h3",[t._v("Start a new gekko")]),n("gekko-config-builder",{on:{config:t.updateConfig}}),n("div",{staticClass:"hr"}),t.config.valid?n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.start(e)}}},[t._v("Start")])]):t._e()],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.intro)}}),n("div",{staticClass:"hr"}),n("h3",[t._v("Currently running imports")]),0===t.imports.length?n("p",[t._v("You currently don't have any imports running.")]):t._e(),t.imports.length?n("ul",t._l(t.imports,function(e){return n("li",[n("router-link",{attrs:{to:"/data/importer/import/"+e.id}},[t._v(t._s(e.watch.exchange)+":"+t._s(e.watch.currency)+"/"+t._s(e.watch.asset))])],1)})):t._e(),n("div",{staticClass:"hr"}),n("h3",[t._v("Start a new import")]),n("import-config-builder",{on:{config:t.updateConfig}}),n("div",{staticClass:"hr"}),n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.run(e)}}},[t._v("Import")])])],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Daterange")]),"scan"===t.tab?[t.scanned?t._e():n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]),"fetching"==t.scanned?n("div",{staticClass:"txt--center"},[n("p",{staticClass:"scan-btn"},[t._v("Scanning..")])]):t._e(),1==t.scanned?[0===t.ranges.length?[n("p",[n("strong",[t._v('Unable to find any local data, do you have local data available for\n"'+t._s(t.config.watch.exchange)+":"+t._s(t.config.watch.currency)+"/"+t._s(t.config.watch.asset)+'"?')])])]:[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Run simulation over:")]),n("form",{staticClass:"radio grd"},t._l(t.ranges,function(e,r){return n("div",{staticClass:"grd-row m1"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.selectedRangeIndex,expression:"selectedRangeIndex"}],staticClass:"grd-row-col-1-6",attrs:{type:"radio"},domProps:{value:r,checked:t._q(t.selectedRangeIndex,r)},on:{__c:function(e){t.selectedRangeIndex=r}}}),n("label",{staticClass:"grd-row-col-5-6",attrs:{for:r}},[t._v(t._s(t.printRange(e)))])])}))],n("p",[n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("rescan")])])])]:t._e(),n("p",{staticClass:"txt--center"},[n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.tab="manual"}}},[t._v("Or manually set a daterange")])])])]:t._e(),"manual"===t.tab?[n("div",[n("label",{attrs:{for:"from"}},[t._v("From:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.from,expression:"from"}],domProps:{value:t.from},on:{input:function(e){e.target.composing||(t.from=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"to"}},[t._v("To:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.to,expression:"to"}],domProps:{value:t.to},on:{input:function(e){e.target.composing||(t.to=e.target.value)}}})]),n("p",{staticClass:"txt--center"}),n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.tab="scan"}}},[t._v("Or scan for a daterange")])])]:t._e()],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.intro)}}),n("div",{staticClass:"hr"}),n("h2",[t._v("Available datasets")]),"idle"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]):t._e(),"scanning"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("spinner")],1):t._e(),"scanned"===t.datasetScanstate?n("div",{staticClass:"my2"},[t.unscannableMakets.length?n("div",{staticClass:"bg--orange p1 warning my1"},[t.viewUnscannable?t._e():n("p",{staticClass:"clickable",on:{click:function(e){e.preventDefault(),t.toggleUnscannable(e)}}},[t._v("Some markets were unscannable, click here for details.")]),t.viewUnscannable?[n("p",[t._v("Unable to find datasets in the following markets:")]),t._l(t.unscannableMakets,function(e){return n("div",{staticClass:"mx2"},[t._v("- "+t._s(e.exchange)+":"+t._s(e.currency)+":"+t._s(e.asset))])})]:t._e()],2):t._e(),t.datasets.length?[n("table",{staticClass:"full data"},[t._m(0),n("tbody",t._l(t.datasets,function(e){return n("tr",[n("td",[t._v(t._s(e.exchange))]),n("td",[t._v(t._s(e.currency))]),n("td",[t._v(t._s(e.asset))]),n("td",[t._v(t._s(t.fmt(e.from)))]),n("td",[t._v(t._s(t.fmt(e.to)))]),n("td",[t._v(t._s(t.humanizeDuration(e.to.diff(e.from))))])])}))])]:t._e(),t.datasets.length?t._e():[n("p",[t._v("It looks like you don't have any local data yet.")])]],2):t._e(),n("div",{staticClass:"my2"},[n("h2",[t._v("Import more data")]),n("p",{staticClass:"text"},[t._v("You can easily import more market data directly from exchanges using the importer.")]),n("router-link",{staticClass:"btn--primary",attrs:{to:"/data/importer"}},[t._v("Go to the importer!")])],1)])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("from")]),n("th",[t._v("to")]),n("th",[t._v("duration")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Market")]),n("market-picker",{staticClass:"contain",attrs:{"only-importable":"true"},on:{market:t.updateMarketConfig}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("range-creator",{on:{range:t.updateRange}})],1)])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{attrs:{id:"top"}}),t._m(0),n("nav",{staticClass:"bg--light-gray"},[n("div",{staticClass:"menu contain"},[n("router-link",{staticClass:"py1",attrs:{to:"/home"}},[t._v("Home")]),n("router-link",{staticClass:"py1",attrs:{to:"/live-gekkos"}},[t._v("Live Gekkos")]),n("router-link",{staticClass:"py1",attrs:{to:"/backtest"}},[t._v("Backtest")]),n("router-link",{staticClass:"py1",attrs:{to:"/data"}},[t._v("Local data")]),n("router-link",{staticClass:"py1",attrs:{to:"/config"}},[t._v("Config")]),n("a",{staticClass:"py1",attrs:{href:"https://gekko.wizb.it/docs/introduction/about_gekko.html",target:"_blank"}},[t._v("Documentation")])],1)])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("header",{staticClass:"bg--off-white grd"},[n("div",{staticClass:"contain grd-row"},[n("h3",{staticClass:"py1 px2 col-2"},[t._v("Gekko UI")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("section",{staticClass:"contain grd-row"},[n("div",{staticClass:"grd-row-col-3-6",domProps:{innerHTML:t._s(t.left)}}),t._m(0)])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-3-6 txt--center"},[n("img",{attrs:{src:"/assets/gekko.jpg"}}),n("p",[n("em",[t._v("The most valuable commodity I know of is information.")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h2",{staticClass:"contain"},[t._v("Backtest")]),n("div",{staticClass:"hr contain"}),n("config-builder",{on:{config:t.check}}),t.backtestable?n("div",[n("div",{staticClass:"txt--center"},["fetching"!==t.backtestState?n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.run(e)}}},[t._v("Backtest")]):t._e(),"fetching"===t.backtestState?n("div",{staticClass:"scan-btn"},[n("p",[t._v("Running backtest..")]),n("spinner")],1):t._e()])]):t._e(),t.backtestResult&&"fetched"===t.backtestState?n("result",{attrs:{result:t.backtestResult}}):t._e()],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement;t._self._c;return t._m(0)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"spinner"},[n("div",{staticClass:"rect1"}),n("div",{staticClass:"rect2"}),n("div",{staticClass:"rect3"}),n("div",{staticClass:"rect4"})])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Type")]),[n("label",{staticClass:"wrapper",attrs:{for:"type"}},[t._v("What do you want to do with gekko?")]),n("form",{staticClass:"radio grd"},t._l(t.types,function(e,r){return n("div",{staticClass:"grd-row m1"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.selectedTypeIndex,expression:"selectedTypeIndex"}],staticClass:"grd-row-col-1-6",attrs:{type:"radio"},domProps:{value:r,checked:t._q(t.selectedTypeIndex,r)},on:{__c:function(e){t.selectedTypeIndex=r}}}),n("label",{staticClass:"grd-row-col-5-6",attrs:{for:r}},[t._v(t._s(e))])])}))]],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"mx1"},[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Exchange:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.exchange,expression:"exchange"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.exchange=e.target.multiple?n:n[0]}}},t._l(t.exchanges,function(e,r){return n("option",[t._v(t._s(r))])}))])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{attrs:{id:"app"}},[n("top"),n("div",{staticClass:"fill"},[n("router-view",{staticClass:"view"})],1),n("bottom"),n("modal")],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain py2"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.text)}}),n("div",{staticClass:"hr"}),n("h3",[t._v("Market watchers")]),t.watchers.length?t._e():n("div",{staticClass:"text"},[n("p",[t._v("You are currently not watching any markets.")])]),t.watchers.length?n("table",{staticClass:"full clickable"},[t._m(0),n("tbody",t._l(t.watchers,function(e){return n("tr",{staticClass:"clickable",on:{click:function(n){t.$router.push({path:"live-gekkos/watcher/"+e.id})}}},[n("td",[t._v(t._s(e.watch.exchange))]),n("td",[t._v(t._s(e.watch.currency))]),n("td",[t._v(t._s(e.watch.asset))]),n("td",[e.firstCandle?[t._v(t._s(t.fmt(e.firstCandle.start)))]:t._e()],2),n("td",[e.lastCandle?[t._v(t._s(t.fmt(e.lastCandle.start)))]:t._e()],2),n("td",[e.firstCandle&&e.lastCandle?[t._v(t._s(t.timespan(e.lastCandle.start,e.firstCandle.start)))]:t._e()],2)])}))]):t._e(),n("h3",[t._v("Strat runners")]),t.stratrunners.length?t._e():n("div",{staticClass:"text"},[n("p",[t._v("You are currently not running any strategies.")])]),t.stratrunners.length?n("table",{staticClass:"full"},[t._m(1),n("tbody",t._l(t.stratrunners,function(e){return n("tr",{staticClass:"clickable",on:{click:function(n){t.$router.push({path:"live-gekkos/stratrunner/"+e.id})}}},[n("td",[t._v(t._s(e.watch.exchange))]),n("td",[t._v(t._s(e.watch.currency))]),n("td",[t._v(t._s(e.watch.asset))]),n("td",[e.lastCandle?[t._v(t._s(t.fmt(e.lastCandle.start)))]:t._e()],2),n("td",[e.firstCandle&&e.lastCandle?[t._v(t._s(t.timespan(e.lastCandle.start,e.firstCandle.start)))]:t._e()],2),n("td",[t._v(t._s(e.strat.name))]),n("td",[e.report?t._e():[t._v("0")],e.report?[t._v(t._s(t.round(e.report.profit))+" "+t._s(e.watch.currency))]:t._e()],2)])}))]):t._e(),n("div",{staticClass:"hr"}),n("h2",[t._v("Start a new live Gekko")]),n("router-link",{staticClass:"btn--primary",attrs:{to:"/live-gekkos/new"}},[t._v("Start a new live Gekko!")])],1)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("started at")]),n("th",[t._v("last update")]),n("th",[t._v("duration")])])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("last update")]),n("th",[t._v("duration")]),n("th",[t._v("strategy")]),n("th",[t._v("profit")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Select a dataset")]),"idle"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]):t._e(),"scanning"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("spinner")],1):t._e(),"scanned"===t.datasetScanstate?n("div",{staticClass:"my2"},[0!=t.datasets.length?n("div",[n("table",{staticClass:"full"},[t._m(0),n("tbody",t._l(t.datasets,function(e,r){return n("tr",[n("td",{staticClass:"radio"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.setIndex,expression:"setIndex"}],attrs:{type:"radio",name:"dataset",id:e.id},domProps:{value:r,checked:t._q(t.setIndex,r)},on:{__c:function(e){t.setIndex=r}}})]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.exchange))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.currency))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.asset))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.fmt(e.from)))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.fmt(e.to)))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.humanizeDuration(e.to.diff(e.from))))])])])}))]),t.rangeVisible?t._e():n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.openRange(e)}}},[t._v("Adjust range")]),t.rangeVisible?[n("div",[n("label",{attrs:{for:"customFrom"}},[t._v("From:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.customFrom,expression:"customFrom"}],domProps:{value:t.customFrom},on:{input:function(e){e.target.composing||(t.customFrom=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"customTo"}},[t._v("To:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.customTo,expression:"customTo"}],domProps:{value:t.customTo},on:{input:function(e){e.target.composing||(t.customTo=e.target.value)}}})])]:t._e()],2):n("em",[t._v("No Data found "),n("a",{attrs:{href:"#/data/importer"}},[t._v("Lets add some")])])]):t._e()])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th"),n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("from")]),n("th",[t._v("to")]),n("th",[t._v("duration")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"my2"},[t.data?t._e():n("div",{staticClass:"contain"},[n("h1",[t._v("Unknown Strat runner")]),n("p",[t._v("Gekko doesn't know what strat runner this is...")])]),t.data?n("div",[n("h2",{staticClass:"contain"},[t._v("Strat runner")]),n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Market")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Exchange")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Currency")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Asset")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.asset))])])]),n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Runtime")]),t.isLoading?n("spinner"):t._e(),t.isLoading?t._e():[t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Watching since")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.firstCandle.start)))])]):t._e(),t.data.lastCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Received data until")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.lastCandle.start)))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Data spanning")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.humanizeDuration(t.moment(t.data.lastCandle.start).diff(t.moment(t.data.firstCandle.start)))))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Amount of trades")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.trades.length))])]):t._e()]],2)]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Strategy")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Name")]),n("div",{staticClass:"grd-row-col-3-6"},[n("strong",[t._v(t._s(t.stratName))])])]),t._v("Parameters"),n("pre",[t._v(t._s(t.stratParams))])]),n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Profit report")]),t.report?t._e():[t._m(0)],t.report?[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Start balance")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.startBalance)))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Current balance")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.balance)))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Market")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.market))+" "+t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Profit")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.profit))+" "+t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Alpha")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.alpha))+" "+t._s(t.data.watch.currency))])])]:t._e()],2)]),t.watcher?n("p",[n("em",[t._v("This strat runner gets data from "),n("router-link",{attrs:{to:"/live-gekkos/watcher/"+t.watcher.id}},[t._v("this market watcher")])],1),t._v(".")]):t._e()]),t.isLoading?t._e():[n("h3",{staticClass:"contain"},[t._v("Market graph")]),"fetching"===t.candleFetch?n("spinner"):t._e(),"fetched"===t.candleFetch?[n("chart",{attrs:{data:t.chartData,height:300}})]:t._e(),n("roundtrips",{attrs:{roundtrips:t.data.roundtrips}})]],2):t._e()])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("p",[n("em",[t._v("Waiting for at least one trade..")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.active?n("div",[n("div",{attrs:{id:"modal-background"}}),n("div",{staticClass:"modal",attrs:{id:"modal"}},[n("div",{staticClass:"modal-guts",domProps:{innerHTML:t._s(t.content)}})])]):t._e()},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd"},[n("div",{staticClass:"px1"},[n("h3",[t._v("Paper trader")]),"closed"===t.toggle?n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.switchToggle(e)}}},[t._v("Change paper trader settings")]):t._e(),"open"===t.toggle?[n("p",[t._v("Settings:")]),n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.rawPaperTraderParams,expression:"rawPaperTraderParams"}],staticClass:"params",domProps:{value:t.rawPaperTraderParams},on:{input:function(e){e.target.composing||(t.rawPaperTraderParams=e.target.value)}}}),t.rawPaperTraderParamsError?n("p",{staticClass:"bg--red p1"},[t._v(t._s(t.rawPaperTraderParamsError.message))]):t._e()]:t._e()],2)])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[t.data&&!t.data.done?n("div",[n("h2",[t._v("Importing data..")]),n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[t._m(0),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[t._m(1),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.currency)+"/"+t._s(t.data.watch.asset))])])]),n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[t._m(2),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.from)))])]),n("div",{staticClass:"grd-row"},[t._m(3),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.to)))])]),t.initialized?n("div",{staticClass:"grd-row"},[t._m(4),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.latest)))])]):t._e(),t.initialized?n("div",{staticClass:"grd-row"},[t._m(5),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fromEnd))])]):t._e()]),t.initialized?t._e():n("spinner"),t.initialized?n("div",{staticClass:"contain"},[n("progressBar",{attrs:{progress:t.progress}})],1):t._e(),n("p",[n("em",[t._v("(you don't have to wait until the import is done,\nyou can already start "),n("router-link",{attrs:{to:"/backtest"}},[t._v("backtesting")]),t._v(").")],1)])],1):t._e(),t.data&&t.data.done?n("div",{staticClass:"txt--center"},[n("h2",[t._v("Import done")]),n("p",[t._v(" \nGo and "),n("router-link",{attrs:{to:"/backtest"}},[t._v("backtest")]),t._v(" with your new data!")],1)]):t._e(),t.data?t._e():n("div",{staticClass:"txt--center"},[n("h2",[t._v("ERROR: Uknown import")]),n("p",[n("I",[t._v("don't know this import..")])],1)])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Market:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Currency/Asset:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("From:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("To:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Imported data until:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Remaining:")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 px1"},[n("h3",[t._v("Strategy")]),n("div",[n("label",{staticClass:"wrapper",attrs:{for:"strat"}},[t._v("Strategy:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.strategy,expression:"strategy"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.strategy=e.target.multiple?n:n[0]}}},t._l(t.strategies,function(e){return n("option",[t._v(t._s(e.name))])}))])]),n("div",[n("label",{attrs:{for:"candleSize"}},[t._v("Candle Size")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.rawCandleSize,expression:"rawCandleSize"}],domProps:{value:t.rawCandleSize},on:{input:function(e){e.target.composing||(t.rawCandleSize=e.target.value)}}})]),n("div",{staticClass:"grd-row-col-3-6 align"},[n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.candleSizeUnit,expression:"candleSizeUnit"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.candleSizeUnit=e.target.multiple?n:n[0]}}},[n("option",[t._v("minutes")]),n("option",[t._v("hours")]),n("option",[t._v("days")])])])])])]),n("div",[n("label",{attrs:{for:"historySize"}},[t._v("Warmup period (in "+t._s(t.rawCandleSize)+" "+t._s(t.singularCandleSizeUnit)+" candles):")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.historySize,expression:"historySize"}],domProps:{value:t.historySize},on:{input:function(e){e.target.composing||(t.historySize=e.target.value)}}}),n("em",{staticClass:"label-like"},[t._v("(will use "+t._s(t.humanizeDuration(t.candleSize*t.historySize*1e3*60))+" of data as history)")])])]),n("div",{staticClass:"grd-row-col-2-6 px1"},[n("div",[n("h3",[t._v("Parameters")]),n("p",[t._v(t._s(t.strategy)+" Parameters:")]),n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.rawStratParams,expression:"rawStratParams"}],staticClass:"params",domProps:{value:t.rawStratParams},on:{input:function(e){e.target.composing||(t.rawStratParams=e.target.value)}}}),t.rawStratParamsError?n("p",{staticClass:"bg--red p1"},[t._v(t._s(t.rawStratParamsError.message))]):t._e()])])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"my2"},[t.data?t._e():n("div",{staticClass:"contain"},[n("h1",[t._v("Unknown Watcher")]),n("p",[t._v("Gekko doesn't know what whatcher this is...")])]),t.data?n("div",[n("h2",{staticClass:"contain"},[t._v("Market Watcher")]),n("div",{staticClass:"grd contain"},[n("h3",[t._v("Market")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Exchange")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Currency")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Asset")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.asset))])]),n("h3",[t._v("Statistics")]),t.isLoading?n("spinner"):t._e(),t.isLoading?t._e():[t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Watching since")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.firstCandle.start)))])]):t._e(),t.data.lastCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Received data until")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.lastCandle.start)))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Data spanning")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.humanizeDuration(t.moment(t.data.lastCandle.start).diff(t.moment(t.data.firstCandle.start)))))])]):t._e()]],2),t.isLoading?t._e():[n("h3",{staticClass:"contain"},[t._v("Market graph")]),"fetching"===t.candleFetch?n("spinner"):t._e(),t.candles.length?[n("chart",{attrs:{data:t.chartData,height:500}})]:t._e()]],2):t._e()])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("h3",[t._v("Add an API key")]),n("p",[t._v("Make sure that the API key has the permissions to create and cancel orders and view balances.")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Exchange")]),n("exchange-picker",{staticClass:"contain",attrs:{"only-tradable":"true"},on:{exchange:t.updateExchange}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Credentials")]),t._l(t.requires,function(e){return[n("label",[t._v(t._s(e))]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.credentials[e],expression:"credentials[cred]"}],domProps:{value:t.credentials[e]},on:{input:function(n){n.target.composing||t.$set(t.credentials,e,n.target.value)}}})]})],2)]),n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.upload(e)}}},[t._v("Add")])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Market")]),n("market-picker",{staticClass:"contain",attrs:{"only-tradable":t.isTradebot},on:{market:t.updateMarketConfig}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("type-picker",{on:{type:t.updateType}})],1)]),"market watcher"!==t.type?[n("div",{staticClass:"hr"}),n("strat-picker",{staticClass:"contain my2",on:{stratConfig:t.updateStrat}}),"paper trader"===t.type?n("div",{staticClass:"hr"}):t._e(),"paper trader"===t.type?n("paper-trader",{on:{settings:t.updatePaperTrader}}):t._e()]:t._e()],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("dataset-picker",{staticClass:"contain my2",on:{dataset:t.updateDataset}}),n("div",{staticClass:"hr"}),n("strat-picker",{staticClass:"contain my2",on:{stratConfig:t.updateStrat}}),n("div",{staticClass:"hr"}),n("paper-trader",{on:{settings:t.updatePaperTrader}}),n("div",{staticClass:"hr"})],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain roundtrips"},[n("h2",[t._v("Roundtrips")]),t.roundtrips.length?n("table",[n("thead",[t._m(0),t._l(t.roundtrips,function(e){return n("tr",[n("td",[t._v(t._s(t.fmt(e.entryAt)))]),n("td",[t._v(t._s(t.fmt(e.exitAt)))]),n("td",[t._v(t._s(t.diff(e.duration)))]),n("td",[t._v(t._s(t.round(e.entryBalance)))]),n("td",[t._v(t._s(t.round(e.exitBalance)))]),-1===Math.sign(e.pnl)?[n("td",{staticClass:"loss"},[t._v(t._s(Math.sign(e.pnl)*e.pnl.toFixed(2)))]),n("td",{staticClass:"loss"},[t._v(t._s(e.profit.toFixed(2))+"%")])]:[n("td",{staticClass:"profit"},[t._v(t._s(e.pnl.toFixed(2)))]),n("td",{staticClass:"profit"},[t._v(t._s(e.profit.toFixed(2))+"%")])]],2)})],2)]):t._e(),t.roundtrips.length?t._e():n("div",[n("p",[t._v("Not enough data to display")])])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",[n("th",[t._v("Entry at (UTC)")]),n("th",[t._v("Exit at (UTC)")]),n("th",[t._v("Exposure")]),n("th",[t._v("Entry balance")]),n("th",[t._v("Exit balance")]),n("th",[t._v("P&L")]),n("th",[t._v("Profit")])])}]}},function(t,e,n){var r=n(84);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(85);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(86);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(87);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(88);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(89);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(90);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(91);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(92);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(93);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(94);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(95);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(96);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(97);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(98);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(99);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(100);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(101);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(102);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(103);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(104);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(105);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(106);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(107);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(108);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(109);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(110);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(111);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}}]);
\ No newline at end of file
+function n(t,e){if(!t)throw new Error("[vue-router] "+e)}function r(e,n){"production"===t.env.NODE_ENV||e||"undefined"!=typeof console&&console.warn("[vue-router] "+n)}function i(t){return Object.prototype.toString.call(t).indexOf("Error")>-1}function o(e,n){switch(typeof n){case"undefined":return;case"object":return n;case"function":return n(e);case"boolean":return n?e.params:void 0;default:"production"!==t.env.NODE_ENV&&r(!1,'props in "'+e.path+'" is a '+typeof n+", expecting an object, function or boolean.")}}function a(e,n,i){void 0===n&&(n={});var o,a=i||s;try{o=a(e||"")}catch(e){"production"!==t.env.NODE_ENV&&r(!1,e.message),o={}}for(var u in n){var c=n[u];o[u]=Array.isArray(c)?c.slice():c}return o}function s(t){var e={};return(t=t.trim().replace(/^(\?|#|&)/,""))?(t.split("&").forEach(function(t){var n=t.replace(/\+/g," ").split("="),r=Pt(n.shift()),i=n.length>0?Pt(n.join("=")):null;void 0===e[r]?e[r]=i:Array.isArray(e[r])?e[r].push(i):e[r]=[e[r],i]}),e):e}function u(t){var e=t?Object.keys(t).map(function(e){var n=t[e];if(void 0===n)return"";if(null===n)return Dt(e);if(Array.isArray(n)){var r=[];return n.forEach(function(t){void 0!==t&&(null===t?r.push(Dt(e)):r.push(Dt(e)+"="+Dt(t)))}),r.join("&")}return Dt(e)+"="+Dt(n)}).filter(function(t){return t.length>0}).join("&"):null;return e?"?"+e:""}function c(t,e,n,r){var i=r&&r.options.stringifyQuery,o={name:e.name||t&&t.name,meta:t&&t.meta||{},path:e.path||"/",hash:e.hash||"",query:e.query||{},params:e.params||{},fullPath:f(e,i),matched:t?l(t):[]};return n&&(o.redirectedFrom=f(n,i)),Object.freeze(o)}function l(t){for(var e=[];t;)e.unshift(t),t=t.parent;return e}function f(t,e){var n=t.path,r=t.query;void 0===r&&(r={});var i=t.hash;void 0===i&&(i="");var o=e||u;return(n||"/")+o(r)+i}function d(t,e){return e===It?t===e:!!e&&(t.path&&e.path?t.path.replace(Mt,"")===e.path.replace(Mt,"")&&t.hash===e.hash&&p(t.query,e.query):!(!t.name||!e.name)&&(t.name===e.name&&t.hash===e.hash&&p(t.query,e.query)&&p(t.params,e.params)))}function p(t,e){void 0===t&&(t={}),void 0===e&&(e={});var n=Object.keys(t),r=Object.keys(e);return n.length===r.length&&n.every(function(n){var r=t[n],i=e[n];return"object"==typeof r&&"object"==typeof i?p(r,i):String(r)===String(i)})}function h(t,e){return 0===t.path.replace(Mt,"/").indexOf(e.path.replace(Mt,"/"))&&(!e.hash||t.hash===e.hash)&&v(t.query,e.query)}function v(t,e){for(var n in e)if(!(n in t))return!1;return!0}function m(t){if(!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey||t.defaultPrevented||void 0!==t.button&&0!==t.button)){if(t.currentTarget&&t.currentTarget.getAttribute){if(/\b_blank\b/i.test(t.currentTarget.getAttribute("target")))return}return t.preventDefault&&t.preventDefault(),!0}}function g(t){if(t)for(var e,n=0;n=0&&(e=t.slice(r),t=t.slice(0,r));var i=t.indexOf("?");return i>=0&&(n=t.slice(i+1),t=t.slice(0,i)),{path:t,query:n,hash:e}}function x(t){return t.replace(/\/\//g,"/")}function w(t,e){for(var n,r=[],i=0,o=0,a="",s=e&&e.delimiter||"/";null!=(n=Gt.exec(t));){var u=n[0],c=n[1],l=n.index;if(a+=t.slice(o,l),o=l+u.length,c)a+=c[1];else{var f=t[o],d=n[2],p=n[3],h=n[4],v=n[5],m=n[6],g=n[7];a&&(r.push(a),a="");var _=null!=d&&null!=f&&f!==d,y="+"===m||"*"===m,b="?"===m||"*"===m,x=n[2]||s,w=h||v;r.push({name:p||i++,prefix:d||"",delimiter:x,optional:b,repeat:y,partial:_,asterisk:!!g,pattern:w?$(w):g?".*":"[^"+A(x)+"]+?"})}}return o-1&&(a.params[f]=n.params[f]);if(u)return a.path=M(u.path,a.params,'named route "'+s+'"'),l(u,a,o)}else if(a.path){a.params={};for(var v=0;v=t.length?n():t[i]?e(t[i],function(){r(i+1)}):r(i+1)};r(0)}function st(e){return function(n,o,a){var s=!1,u=0,c=null;ut(e,function(e,n,o,l){if("function"==typeof e&&void 0===e.cid){s=!0,u++;var f,d=lt(function(t){t.__esModule&&t.default&&(t=t.default),e.resolved="function"==typeof t?t:St.extend(t),o.components[l]=t,--u<=0&&a()}),p=lt(function(e){var n="Failed to resolve async component "+l+": "+e;"production"!==t.env.NODE_ENV&&r(!1,n),c||(c=i(e)?e:new Error(n),a(c))});try{f=e(d,p)}catch(t){p(t)}if(f)if("function"==typeof f.then)f.then(d,p);else{var h=f.component;h&&"function"==typeof h.then&&h.then(d,p)}}}),s||a()}}function ut(t,e){return ct(t.map(function(t){return Object.keys(t.components).map(function(n){return e(t.components[n],t.instances[n],t,n)})}))}function ct(t){return Array.prototype.concat.apply([],t)}function lt(t){var e=!1;return function(){for(var n=[],r=arguments.length;r--;)n[r]=arguments[r];if(!e)return e=!0,t.apply(this,n)}}function ft(t){if(!t)if(Vt){var e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^https?:\/\/[^\/]+/,"")}else t="/";return"/"!==t.charAt(0)&&(t="/"+t),t.replace(/\/$/,"")}function dt(t,e){var n,r=Math.max(t.length,e.length);for(n=0;n=0?e.slice(0,n):e;window.location.replace(r+"#"+t)}function At(t,e){return t.push(e),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function $t(t,e,n){var r="hash"===n?"#"+e:e;return t?x(t+"/"+r):r}var St,jt={name:"router-view",functional:!0,props:{name:{type:String,default:"default"}},render:function(t,e){var n=e.props,r=e.children,i=e.parent,a=e.data;a.routerView=!0;for(var s=i.$createElement,u=n.name,c=i.$route,l=i._routerViewCache||(i._routerViewCache={}),f=0,d=!1;i&&i._routerRoot!==i;)i.$vnode&&i.$vnode.data.routerView&&f++,i._inactive&&(d=!0),i=i.$parent;if(a.routerViewDepth=f,d)return s(l[u],a,r);var p=c.matched[f];if(!p)return l[u]=null,s();var h=l[u]=p.components[u];return a.registerRouteInstance=function(t,e){var n=p.instances[u];(e&&n!==t||!e&&n===t)&&(p.instances[u]=e)},(a.hook||(a.hook={})).prepatch=function(t,e){p.instances[u]=e.componentInstance},a.props=o(c,p.props&&p.props[u]),s(h,a,r)}},Tt=/[!'()*]/g,Nt=function(t){return"%"+t.charCodeAt(0).toString(16)},Rt=/%2C/g,Dt=function(t){return encodeURIComponent(t).replace(Tt,Nt).replace(Rt,",")},Pt=decodeURIComponent,Mt=/\/?$/,It=c(null,{path:"/"}),Ft=[String,Object],Lt=[String,Array],zt={name:"router-link",props:{to:{type:Ft,required:!0},tag:{type:String,default:"a"},exact:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,event:{type:Lt,default:"click"}},render:function(t){var e=this,n=this.$router,r=this.$route,i=n.resolve(this.to,r,this.append),o=i.location,a=i.route,s=i.href,u={},l=n.options.linkActiveClass,f=n.options.linkExactActiveClass,p=null==l?"router-link-active":l,v=null==f?"router-link-exact-active":f,_=null==this.activeClass?p:this.activeClass,y=null==this.exactActiveClass?v:this.exactActiveClass,b=o.path?c(null,o,null,n):a;u[y]=d(r,b),u[_]=this.exact?u[y]:h(r,b);var x=function(t){m(t)&&(e.replace?n.replace(o):n.push(o))},w={click:m};Array.isArray(this.event)?this.event.forEach(function(t){w[t]=x}):w[this.event]=x;var k={class:u};if("a"===this.tag)k.on=w,k.attrs={href:s};else{var C=g(this.$slots.default);if(C){C.isStatic=!1;var E=St.util.extend;(C.data=E({},C.data)).on=w;(C.data.attrs=E({},C.data.attrs)).href=s}else k.on=w}return t(this.tag,k,this.$slots.default)}},Vt="undefined"!=typeof window,Ut=Array.isArray||function(t){return"[object Array]"==Object.prototype.toString.call(t)},qt=P,Ht=w,Wt=k,Bt=O,Yt=D,Gt=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");qt.parse=Ht,qt.compile=Wt,qt.tokensToFunction=Bt,qt.tokensToRegExp=Yt;var Kt=Object.create(null),Xt=Object.create(null),Jt=Vt&&function(){var t=window.navigator.userAgent;return(-1===t.indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone"))&&(window.history&&"pushState"in window.history)}(),Zt=Vt&&window.performance&&window.performance.now?window.performance:Date,Qt=et(),te=function(t,e){this.router=t,this.base=ft(e),this.current=It,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[]};te.prototype.listen=function(t){this.cb=t},te.prototype.onReady=function(t,e){this.ready?t():(this.readyCbs.push(t),e&&this.readyErrorCbs.push(e))},te.prototype.onError=function(t){this.errorCbs.push(t)},te.prototype.transitionTo=function(t,e,n){var r=this,i=this.router.match(t,this.current);this.confirmTransition(i,function(){r.updateRoute(i),e&&e(i),r.ensureURL(),r.ready||(r.ready=!0,r.readyCbs.forEach(function(t){t(i)}))},function(t){n&&n(t),t&&!r.ready&&(r.ready=!0,r.readyErrorCbs.forEach(function(e){e(t)}))})},te.prototype.confirmTransition=function(t,e,n){var o=this,a=this.current,s=function(t){i(t)&&(o.errorCbs.length?o.errorCbs.forEach(function(e){e(t)}):(r(!1,"uncaught error during route navigation:"),console.error(t))),n&&n(t)};if(d(t,a)&&t.matched.length===a.matched.length)return this.ensureURL(),s();var u=dt(this.current.matched,t.matched),c=u.updated,l=u.deactivated,f=u.activated,p=[].concat(vt(l),this.router.beforeHooks,mt(c),f.map(function(t){return t.beforeEnter}),st(f));this.pending=t;var h=function(e,n){if(o.pending!==t)return s();try{e(t,a,function(t){!1===t||i(t)?(o.ensureURL(!0),s(t)):"string"==typeof t||"object"==typeof t&&("string"==typeof t.path||"string"==typeof t.name)?(s(),"object"==typeof t&&t.replace?o.replace(t):o.push(t)):n(t)})}catch(t){s(t)}};at(p,h,function(){var n=[];at(_t(f,n,function(){return o.current===t}).concat(o.router.resolveHooks),h,function(){if(o.pending!==t)return s();o.pending=null,e(t),o.router.app&&o.router.app.$nextTick(function(){n.forEach(function(t){t()})})})})},te.prototype.updateRoute=function(t){var e=this.current;this.current=t,this.cb&&this.cb(t),this.router.afterHooks.forEach(function(n){n&&n(t,e)})};var ee=function(t){function e(e,n){var r=this;t.call(this,e,n);var i=e.options.scrollBehavior;i&&B(),window.addEventListener("popstate",function(t){var n=r.current;r.transitionTo(xt(r.base),function(t){i&&Y(e,t,n,!0)})})}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.go=function(t){window.history.go(t)},e.prototype.push=function(t,e,n){var r=this,i=this,o=i.current;this.transitionTo(t,function(t){it(x(r.base+t.fullPath)),Y(r.router,t,o,!1),e&&e(t)},n)},e.prototype.replace=function(t,e,n){var r=this,i=this,o=i.current;this.transitionTo(t,function(t){ot(x(r.base+t.fullPath)),Y(r.router,t,o,!1),e&&e(t)},n)},e.prototype.ensureURL=function(t){if(xt(this.base)!==this.current.fullPath){var e=x(this.base+this.current.fullPath);t?it(e):ot(e)}},e.prototype.getCurrentLocation=function(){return xt(this.base)},e}(te),ne=function(t){function e(e,n,r){t.call(this,e,n),r&&wt(this.base)||kt()}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.setupListeners=function(){var t=this;window.addEventListener("hashchange",function(){kt()&&t.transitionTo(Ct(),function(t){Ot(t.fullPath)})})},e.prototype.push=function(t,e,n){this.transitionTo(t,function(t){Et(t.fullPath),e&&e(t)},n)},e.prototype.replace=function(t,e,n){this.transitionTo(t,function(t){Ot(t.fullPath),e&&e(t)},n)},e.prototype.go=function(t){window.history.go(t)},e.prototype.ensureURL=function(t){var e=this.current.fullPath;Ct()!==e&&(t?Et(e):Ot(e))},e.prototype.getCurrentLocation=function(){return Ct()},e}(te),re=function(t){function e(e,n){t.call(this,e,n),this.stack=[],this.index=-1}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.push=function(t,e,n){var r=this;this.transitionTo(t,function(t){r.stack=r.stack.slice(0,r.index+1).concat(t),r.index++,e&&e(t)},n)},e.prototype.replace=function(t,e,n){var r=this;this.transitionTo(t,function(t){r.stack=r.stack.slice(0,r.index).concat(t),e&&e(t)},n)},e.prototype.go=function(t){var e=this,n=this.index+t;if(!(n<0||n>=this.stack.length)){var r=this.stack[n];this.confirmTransition(r,function(){e.index=n,e.updateRoute(r)})}},e.prototype.getCurrentLocation=function(){var t=this.stack[this.stack.length-1];return t?t.fullPath:"/"},e.prototype.ensureURL=function(){},e}(te),ie=function(e){void 0===e&&(e={}),this.app=null,this.apps=[],this.options=e,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=q(e.routes||[],this);var r=e.mode||"hash";switch(this.fallback="history"===r&&!Jt&&!1!==e.fallback,this.fallback&&(r="hash"),Vt||(r="abstract"),this.mode=r,r){case"history":this.history=new ee(this,e.base);break;case"hash":this.history=new ne(this,e.base,this.fallback);break;case"abstract":this.history=new re(this,e.base);break;default:"production"!==t.env.NODE_ENV&&n(!1,"invalid mode: "+r)}},oe={currentRoute:{}};ie.prototype.match=function(t,e,n){return this.matcher.match(t,e,n)},oe.currentRoute.get=function(){return this.history&&this.history.current},ie.prototype.init=function(e){var r=this;if("production"!==t.env.NODE_ENV&&n(_.installed,"not installed. Make sure to call `Vue.use(VueRouter)` before creating root instance."),this.apps.push(e),!this.app){this.app=e;var i=this.history;if(i instanceof ee)i.transitionTo(i.getCurrentLocation());else if(i instanceof ne){var o=function(){i.setupListeners()};i.transitionTo(i.getCurrentLocation(),o,o)}i.listen(function(t){r.apps.forEach(function(e){e._route=t})})}},ie.prototype.beforeEach=function(t){return At(this.beforeHooks,t)},ie.prototype.beforeResolve=function(t){return At(this.resolveHooks,t)},ie.prototype.afterEach=function(t){return At(this.afterHooks,t)},ie.prototype.onReady=function(t,e){this.history.onReady(t,e)},ie.prototype.onError=function(t){this.history.onError(t)},ie.prototype.push=function(t,e,n){this.history.push(t,e,n)},ie.prototype.replace=function(t,e,n){this.history.replace(t,e,n)},ie.prototype.go=function(t){this.history.go(t)},ie.prototype.back=function(){this.go(-1)},ie.prototype.forward=function(){this.go(1)},ie.prototype.getMatchedComponents=function(t){var e=t?t.matched?t:this.resolve(t).route:this.currentRoute;return e?[].concat.apply([],e.matched.map(function(t){return Object.keys(t.components).map(function(e){return t.components[e]})})):[]},ie.prototype.resolve=function(t,e,n){var r=V(t,e||this.history.current,n,this),i=this.match(r,e),o=i.redirectedFrom||i.fullPath;return{location:r,route:i,href:$t(this.history.base,o,this.mode),normalizedTo:r,resolved:i}},ie.prototype.addRoutes=function(t){this.matcher.addRoutes(t),this.history.current!==It&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(ie.prototype,oe),ie.install=_,ie.version="2.7.0",Vt&&window.Vue&&window.Vue.use(ie),e.a=ie}).call(e,n(9))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(130),i=n.n(r),o=n(129),a=n.n(o),s=n(131),u=n.n(s);e.default={name:"app",components:{top:i.a,bottom:a.a,modal:u.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(125),i=n.n(r),o=n(20),a=n.n(o),s=n(18),u=n.n(s),c=n(3),l=n.n(c),f=n(2);e.default={created:function(){var t=this;n.i(f.a)("configPart/performanceAnalyzer",function(e,n){t.performanceAnalyzer=toml.parse(n.part),t.performanceAnalyzer.enabled=!0})},data:function(){return{dataset:{},strat:{},paperTrader:{},performanceAnalyzer:{}}},components:{stratPicker:a.a,datasetPicker:i.a,paperTrader:u.a},computed:{market:function(){return this.dataset.exchange?{exchange:this.dataset.exchange,currency:this.dataset.currency,asset:this.dataset.asset}:{}},range:function(){return this.dataset.exchange?{from:this.dataset.from,to:this.dataset.to}:{}},config:function(){var t={};return Object.assign(t,{watch:this.market},{paperTrader:this.paperTrader},this.strat,{backtest:{daterange:this.range}},{performanceAnalyzer:this.performanceAnalyzer}),t.valid=this.validConfig(t),t}},methods:{validConfig:function(t){if(!t.backtest)return!1;if(!t.backtest.daterange)return!1;if(l.a.isEmpty(t.backtest.daterange))return!1;if(!t.watch)return!1;if(!t.tradingAdvisor)return!1;var e=t.tradingAdvisor.method;if(l.a.isEmpty(t[e]))return!1;if(t.tradingAdvisor){if(l.a.isNaN(t.tradingAdvisor.candleSize))return!1;if(0==t.tradingAdvisor.candleSize)return!1}return!0},updateDataset:function(t){this.dataset=t,this.$emit("config",this.config)},updateStrat:function(t){this.strat=t,this.$emit("config",this.config)},updatePaperTrader:function(t){this.paperTrader=t,this.paperTrader.enabled=!0,this.$emit("config",this.config)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(119),i=n.n(r),o=n(120),a=n.n(o),s=n(2),u=n(5),c=n.n(u);e.default={data:function(){return{backtestable:!1,backtestState:"idle",backtestResult:!1,config:!1}},methods:{check:function(t){if(this.config=t,!t.valid)return this.backtestable=!1;this.backtestable=!0},run:function(){var t=this;this.backtestState="fetching";var e={gekkoConfig:this.config,data:{candleProps:["close","start"],indicatorResults:!0,report:!0,roundtrips:!0,trades:!0}};n.i(s.b)("backtest",e,function(e,n){t.backtestState="fetched",t.backtestResult=n})}},components:{configBuilder:i.a,result:a.a,spinner:c.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(68),i=n(69);e.default={props:["data","height"],data:function(){return{isClicked:!1}},watch:{data:function(){this.render()}},created:function(){setTimeout(this.render,100)},beforeDestroy:function(){this.remove()},methods:{click:function(){this.isClicked=!0},render:function(){this.remove(),_.size(this.data.candles)<4?n.i(i.a)("Not enough data to spawn chart"):n.i(r.a)(this.data.candles,this.data.trades,this.height)},remove:function(){d3.select("#chart").html("")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(121),i=n.n(r),o=n(10),a=n.n(o),s=n(16),u=n.n(s);e.default={props:["result"],data:function(){return{}},methods:{},components:{roundtripTable:u.a,resultSummary:i.a,chart:a.a}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["roundtrips"],data:function(){return{}},methods:{diff:function(t){return moment.duration(t).humanize()},humanizeDuration:function(t){return window.humanizeDuration(t)},fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},round:function(t){return(+t).toFixed(3)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(21),i=n.n(r);e.default={props:["report"],components:{paperTradeSummary:i.a},methods:{round:function(t){return(+t).toFixed(5)}},computed:{profitClass:function(){return this.report.relativeProfit>0?"profit":"loss"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(126),i=n.n(r),o=n(3),a=(n.n(o),n(2));e.default={data:function(){return{exchange:!1,credentials:{}}},components:{exchangePicker:i.a},computed:{apiKeySets:function(){return this.$store.state.apiKeys},exchanges:function(){return this.$store.state.exchanges},requires:function(){return this.exchanges&&this.exchange?this.exchanges[this.exchange].requires:[]},config:function(){return{exchange:this.exchange,values:this.credentials}}},watch:{credentials:function(){this.emitConfig()}},methods:{updateExchange:function(t){this.credentials={},this.exchange=t,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)},upload:function(){var t=this,e=this.config.exchange;this.exchanges&&this.apiKeySets.includes(e)&&!confirm("You already have API keys for "+e+" defined, do you want to overwrite them?")||n.i(a.b)("addApiKey",this.config,function(e,n){if(e)return alert(e);t.credentials={}})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(122),i=n.n(r),o=n(2);e.default={components:{apiConfigBuilder:i.a},data:function(){return{addApiToggle:!1}},methods:{openAddApi:function(){this.addApiToggle=!0},removeApiKey:function(t){confirm("Are you sure you want to delete these API keys?")&&n.i(o.b)("removeApiKey",{exchange:t},function(t,e){if(t)return alert(t)})}},computed:{apiKeySets:function(){return this.$store.state.apiKeys}},watch:{apiKeySets:function(){this.addApiToggle=!1}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(5),i=n.n(r),o=n(8),a=n(13),s=n.i(o.a)("\n\n## Local data\n\nGekko needs local market data in order to backtest strategies. The local\ndata can also be used in a warmup period when running a strategy against a\nlive market.\n\n");e.default={mixins:[a.a],components:{spinner:i.a},data:function(){return{intro:s,viewUnscannable:!1}},methods:{toggleUnscannable:function(){this.viewUnscannable=!0},humanizeDuration:function(t){return window.humanizeDuration(t)},fmt:function(t){return t.format("YYYY-MM-DD HH:mm")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),i=n.n(r),o=n(11),a=n.n(o),s=n(3);n.n(s);e.default={data:function(){return{market:{},range:{}}},components:{marketPicker:i.a,rangeCreator:a.a},computed:{config:function(){var t={};return Object.assign(t,this.market,{importer:{daterange:this.range}},{candleWriter:{enabled:!0}}),t}},methods:{updateMarketConfig:function(t){this.market=t,this.emitConfig()},updateRange:function(t){this.range=t,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2),i=n(5),o=n.n(i),a=n(123),s=n.n(a),u=n(8),c=n.i(u.a)("\n\n## Import data\n\nThe importer can download historical market data directly from the exchange.\n\n");e.default={components:{importConfigBuilder:s.a,spinner:o.a},data:function(){return{intro:c,config:{}}},computed:{imports:function(){return this.$store.state.imports}},methods:{daysApart:function(t){var e=moment(t.to),n=moment(t.from);return e.diff(n,"days")},updateConfig:function(t){this.config=t},run:function(){var t=this;if(this.daysApart(this.config.importer.daterange)<1)return alert("You can only import at least one day of data..");n.i(r.b)("import",this.config,function(e,n){if(e)return alert(e);t.$store.commit("addImport",n),t.$router.push({path:"/data/importer/import/"+n.id})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(128),a=n.n(o),s=n(5),u=n.n(s);e.default={components:{progressBar:a.a,spinner:u.a},computed:{data:function(){return i.a.find(this.$store.state.imports,{id:this.$route.params.id})},initialized:function(){if(this.data&&this.latest.isValid())return!0},latest:function(){if(this.data)return this.mom(this.data.latest)},fromEndMs:function(){if(this.data)return this.to.diff(this.latest)},fromEnd:function(){return this.latest?humanizeDuration(this.fromEndMs):"LOADING"},from:function(){if(this.data)return this.mom(this.data.from)},to:function(){if(this.data)return this.mom(this.data.to)},timespan:function(){if(this.data)return this.to.diff(this.from)},progress:function(){if(this.data){return 100*(this.timespan-this.fromEndMs)/this.timespan}}},methods:{fmt:function(t){return t.format("YYYY-MM-DD HH:mm:ss")},mom:function(t){return moment.utc(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),i=n.n(r),o=n(127),a=n.n(o),s=n(20),u=n.n(s),c=n(18),l=n.n(c),f=n(2),d=n(3),p=n.n(d);e.default={created:function(){var t=this;n.i(f.a)("configPart/candleWriter",function(e,n){t.candleWriter=toml.parse(n.part)}),n.i(f.a)("configPart/performanceAnalyzer",function(e,n){t.performanceAnalyzer=toml.parse(n.part),t.performanceAnalyzer.enabled=!0})},data:function(){return{market:{},range:{},type:"",strat:{},paperTrader:{},candleWriter:{},performanceAnalyzer:{}}},components:{marketPicker:i.a,typePicker:a.a,stratPicker:u.a,paperTrader:l.a},computed:{isTradebot:function(){return"tradebot"===this.type},config:function(){var t={};return Object.assign(t,this.market,this.strat,{paperTrader:this.paperTrader},{candleWriter:this.candleWriter},{type:this.type},{performanceAnalyzer:this.performanceAnalyzer}),this.isTradebot&&(delete t.paperTrader,t.trader={enabled:!0}),t.valid=this.validConfig(t),t}},methods:{validConfig:function(t){if("market watcher"===t.type)return!0;if(!t.tradingAdvisor)return!1;if(p.a.isNaN(t.tradingAdvisor.candleSize))return!1;if(0==t.tradingAdvisor.candleSize)return!1;var e=t.tradingAdvisor.method;return!p.a.isEmpty(t[e])},updateMarketConfig:function(t){this.market=t,this.emitConfig()},updateType:function(t){this.type=t,this.emitConfig()},updateStrat:function(t){this.strat=t,this.emitConfig()},updatePaperTrader:function(t){this.paperTrader=t,this.paperTrader.enabled=!0,this.emitConfig()},emitConfig:function(){this.$emit("config",this.config)}}}},function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(e,"__esModule",{value:!0});var i,o=n(8),a=n.i(o.a)("\n\n## Live Gekko\n\nRun your strategy against the live market!\n\n");e.default=(i={data:function(){return{text:a}},created:function(){var t=this;this.timer=setInterval(function(){t.now=moment()},1e3)},destroyed:function(){clearTimeout(this.timer)}},r(i,"data",function(){return{text:a,timer:!1,now:moment()}}),r(i,"computed",{stratrunners:function(){return this.$store.state.stratrunners},watchers:function(){return this.$store.state.watchers}}),r(i,"methods",{humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},round:function(t){return(+t).toFixed(3)},timespan:function(t,e){return this.humanizeDuration(this.moment(t).diff(this.moment(e)))}}),i)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(4),a=n(2),s=n(124),u=n.n(s);e.default={components:{gekkoConfigBuilder:u.a},data:function(){return{pendingStratrunner:!1,config:{}}},computed:{watchers:function(){return this.$store.state.watchers},stratrunners:function(){return this.$store.state.stratrunners},watchConfig:function(){var t=i.a.pick(this.config,"watch","candleWriter"),e=o.a.util.extend({},t);return e.type="market watcher",e.mode="realtime",e},requiredHistoricalData:function(){if(this.config.tradingAdvisor&&this.config.valid){var t=this.config.tradingAdvisor;return t.candleSize*t.historySize}},gekkoConfig:function(){var t;if(this.existingMarketWatcher){if(this.requiredHistoricalData){var e=moment().utc().startOf("minute").subtract(this.requiredHistoricalData,"minutes").unix(),n=moment.utc(this.existingMarketWatcher.firstCandle.start).unix();t=moment.unix(Math.max(e,n)).utc().format()}else t=moment().utc().startOf("minute").format();return o.a.util.extend({market:{type:"leech",from:t},mode:"realtime"},this.config)}},existingMarketWatcher:function(){var t=o.a.util.extend({},this.watchConfig.watch);return i.a.find(this.watchers,{watch:t})},exchange:function(){return this.watchConfig.watch.exchange},existingTradebot:function(){return i.a.find(this.stratrunners.filter(function(t){return"tradebot"===t.trader}),{watch:{exchange:this.exchange}})},availableApiKeys:function(){return this.$store.state.apiKeys}},watch:{existingMarketWatcher:function(t,e){var n=this;this.pendingStratrunner&&t&&t.firstCandle&&t.lastCandle&&(this.pendingStratrunner=!1,this.startGekko(function(t,e){n.$router.push({path:"/live-gekkos/stratrunner/"+e.id})}))}},methods:{updateConfig:function(t){this.config=t},start:function(){var t=this;if("tradebot"===this.config.type){if(this.existingTradebot){var e="You already have a tradebot running on this exchange";return e+=", you can only run one tradebot per exchange.",alert(e)}if(!this.availableApiKeys.includes(this.exchange))return alert("Please first configure API keys for this exchange in the config page.")}"market watcher"===this.config.type?this.existingMarketWatcher?(alert("This market is already being watched, redirecting you now..."),this.$router.push({path:"/live-gekkos/watcher/"+this.existingMarketWatcher.id})):this.startWatcher(function(e,n){t.$router.push({path:"/live-gekkos/watcher/"+n.id})}):this.existingMarketWatcher?this.startGekko(this.routeToGekko):this.startWatcher(function(e,n){t.pendingStratrunner=!0})},routeToGekko:function(t,e){if(t||e.error)return console.error(t,e.error);this.$router.push({path:"/live-gekkos/stratrunner/"+e.id})},startWatcher:function(t){n.i(a.b)("startGekko",this.watchConfig,t)},startGekko:function(t){n.i(a.b)("startGekko",this.gekkoConfig,t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(4),i=n(3),o=n.n(i),a=n(2),s=n(5),u=n.n(s),c=n(10),l=n.n(c),f=n(16),d=n.n(f),p=n(21),h=n.n(p);e.default={created:function(){this.isLoading||this.getCandles()},components:{spinner:u.a,chart:l.a,paperTradeSummary:h.a,roundtrips:d.a},data:function(){return{candleFetch:"idle",candles:!1}},computed:{stratrunners:function(){return this.$store.state.stratrunners},data:function(){return o.a.find(this.stratrunners,{id:this.$route.params.id})},chartData:function(){return{candles:this.candles,trades:this.trades}},trades:function(){return this.data?this.data.trades:[]},report:function(){if(this.data)return this.data.report},stratName:function(){if(this.data)return this.data.strat.tradingAdvisor.method},stratParams:function(){if(!this.data)return"";var t=r.a.util.extend({},this.data.strat.params);return delete t.__empty,o.a.isEmpty(t)?"No parameters":JSON.stringify(t,null,4)},isLoading:function(){return!this.data||(!o.a.isObject(this.data.firstCandle)||!o.a.isObject(this.data.lastCandle))},watchers:function(){return this.$store.state.watchers},watcher:function(){var t=r.a.util.extend({},this.data.watch);return o.a.find(this.watchers,{watch:t})}},watch:{"data.lastCandle.start":function(){this.candleFetch="dirty"},data:function(t,e){this.isLoading||"fetched"!==this.candleFetch&&this.getCandles()}},methods:{round:function(t){return(+t).toFixed(5)},humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},getCandles:function(){var t=this;this.candleFetch="fetching";var e=this.data.lastCandle.start,r=this.data.firstCandle.start,i=this.data.strat.tradingAdvisor.candleSize,s={watch:this.data.watch,daterange:{to:e,from:r},candleSize:i};n.i(a.b)("getCandles",s,function(e,n){t.candleFetch="fetched",n&&!n.error&&o.a.isArray(n)||console.log(n),t.candles=n.map(function(t){return t.start=moment.unix(t.start).utc().format(),t})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2),i=n(3),o=n.n(i),a=n(5),s=n.n(a),u=(n(4),n(10)),c=n.n(u);e.default={created:function(){this.isLoading||this.getCandles()},components:{spinner:s.a,chart:c.a},data:function(){return{candleFetch:"idle",candles:[]}},computed:{watchers:function(){return this.$store.state.watchers},data:function(){return o.a.find(this.watchers,{id:this.$route.params.id})},chartData:function(){return{candles:this.candles,trades:[]}},isLoading:function(){return!this.data||(!o.a.isObject(this.data.firstCandle)||!o.a.isObject(this.data.lastCandle))}},watch:{"data.lastCandle.start":function(){this.candleFetch="dirty"},data:function(t,e){t&&t.firstCandle&&t.lastCandle&&"fetched"!==this.candleFetch&&this.getCandles()}},methods:{humanizeDuration:function(t){return window.humanizeDuration(t)},moment:function(t){function e(e){return t.apply(this,arguments)}return e.toString=function(){return t.toString()},e}(function(t){return moment.utc(t)}),fmt:function(t){return moment.utc(t).format("YYYY-MM-DD HH:mm")},getCandles:function(){var t=this;this.candleFetch="fetching";var e=moment.utc(this.data.lastCandle.start).unix(),i=Math.max(moment.utc(this.data.firstCandle.start).unix(),moment.utc(e).subtract(7,"days").unix()),o=e-i,a=60;o<86400&&(a=o<43200?1:5),i=moment.unix(i).utc().format(),e=moment.unix(e).utc().format();var s={watch:this.data.watch,daterange:{to:e,from:i},candleSize:a};n.i(r.b)("getCandles",s,function(e,n){t.candleFetch="fetched",t.candles=n.map(function(t){return t.start=moment.unix(t.start).utc().format(),t})})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(4)),o=(n(2),n(5)),a=n.n(o),s=n(13);e.default={components:{spinner:a.a},data:function(){return{setIndex:-1,customTo:!1,customFrom:!1,rangeVisible:!1,set:!1}},mixins:[s.a],methods:{humanizeDuration:function(t){return window.humanizeDuration(t,{largest:4})},fmt:function(t){return t.utc().format("YYYY-MM-DD HH:mm")},openRange:function(){if(-1===this.setIndex)return alert("Select a dataset to adjust range");this.updateCustomRange(),this.rangeVisible=!0},updateCustomRange:function(){this.customTo=this.fmt(this.set.to),this.customFrom=this.fmt(this.set.from)},emitSet:function(t){if(t){var e=void 0;this.customTo?(e=i.a.util.extend({},t),e.to=moment.utc(this.customTo,"YYYY-MM-DD HH:mm").format(),e.from=moment.utc(this.customFrom,"YYYY-MM-DD HH:mm").format()):e=t,this.$emit("dataset",e)}}},watch:{setIndex:function(){this.set=this.datasets[this.setIndex],this.updateCustomRange(),this.emitSet(this.set)},customTo:function(){this.emitSet(this.set)},customFrom:function(){this.emitSet(this.set)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(19),a=(n.n(o),n(11));n.n(a),n(2);e.default={props:["onlyTradable","onlyImportable"],data:function(){return{exchange:"poloniex"}},created:function(){this.emitExchange()},computed:{exchanges:function(){var t=Object.assign({},this.$store.state.exchanges);return!i.a.isEmpty(t)&&(this.onlyTradable&&i.a.each(t,function(e,n){e.tradable||delete t[n]}),this.onlyImportable&&i.a.each(t,function(e,n){e.importable||delete t[n]}),t)}},watch:{exchanges:function(){this.emitExchange()},exchange:function(){this.emitExchange()}},methods:{emitExchange:function(){this.$emit("exchange",this.exchange)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(19),a=(n.n(o),n(11));n.n(a),n(2);e.default={props:["onlyTradable","onlyImportable"],data:function(){return{exchange:"poloniex",currency:"USDT",asset:"BTC"}},created:function(){this.emitConfig()},computed:{exchanges:function(){var t=Object.assign({},this.$store.state.exchanges);return!i.a.isEmpty(t)&&(this.onlyTradable&&i.a.each(t,function(e,n){e.tradable||delete t[n]}),this.onlyImportable&&i.a.each(t,function(e,n){e.importable||delete t[n]}),t)},markets:function(){return this.exchanges?this.exchanges[this.exchange]:null},assets:function(){return this.exchanges?this.exchanges[this.exchange].markets[this.currency]:null},currencies:function(){return this.exchanges?i.a.keys(this.exchanges[this.exchange].markets):null},watchConfig:function(){return{watch:{exchange:this.exchange,currency:this.currency,asset:this.asset}}}},watch:{currency:function(){this.emitConfig()},asset:function(){this.emitConfig()},market:function(){this.emitConfig()},exchanges:function(){this.emitConfig()},exchange:function(){this.emitConfig()}},methods:{emitConfig:function(){this.$emit("market",this.watchConfig)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(2));e.default={created:function(){var t=this;n.i(i.a)("configPart/paperTrader",function(e,n){t.rawPaperTraderParams=n.part})},data:function(){return{rawPaperTraderParams:"",rawPaperTraderParamsError:!1,paperTraderParams:{},toggle:"closed"}},watch:{rawPaperTraderParams:function(){this.emitConfig()}},methods:{switchToggle:function(){"open"===this.toggle?this.toggle="closed":this.toggle="open"},emitConfig:function(){this.parseParams(),this.$emit("settings",this.paperTraderParams)},parseParams:function(){try{this.paperTraderParams=toml.parse(this.rawPaperTraderParams),this.paperTraderParams.reportRoundtrips=!0,this.rawPaperTraderParamsError=!1}catch(t){this.rawPaperTraderParamsError=t,this.paperTraderParams={}}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3);n.n(r),n(2);e.default={data:function(){return{from:"",to:""}},created:function(){var t=moment().startOf("minute"),e=t.clone().subtract(3,"months");this.to=this.fmt(t),this.from=this.fmt(e),this.emitRange()},methods:{fmtTs:function(t){return moment.unix(t).utc()},fmt:function(t){return t.utc().format("YYYY-MM-DD HH:mm")},emitRange:function(){this.$emit("range",{from:this.fmtTs(this.from),to:this.fmtTs(this.to)})},emitManualEntry:function(){if(this.from.length<"4"||this.from.length<"4")return this.$emit("range",{});var t=moment.utc(this.from),e=moment.utc(this.to);t.isValid()&&e.isValid()?this.$emit("range",{from:this.fmt(t),to:this.fmt(e)}):this.$emit("range",{})}},watch:{from:function(){this.emitManualEntry()},to:function(){this.emitManualEntry()},config:function(){this.scanned=!1},tab:function(){this.scanned=!1,this.$emit("range",{})},selectedRangeIndex:function(){var t=this.ranges[this.selectedRangeIndex];t&&this.emitRange(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=(n.n(r),n(2));e.default={props:["config"],data:function(){return{scanned:!1,ranges:[],selectedRangeIndex:-1,tab:"scan",from:"",to:""}},methods:{scan:function(){var t=this;this.scanned="fetching",this.selectedRangeIndex=-1,n.i(i.b)("scan",this.config,function(e,n){t.scanned=!0,t.ranges=n,t.selectedRangeIndex=0})},printRange:function(t){var e=function(t){return t.format("YYYY-MM-DD HH:mm")},n=moment.unix(t.from),r=moment.unix(t.to),i=moment.duration(r.diff(n)).humanize();return e(n)+" to "+e(r)+" ("+i+")"},fmtTs:function(t){return moment.unix(t).utc()},fmt:function(t){return t.utc().format()},emitRange:function(t){this.$emit("range",{from:this.fmtTs(t.from),to:this.fmtTs(t.to)})},emitManualEntry:function(){if(this.from.length<"4"||this.from.length<"4")return this.$emit("range",{});var t=moment.utc(this.from),e=moment.utc(this.to);t.isValid()&&e.isValid()?this.$emit("range",{from:this.fmt(t),to:this.fmt(e)}):this.$emit("range",{})},reset:function(){this.scanned=!1,this.$emit("range",{})}},watch:{from:function(){this.emitManualEntry()},to:function(){this.emitManualEntry()},config:function(){this.reset()},tab:function(){this.reset()},selectedRangeIndex:function(){var t=this.ranges[this.selectedRangeIndex];t&&this.emitRange(t)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),i=n.n(r),o=n(2);e.default={data:function(){return{strategies:[],candleSizeUnit:"hours",rawCandleSize:1,strategy:"MACD",historySize:10,rawStratParams:"",rawStratParamsError:!1,emptyStrat:!1,stratParams:{}}},created:function(){var t=this;n.i(o.a)("strategies",function(e,n){t.strategies=n,i.a.each(t.strategies,function(t){t.empty=""===t.params}),t.rawStratParams=i.a.find(t.strategies,{name:t.strategy}).params,t.emptyStrat=i.a.find(t.strategies,{name:t.strategy}).empty,t.emitConfig()})},watch:{strategy:function(t){t=i.a.find(this.strategies,{name:t}),this.rawStratParams=t.params,this.emptyStrat=t.empty,this.emitConfig()},candleSize:function(){this.emitConfig()},historySize:function(){this.emitConfig()},rawStratParams:function(){this.emitConfig()}},computed:{candleSize:function(){return"minutes"===this.candleSizeUnit?this.rawCandleSize:"hours"===this.candleSizeUnit?60*this.rawCandleSize:"days"===this.candleSizeUnit?60*this.rawCandleSize*24:void 0},singularCandleSizeUnit:function(){return this.candleSizeUnit.slice(0,-1)},config:function(){var t={tradingAdvisor:{enabled:!0,method:this.strategy,candleSize:+this.candleSize,historySize:+this.historySize}};return this.emptyStrat?t[this.strategy]={__empty:!0}:t[this.strategy]=this.stratParams,t}},methods:{humanizeDuration:function(t){return window.humanizeDuration(t)},emitConfig:function(){this.parseParams(),this.$emit("stratConfig",this.config)},parseParams:function(){try{this.stratParams=toml.parse(this.rawStratParams),this.rawStratParamsError=!1}catch(t){this.rawStratParamsError=t,this.stratParams={}}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={created:function(){this.emitType()},data:function(){return{types:["paper trader","market watcher","tradebot"],selectedTypeIndex:0}},methods:{emitType:function(){this.$emit("type",this.type)}},watch:{type:function(){this.emitType()}},computed:{type:function(){return this.types[this.selectedTypeIndex]}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["report"],methods:{round2:function(t){return(+t).toFixed(2)},round:function(t){return(+t).toFixed(5)}},computed:{profitClass:function(){return this.report.relativeProfit>0?"profit":"loss"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:["progress"],methods:{round:function(t){return(+t).toFixed(2)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(112),i=n(113);e.default={data:function(){return{version:{gekko:r.version,ui:i.version}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8),i=n.i(r.a)("\n\n## Gekko\n\nGekko is a Bitcoin trading bot and backtesting platform that\nconnects to popular Bitcoin exchanges. It is written in javascript\nand runs on nodejs.\n\n[Find out more](https://gekko.wizb.it/).\n\n*Gekko is 100% open source and free, if you paid for this you have been scammed.*\n\n");e.default={data:function(){return{left:i}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8),i={disconnected:n.i(r.a)("\n\n## Disconnected\n\nSomething happened to either Gekko or the connection.\nPlease check the terminal where Gekko is running or\nyour network connection.\n\n ")};e.default={computed:{active:function(){return!this.$store.state.warnings.connected},content:function(){return this.$store.state.warnings.connected?"":i.disconnected}}}},function(t,e,n){"use strict";var r=n(3),i=n.n(r),o=function(){function t(t,e){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e,n){function r(){if(!d3.event.sourceEvent||"zoom"!==d3.event.sourceEvent.type){var t=d3.event.selection||y.range();_.domain(t.map(y.invert,y)),a(_.domain()),d.select(".axis--y").call(C),T.attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}),S.select(".line").attr("d",A),S.select(".axis--x").call(w),d.select(".zoom").call(O.transform,d3.zoomIdentity.scale(m/(t[1]-t[0])).translate(-t[0],0))}}function a(t){var e=o(t,2),n=e[0],r=e[1],a=i.a.sortedIndex(l,n),s=i.a.sortedIndex(l,r),u=f.slice(a,s);b.domain([.9995*d3.min(u),1.0005*d3.max(u)])}function s(){if(!d3.event.sourceEvent||"brush"!==d3.event.sourceEvent.type){var t=d3.event.transform;a(t.rescaleX(y).domain()),d.select(".axis--y").call(C),_.domain(t.rescaleX(y).domain()),S.select(".line").attr("d",A),T.attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}),S.select(".axis--x").call(w),j.select(".brush").call(E.move,_.range().map(t.invertX,t))}}var u=e.map(function(t){return{price:t.price,date:moment.utc(t.date).toDate(),action:t.action}}),c=t.map(function(t){return{price:t.close,date:moment.utc(t.start).toDate()}}),l=c.map(function(t){return+t.date}),f=c.map(function(t){return+t.price}),d=d3.select("#chart");d.attr("width",window.innerWidth-20);var p={top:20,right:20,bottom:110,left:40},h=n-p.top-p.bottom,v={top:n-70,right:20,bottom:30,left:40},m=+d.attr("width")-p.left-p.right,g=n-v.top-v.bottom,_=d3.scaleUtc().range([0,m]),y=d3.scaleUtc().range([0,m]),b=d3.scaleLinear().range([h,0]),x=d3.scaleLinear().range([g,0]),w=d3.axisBottom(_),k=d3.axisBottom(y),C=d3.axisLeft(b).ticks(n/50),E=d3.brushX().extent([[0,0],[m,g]]).on("brush end",r),O=d3.zoom().scaleExtent([1,100]).translateExtent([[0,0],[m,h]]).extent([[0,0],[m,h]]).on("zoom",s),A=d3.line().x(function(t){return _(t.date)}).y(function(t){return b(t.price)}),$=d3.line().x(function(t){return y(t.date)}).y(function(t){return x(t.price)});d.append("defs").append("clipPath").attr("id","clip").append("rect").attr("width",m).attr("height",h);var S=d.append("g").attr("class","focus").attr("transform","translate("+p.left+","+p.top+")"),j=d.append("g").attr("class","context").attr("transform","translate("+v.left+","+v.top+")");_.domain(d3.extent(c,function(t){return t.date})),b.domain([.99*d3.min(f),1.01*d3.max(f)]),y.domain(_.domain()),x.domain(b.domain()),S.append("path").datum(c).attr("class","line price").attr("d",A),S.append("g").attr("class","axis axis--x").attr("transform","translate(0,"+h+")").call(w),S.append("g").attr("class","axis axis--y").call(C),j.append("path").datum(c).attr("class","line").attr("d",$),j.append("g").attr("class","axis axis--x").attr("transform","translate(0,"+g+")").call(k);var T=d.append("g").attr("transform","translate("+p.left+","+p.top+")").selectAll("circle").data(u).enter().append("circle").attr("class",function(t){return t.action}).attr("cx",function(t){return _(t.date)}).attr("cy",function(t){return b(t.price)}).attr("r",5);j.append("g").selectAll("circle").data(u).enter().append("circle").attr("class",function(t){return t.action}).attr("cx",function(t){return y(t.date)}).attr("cy",function(t){return x(t.price)}).attr("r",3);j.append("g").attr("class","brush").call(E).call(E.move,_.range()),d.append("rect").attr("class","zoom").attr("width",m).attr("height",h).attr("transform","translate("+p.left+","+p.top+")").call(O)}},function(t,e,n){"use strict";n.d(e,"a",function(){return r});var r=function(t){d3.select("#chart").append("text").attr("class","message").attr("x",150).attr("y",150).text(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t){var e=n(4),r=n(23),i=n.n(r),o=n(34),a=n(7),s=n(24),u=n.n(s),c=n(33),l=n.n(c),f=n(26),d=n.n(f),p=n(27),h=n.n(p),v=n(28),m=n.n(v),g=n(25),_=n.n(g),y=n(29),b=n.n(y),x=n(30),w=n.n(x),k=n(31),C=n.n(k),E=n(32),O=n.n(E),A=n(6);e.a.use(o.a);var $=new o.a({mode:"hash",base:t,routes:[{path:"/",redirect:"/home"},{path:"/home",component:l.a},{path:"/backtest",component:u.a},{path:"/config",component:_.a},{path:"/data",component:d.a},{path:"/data/importer",component:h.a},{path:"/data/importer/import/:id",component:m.a},{path:"/live-gekkos",component:b.a},{path:"/live-gekkos/new",component:w.a},{path:"/live-gekkos/stratrunner/:id",component:C.a},{path:"/live-gekkos/watcher/:id",component:O.a}]});n.i(A.a)(),new e.a({router:$,store:a.a,el:"#app",render:function(t){return t(i.a)}})}.call(e,"/")},function(t,e,n){"use strict";var r=(n(4),n(22),n(75)),i=n(81),o=n(79),a=n(77),s=n(73);e.a=function(){n.i(r.a)(),n.i(i.a)(),n.i(o.a)(),n.i(a.a)(),n.i(s.a)()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"syncApiKeys",function(){return i}),n.d(e,"syncExchanges",function(){return o});var r=n(4),i=function(t,e){return r.a.set(t,"apiKeys",e),t},o=function(t,e){return r.a.set(t,"exchanges",e),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=function(){function t(t,e){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(t){var e=t,n={};return e.forEach(function(t){n[t.slug]=n[t.slug]||{markets:{}},t.markets.forEach(function(e){var r=a(e.pair,2),i=r[0],o=r[1];n[t.slug].markets[i]=n[t.slug].markets[i]||[],n[t.slug].markets[i].push(o)}),n[t.slug].importable=!!t.providesFullHistory,n[t.slug].tradable=!!t.tradable,n[t.slug].requires=t.requires}),n},u=function(){n.i(r.a)("apiKeys",function(t,e){i.a.commit("syncApiKeys",e)}),n.i(r.a)("exchanges",function(t,e){i.a.commit("syncExchanges",s(e))})},c=function(){o.b.$on("apiKeys",function(t){i.a.commit("syncApiKeys",t.exchanges)})};e.a=function(){u(),c()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addImport",function(){return i}),n.d(e,"syncImports",function(){return o}),n.d(e,"updateImport",function(){return a});var r=n(4),i=function(t,e){return t.imports.push(e),t},o=function(t,e){return t.imports=e,t},a=function(t,e){var n=t.imports.findIndex(function(t){return t.id===e.import_id}),i=t.imports[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.imports,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=function(){n.i(r.a)("imports",function(t,e){i.a.commit("syncImports",e)})},s=function(){o.b.$on("import_update",function(t){i.a.commit("updateImport",t)})};e.a=function(){a(),s()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"setGlobalWarning",function(){return i});var r=(n(4),n(3)),i=(n.n(r),function(t,e){return t.warnings[e.key]=e.value,t})},function(t,e,n){"use strict";var r=n(7),i=n(6),o=function(){i.b.$on("WS_STATUS_CHANGE",function(t){return r.a.commit("setGlobalWarning",{key:"connected",value:t.connected})})};e.a=function(){o()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addStratrunner",function(){return i}),n.d(e,"syncStratrunners",function(){return o}),n.d(e,"updateStratrunner",function(){return a}),n.d(e,"addTradeToStratrunner",function(){return s}),n.d(e,"addRoundtripToStratrunner",function(){return u});var r=n(4),i=function(t,e){return t.stratrunners.push(e),t},o=function(t,e){return t.stratrunners=e,t},a=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.stratrunners,n,o),t},s=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend({},i);return o.trades.push(e.trade),r.a.set(t.stratrunners,n,o),t},u=function(t,e){var n=t.stratrunners.findIndex(function(t){return t.id===e.gekko_id}),i=t.stratrunners[n];if(!i)return t;var o=r.a.util.extend({},i);return o.roundtrips.push(e.roundtrip),r.a.set(t.stratrunners,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=n(3),s=n.n(a),u=function(){n.i(r.a)("gekkos",function(t,e){var n=s.a.filter(e,{type:"leech"});i.a.commit("syncStratrunners",n)})},c=function(){o.b.$on("new_gekko",function(t){"leech"===t.gekko.type&&i.a.commit("addStratrunner",t.gekko)});var t=function(t){i.a.commit("updateStratrunner",t)},e=function(t){i.a.commit("addTradeToStratrunner",t)},n=function(t){i.a.commit("addRoundtripToStratrunner",t)};o.b.$on("report",t),o.b.$on("trade",e),o.b.$on("update",t),o.b.$on("startAt",t),o.b.$on("lastCandle",t),o.b.$on("firstCandle",t),o.b.$on("roundtrip",n)};e.a=function(){u(),c()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n.d(e,"addWatcher",function(){return i}),n.d(e,"syncWatchers",function(){return o}),n.d(e,"updateWatcher",function(){return a});var r=n(4),i=function(t,e){return t.watchers.push(e),t},o=function(t,e){return t.watchers=e,t},a=function(t,e){var n=t.watchers.findIndex(function(t){return t.id===e.gekko_id}),i=t.watchers[n];if(!i)return t;var o=r.a.util.extend(i,e.updates);return r.a.set(t.watchers,n,o),t}},function(t,e,n){"use strict";var r=n(2),i=n(7),o=n(6),a=n(3),s=n.n(a),u=function(){n.i(r.a)("gekkos",function(t,e){var n=s.a.filter(e,{type:"watcher"});i.a.commit("syncWatchers",n)})},c=function(){o.b.$on("new_gekko",function(t){"watcher"===t.gekko.type&&i.a.commit("addWatcher",t.gekko)});var t=function(t){i.a.commit("updateWatcher",t)};o.b.$on("update",t),o.b.$on("startAt",t),o.b.$on("lastCandle",t),o.b.$on("firstCandle",t)};e.a=function(){u(),c()}},function(t,e,n){function r(t){if(t)return i(t)}function i(t){for(var e in r.prototype)t[e]=r.prototype[e];return t}t.exports=r,r.prototype.on=r.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks["$"+t]=this._callbacks["$"+t]||[]).push(e),this},r.prototype.once=function(t,e){function n(){this.off(t,n),e.apply(this,arguments)}return n.fn=e,this.on(t,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n=this._callbacks["$"+t];if(!n)return this;if(1==arguments.length)return delete this._callbacks["$"+t],this;for(var r,i=0;i4?t:document.documentMode}()},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#chartWrapper.clickable{position:relative}#chartWrapper.clickable .shield{cursor:zoom-in;position:absolute;top:0;bottom:0;left:0;right:0;background:grey;opacity:.1}#chart{background-color:#eee;width:100%}#chart circle{clip-path:url(#clip)}#chart .zoom{cursor:move;fill:none;pointer-events:all}#chart .line{fill:none;stroke:#4682b4;stroke-width:1.5px;clip-path:url(#clip)}#chart circle.buy{fill:#7fff00}#chart circle.sell{fill:red}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".scan-btn{margin-top:80px;margin-bottom:30px}.radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".progressbarWrapper p{text-align:center;font-size:20px}.progressbar{background-color:hsla(0,0%,85%,.99);border-radius:13px;padding:0}@keyframes shimmer{0%{background-position:0 0}to{background-position:960px 0}}.progressbar>div{height:20px;border-radius:10px;background-color:orange;animation-duration:1.5s;animation-fill-mode:forwards;animation-iteration-count:infinite;animation-name:shimmer;animation-timing-function:linear;background:#f6f7f8;background:linear-gradient(90deg,orange 10%,#ffce77 25%,orange 40%);background-size:960px 50px;background-position:0;position:relative}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".summary td{text-align:right}.big{font-size:1.3em}.big,.summary table{width:80%}.price.profit{color:#7fff00}.price.loss{color:red}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".summary td{text-align:right}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".scan-btn{margin-top:80px;margin-bottom:30px}.radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".clickable{cursor:pointer}table.full{width:100%}table.full td{padding:.5rem 0}table.full.data th{text-align:left;padding:.5rem 0}.warning p{margin:0;padding:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".menu{display:flex;width:100%;flex-direction:row;margin-top:0;margin-bottom:2rem}.menu a{flex:1 1 100%;display:block;text-align:center;text-decoration:none;color:inherit}.menu .router-link-active{background-color:hsla(0,0%,98%,.99)}.menu a:hover{text-decoration:underline}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".contain{max-width:900px;margin-left:auto;margin-right:auto}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".spinner{margin:20px auto 100px;width:50px;height:40px;text-align:center;font-size:10px}.spinner>div{background-color:#333;height:100%;width:6px;display:inline-block;margin-right:4px;-webkit-animation:sk-stretchdelay 1.2s infinite ease-in-out;animation:sk-stretchdelay 1.2s infinite ease-in-out}.spinner .rect2{-webkit-animation-delay:-1.1s;animation-delay:-1.1s}.spinner .rect3{-webkit-animation-delay:-1s;animation-delay:-1s}.spinner .rect4{-webkit-animation-delay:-.9s;animation-delay:-.9s}.spinner .rect5{-webkit-animation-delay:-.8s;animation-delay:-.8s}@-webkit-keyframes sk-stretchdelay{0%,40%,to{-webkit-transform:scaleY(.4)}20%{-webkit-transform:scaleY(1)}}@keyframes sk-stretchdelay{0%,40%,to{transform:scaleY(.4);-webkit-transform:scaleY(.4)}20%{transform:scaleY(1);-webkit-transform:scaleY(1)}}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".radio label{margin-top:0}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#app{display:flex;min-height:100vh;flex-direction:column}.fill{flex:1}.text{max-width:500px}input{background:none;margin-top:.5em}.params{min-height:235px;line-height:1.3em}.hr{margin-top:2rem;margin-bottom:2rem;height:10px;background-color:hsla(0,0%,98%,.99)}.btn--primary{display:inline-block;margin-right:12px;margin-bottom:12px;height:40px;padding:0 18px;border-radius:4px;text-shadow:0 1px 3px rgba(36,180,126,.4);box-shadow:0 4px 6px rgba(50,50,93,.11),0 1px 3px rgba(0,0,0,.08);line-height:40px;transition:transform .25s}.btn--primary,.btn--primary:hover{background-color:#3498db;color:#fff;text-decoration:none}.btn--primary:hover{transform:translateY(-1px);box-shadow:0 7px 14px rgba(50,50,93,.1),0 3px 6px rgba(0,0,0,.08)}.btn--primary:active,.btn--primary:focus{background-color:#3498db;color:#fff;text-decoration:none}.btn--primary:active{transform:translateY(1px)}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"table.clickable{border-collapse:separate}tr.clickable td:first-child{padding-left:5px}tr.clickable{cursor:pointer}tr.clickable:hover{background:hsla(0,0%,85%,.99)}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"td.radio{width:45px}td label{display:inline;font-size:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"#modal-background{position:fixed;top:0;bottom:0;left:0;right:0;background-color:#000;opacity:.5}.modal{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:600px;min-height:300px;background-color:#fff}.modal-guts{position:absolute;top:0;left:0;width:100%;height:100%;padding:20px 50px 20px 20px;overflow:auto}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".align .custom-select select{padding:.4em 1.2em .3em .8em}.label-like{display:block;font-size:.9em;color:#777}.align{padding-left:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".align .custom-select select{padding:.4em 1.2em .3em .8em}.label-like{display:block;font-size:.9em;color:#777}.align{padding-left:1em}",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,"",""])},function(t,e,n){e=t.exports=n(0)(),e.push([t.i,".roundtrips{margin-top:50px;margin-bottom:50px}.roundtrips table{width:100%}.roundtrips table td,.roundtrips table th{border:1px solid #c6cbd1;padding:8px 12px}.roundtrips table td.loss{color:red;text-align:right}.roundtrips table td.profit{color:green;text-align:right}.roundtrips table tr:nth-child(2n){background-color:#f6f8fa}",""])},function(t,e){t.exports={name:"gekko",version:"0.5.12",description:"A bitcoin trading bot for auto trading at various exchanges",keywords:["trading","bot","bitcoin","TA","finance"],scripts:{test:"./node_modules/.bin/mocha test/*.js --recursive test -u tdd --reporter spec",start:"node ./gekko --config config.js --ui"},author:"Mike van Rossum ",dependencies:{"@slack/client":"^3.10.0",async:"2.1.2",binance:"^1.1.0","bitcoin-co-id":"0.0.1",bitexthai:"^0.1.0","bitfinex-api-node":"^1.2.0",bitstamp:"^1.0.3",bitx:"^1.5.0","btc-china-fork":"0.0.6","btc-markets":"0.0.10",cexio:"0.0.x","co-fs":"^1.2.0",coinfalcon:"^1.0.3",commander:"^2.9.0",gdax:"^0.4.2",gekko:"0.0.9","gemini-exchange-coffee-api":"2.0.6","humanize-duration":"^3.10.0",koa:"^1.2.0","koa-bodyparser":"^2.2.0","koa-cors":"0.0.16","koa-logger":"^1.3.0","koa-router":"^5.4.0","koa-static":"^2.0.0","kraken-api-es5":"^1.0.0",lakebtc_nodejs:"0.1.x",lodash:"2.x",moment:"2.19.3","node-wex":"^1.0.3","node.bittrex.api":"^0.4.3","okcoin-china":"0.0.7",opn:"^4.0.2","poloniex.js":"0.0.7","promisify-node":"^0.4.0","prompt-lite":"0.1.1",pushbullet:"1.4.3",quadrigacx:"0.0.7",relieve:"^2.1.3",retry:"^0.10.1",semver:"5.4.1",sqlite3:"^3.1.13","stats-lite":"^2.0.4","tiny-promisify":"^0.1.1",toml:"^2.3.0",twitter:"^1.7.1","zaif.jp":"^0.1.4"},devDependencies:{chai:"^2.0.0",mocha:"^2.1.1",proxyquire:"^1.7.10",sinon:"^1.12.2"},engines:{node:">=6.0"},license:"MIT",repository:{type:"git",url:"https://github.com/askmike/gekko.git"}}},function(t,e){t.exports={name:"vue",version:"0.2.0",description:"The frontend for the Gekko UI",author:"Mike van Rossum ",scripts:{dev:"cross-env NODE_ENV=development webpack-dev-server --open --inline --hot",build:"cross-env NODE_ENV=production webpack --progress --hide-modules"},devDependencies:{"babel-core":"^6.0.0","babel-loader":"^6.0.0","babel-preset-es2015":"^6.0.0","cross-env":"^3.0.0","css-loader":"^0.25.0","file-loader":"^0.9.0","json-loader":"^0.5.4",marked:"^0.3.6",superagent:"^2.3.0","superagent-no-cache":"uditalias/superagent-no-cache",vue:"^2.0.1","vue-loader":"^9.7.0","vue-router":"^2.0.3",vuex:"^2.2.1",webpack:"^2.1.0-beta.25","webpack-dev-server":"^2.1.0-beta.0"},dependencies:{jade:"^1.11.0"}}},function(t,e,n){(function(e){(function(){function e(t){this.tokens=[],this.tokens.links={},this.options=t||l.defaults,this.rules=f.normal,this.options.gfm&&(this.options.tables?this.rules=f.tables:this.rules=f.gfm)}function n(t,e){if(this.options=e||l.defaults,this.links=t,this.rules=d.normal,this.renderer=this.options.renderer||new r,this.renderer.options=this.options,!this.links)throw new Error("Tokens array requires a `links` property.");this.options.gfm?this.options.breaks?this.rules=d.breaks:this.rules=d.gfm:this.options.pedantic&&(this.rules=d.pedantic)}function r(t){this.options=t||{}}function i(t){this.tokens=[],this.token=null,this.options=t||l.defaults,this.options.renderer=this.options.renderer||new r,this.renderer=this.options.renderer,this.renderer.options=this.options}function o(t,e){return t.replace(e?/&/g:/&(?!#?\w+;)/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}function a(t){return t.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/g,function(t,e){return e=e.toLowerCase(),"colon"===e?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""})}function s(t,e){return t=t.source,e=e||"",function n(r,i){return r?(i=i.source||i,i=i.replace(/(^|[^\[])\^/g,"$1"),t=t.replace(r,i),n):new RegExp(t,e)}}function u(){}function c(t){for(var e,n,r=1;rAn error occured:"+o(t.message+"",!0)+"
";throw t}}var f={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:u,hr:/^( *[-*_]){3,} *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,nptable:u,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,blockquote:/^( *>[^\n]+(\n(?!def)[^\n]+)*\n*)+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:/^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,def:/^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,table:u,paragraph:/^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,text:/^[^\n]+/};f.bullet=/(?:[*+-]|\d+\.)/,f.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,f.item=s(f.item,"gm")(/bull/g,f.bullet)(),f.list=s(f.list)(/bull/g,f.bullet)("hr","\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))")("def","\\n+(?="+f.def.source+")")(),f.blockquote=s(f.blockquote)("def",f.def)(),f._tag="(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b",f.html=s(f.html)("comment",//)("closed",/<(tag)[\s\S]+?<\/\1>/)("closing",/])*?>/)(/tag/g,f._tag)(),f.paragraph=s(f.paragraph)("hr",f.hr)("heading",f.heading)("lheading",f.lheading)("blockquote",f.blockquote)("tag","<"+f._tag)("def",f.def)(),f.normal=c({},f),f.gfm=c({},f.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),f.gfm.paragraph=s(f.paragraph)("(?!","(?!"+f.gfm.fences.source.replace("\\1","\\2")+"|"+f.list.source.replace("\\1","\\3")+"|")(),f.tables=c({},f.gfm,{nptable:/^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,table:/^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/}),e.rules=f,e.lex=function(t,n){return new e(n).lex(t)},e.prototype.lex=function(t){return t=t.replace(/\r\n|\r/g,"\n").replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,"\n"),this.token(t,!0)},e.prototype.token=function(t,e,n){for(var r,i,o,a,s,u,c,l,d,t=t.replace(/^ +$/gm,"");t;)if((o=this.rules.newline.exec(t))&&(t=t.substring(o[0].length),o[0].length>1&&this.tokens.push({type:"space"})),o=this.rules.code.exec(t))t=t.substring(o[0].length),o=o[0].replace(/^ {4}/gm,""),this.tokens.push({type:"code",text:this.options.pedantic?o:o.replace(/\n+$/,"")});else if(o=this.rules.fences.exec(t))t=t.substring(o[0].length),this.tokens.push({type:"code",lang:o[2],text:o[3]||""});else if(o=this.rules.heading.exec(t))t=t.substring(o[0].length),this.tokens.push({type:"heading",depth:o[1].length,text:o[2]});else if(e&&(o=this.rules.nptable.exec(t))){for(t=t.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/\n$/,"").split("\n")},l=0;l ?/gm,""),this.token(o,e,!0),this.tokens.push({type:"blockquote_end"});else if(o=this.rules.list.exec(t)){for(t=t.substring(o[0].length),a=o[2],this.tokens.push({type:"list_start",ordered:a.length>1}),o=o[0].match(this.rules.item),r=!1,d=o.length,l=0;l1&&s.length>1||(t=o.slice(l+1).join("\n")+t,l=d-1)),i=r||/\n\n(?!\s*$)/.test(u),l!==d-1&&(r="\n"===u.charAt(u.length-1),i||(i=r)),this.tokens.push({type:i?"loose_item_start":"list_item_start"}),this.token(u,!1,n),this.tokens.push({type:"list_item_end"});this.tokens.push({type:"list_end"})}else if(o=this.rules.html.exec(t))t=t.substring(o[0].length),this.tokens.push({type:this.options.sanitize?"paragraph":"html",pre:!this.options.sanitizer&&("pre"===o[1]||"script"===o[1]||"style"===o[1]),text:o[0]});else if(!n&&e&&(o=this.rules.def.exec(t)))t=t.substring(o[0].length),this.tokens.links[o[1].toLowerCase()]={href:o[2],title:o[3]};else if(e&&(o=this.rules.table.exec(t))){for(t=t.substring(o[0].length),u={type:"table",header:o[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:o[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:o[3].replace(/(?: *\| *)?\n$/,"").split("\n")},l=0;l])/,autolink:/^<([^ >]+(@|:\/)[^ >]+)>/,url:u,tag:/^|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,link:/^!?\[(inside)\]\(href\)/,reflink:/^!?\[(inside)\]\s*\[([^\]]*)\]/,nolink:/^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,strong:/^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,em:/^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,code:/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,br:/^ {2,}\n(?!\s*$)/,del:u,text:/^[\s\S]+?(?=[\\?(?:\s+['"]([\s\S]*?)['"])?\s*/,d.link=s(d.link)("inside",d._inside)("href",d._href)(),d.reflink=s(d.reflink)("inside",d._inside)(),d.normal=c({},d),d.pedantic=c({},d.normal,{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/}),d.gfm=c({},d.normal,{escape:s(d.escape)("])","~|])")(),url:/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,del:/^~~(?=\S)([\s\S]*?\S)~~/,text:s(d.text)("]|","~]|")("|","|https?://|")()}),d.breaks=c({},d.gfm,{br:s(d.br)("{2,}","*")(),text:s(d.gfm.text)("{2,}","*")()}),n.rules=d,n.output=function(t,e,r){return new n(e,r).output(t)},n.prototype.output=function(t){for(var e,n,r,i,a="";t;)if(i=this.rules.escape.exec(t))t=t.substring(i[0].length),a+=i[1];else if(i=this.rules.autolink.exec(t))t=t.substring(i[0].length),"@"===i[2]?(n=":"===i[1].charAt(6)?this.mangle(i[1].substring(7)):this.mangle(i[1]),r=this.mangle("mailto:")+n):(n=o(i[1]),r=n),a+=this.renderer.link(r,null,n);else if(this.inLink||!(i=this.rules.url.exec(t))){if(i=this.rules.tag.exec(t))!this.inLink&&/^/i.test(i[0])&&(this.inLink=!1),t=t.substring(i[0].length),a+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(i[0]):o(i[0]):i[0];else if(i=this.rules.link.exec(t))t=t.substring(i[0].length),this.inLink=!0,a+=this.outputLink(i,{href:i[2],title:i[3]}),this.inLink=!1;else if((i=this.rules.reflink.exec(t))||(i=this.rules.nolink.exec(t))){if(t=t.substring(i[0].length),e=(i[2]||i[1]).replace(/\s+/g," "),!(e=this.links[e.toLowerCase()])||!e.href){a+=i[0].charAt(0),t=i[0].substring(1)+t;continue}this.inLink=!0,a+=this.outputLink(i,e),this.inLink=!1}else if(i=this.rules.strong.exec(t))t=t.substring(i[0].length),a+=this.renderer.strong(this.output(i[2]||i[1]));else if(i=this.rules.em.exec(t))t=t.substring(i[0].length),a+=this.renderer.em(this.output(i[2]||i[1]));else if(i=this.rules.code.exec(t))t=t.substring(i[0].length),a+=this.renderer.codespan(o(i[2],!0));else if(i=this.rules.br.exec(t))t=t.substring(i[0].length),a+=this.renderer.br();else if(i=this.rules.del.exec(t))t=t.substring(i[0].length),a+=this.renderer.del(this.output(i[1]));else if(i=this.rules.text.exec(t))t=t.substring(i[0].length),a+=this.renderer.text(o(this.smartypants(i[0])));else if(t)throw new Error("Infinite loop on byte: "+t.charCodeAt(0))}else t=t.substring(i[0].length),n=o(i[1]),r=n,a+=this.renderer.link(r,null,n);return a},n.prototype.outputLink=function(t,e){var n=o(e.href),r=e.title?o(e.title):null;return"!"!==t[0].charAt(0)?this.renderer.link(n,r,this.output(t[1])):this.renderer.image(n,r,o(t[1]))},n.prototype.smartypants=function(t){return this.options.smartypants?t.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014\/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014\/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…"):t},n.prototype.mangle=function(t){if(!this.options.mangle)return t;for(var e,n="",r=t.length,i=0;i.5&&(e="x"+e.toString(16)),n+=""+e+";";return n},r.prototype.code=function(t,e,n){if(this.options.highlight){var r=this.options.highlight(t,e);null!=r&&r!==t&&(n=!0,t=r)}return e?''+(n?t:o(t,!0))+"\n
\n":""+(n?t:o(t,!0))+"\n
"},r.prototype.blockquote=function(t){return"\n"+t+"
\n"},r.prototype.html=function(t){return t},r.prototype.heading=function(t,e,n){return"\n"},r.prototype.hr=function(){return this.options.xhtml?"
\n":"
\n"},r.prototype.list=function(t,e){var n=e?"ol":"ul";return"<"+n+">\n"+t+""+n+">\n"},r.prototype.listitem=function(t){return""+t+"\n"},r.prototype.paragraph=function(t){return""+t+"
\n"},r.prototype.table=function(t,e){return"\n"},r.prototype.tablerow=function(t){return"\n"+t+"
\n"},r.prototype.tablecell=function(t,e){var n=e.header?"th":"td";return(e.align?"<"+n+' style="text-align:'+e.align+'">':"<"+n+">")+t+""+n+">\n"},r.prototype.strong=function(t){return""+t+""},r.prototype.em=function(t){return""+t+""},r.prototype.codespan=function(t){return""+t+"
"},r.prototype.br=function(){return this.options.xhtml?"
":"
"},r.prototype.del=function(t){return""+t+""},r.prototype.link=function(t,e,n){if(this.options.sanitize){try{var r=decodeURIComponent(a(t)).replace(/[^\w:]/g,"").toLowerCase()}catch(t){return""}if(0===r.indexOf("javascript:")||0===r.indexOf("vbscript:"))return""}var i='"+n+""},r.prototype.image=function(t,e,n){var r='":">"},r.prototype.text=function(t){return t},i.parse=function(t,e,n){return new i(e,n).parse(t)},i.prototype.parse=function(t){this.inline=new n(t.links,this.options,this.renderer),this.tokens=t.reverse();for(var e="";this.next();)e+=this.tok();return e},i.prototype.next=function(){return this.token=this.tokens.pop()},i.prototype.peek=function(){return this.tokens[this.tokens.length-1]||0},i.prototype.parseText=function(){for(var t=this.token.text;"text"===this.peek().type;)t+="\n"+this.next().text;return this.inline.output(t)},i.prototype.tok=function(){switch(this.token.type){case"space":return"";case"hr":return this.renderer.hr();case"heading":return this.renderer.heading(this.inline.output(this.token.text),this.token.depth,this.token.text);case"code":return this.renderer.code(this.token.text,this.token.lang,this.token.escaped);case"table":var t,e,n,r,i="",o="";for(n="",t=0;t=300)&&(r=new Error(e.statusText||"Unsuccessful HTTP response"),r.original=t,r.response=e,r.status=e.status)}catch(t){r=t}r?n.callback(r,e):n.callback(null,e)})}function p(t,e){var n=_("DELETE",t);return e&&n.end(e),n}var h;"undefined"!=typeof window?h=window:"undefined"!=typeof self?h=self:(console.warn("Using browser-only version of superagent in non-browser environment"),h=this);var v=n(82),m=n(117),g=n(15),_=t.exports=n(118).bind(null,d);_.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(t){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(t){}throw Error("Browser-only verison of superagent could not find XHR")};var y="".trim?function(t){return t.trim()}:function(t){return t.replace(/(^\s*|\s*$)/g,"")};_.serializeObject=i,_.parseString=a,_.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},_.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},_.parse={"application/x-www-form-urlencoded":a,"application/json":JSON.parse},f.prototype.get=function(t){return this.header[t.toLowerCase()]},f.prototype._setHeaderProperties=function(t){var e=this.header["content-type"]||"";this.type=c(e);var n=l(e);for(var r in n)this[r]=n[r]},f.prototype._parseBody=function(t){var e=_.parse[this.type];return!e&&u(this.type)&&(e=_.parse["application/json"]),e&&t&&(t.length||t instanceof Object)?e(t):null},f.prototype._setStatusProperties=function(t){1223===t&&(t=204);var e=t/100|0;this.status=this.statusCode=t,this.statusType=e,this.info=1==e,this.ok=2==e,this.clientError=4==e,this.serverError=5==e,this.error=(4==e||5==e)&&this.toError(),this.accepted=202==t,this.noContent=204==t,this.badRequest=400==t,this.unauthorized=401==t,this.notAcceptable=406==t,this.notFound=404==t,this.forbidden=403==t},f.prototype.toError=function(){var t=this.req,e=t.method,n=t.url,r="cannot "+e+" "+n+" ("+this.status+")",i=new Error(r);return i.status=this.status,i.method=e,i.url=n,i},_.Response=f,v(d.prototype);for(var b in m)d.prototype[b]=m[b];d.prototype.type=function(t){return this.set("Content-Type",_.types[t]||t),this},d.prototype.responseType=function(t){return this._responseType=t,this},d.prototype.accept=function(t){return this.set("Accept",_.types[t]||t),this},d.prototype.auth=function(t,e,n){switch(n||(n={type:"basic"}),n.type){case"basic":var r=btoa(t+":"+e);this.set("Authorization","Basic "+r);break;case"auto":this.username=t,this.password=e}return this},d.prototype.query=function(t){return"string"!=typeof t&&(t=i(t)),t&&this._query.push(t),this},d.prototype.attach=function(t,e,n){return this._getFormData().append(t,e,n||e.name),this},d.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},d.prototype.callback=function(t,e){var n=this._callback;this.clearTimeout(),n(t,e)},d.prototype.crossDomainError=function(){var t=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");t.crossDomain=!0,t.status=this.status,t.method=this.method,t.url=this.url,this.callback(t)},d.prototype._timeoutError=function(){var t=this._timeout,e=new Error("timeout of "+t+"ms exceeded");e.timeout=t,this.callback(e)},d.prototype._appendQueryString=function(){var t=this._query.join("&");t&&(this.url+=~this.url.indexOf("?")?"&"+t:"?"+t)},d.prototype.end=function(t){var e=this,n=this.xhr=_.getXHR(),i=this._timeout,o=this._formData||this._data;this._callback=t||r,n.onreadystatechange=function(){if(4==n.readyState){var t;try{t=n.status}catch(e){t=0}if(0==t){if(e.timedout)return e._timeoutError();if(e._aborted)return;return e.crossDomainError()}e.emit("end")}};var a=function(t,n){n.total>0&&(n.percent=n.loaded/n.total*100),n.direction=t,e.emit("progress",n)};if(this.hasListeners("progress"))try{n.onprogress=a.bind(null,"download"),n.upload&&(n.upload.onprogress=a.bind(null,"upload"))}catch(t){}if(i&&!this._timer&&(this._timer=setTimeout(function(){e.timedout=!0,e.abort()},i)),this._appendQueryString(),this.username&&this.password?n.open(this.method,this.url,!0,this.username,this.password):n.open(this.method,this.url,!0),this._withCredentials&&(n.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof o&&!this._isHost(o)){var s=this._header["content-type"],c=this._serializer||_.serialize[s?s.split(";")[0]:""];!c&&u(s)&&(c=_.serialize["application/json"]),c&&(o=c(o))}for(var l in this.header)null!=this.header[l]&&n.setRequestHeader(l,this.header[l]);return this._responseType&&(n.responseType=this._responseType),this.emit("request",this),n.send(void 0!==o?o:null),this},_.Request=d,_.get=function(t,e,n){var r=_("GET",t);return"function"==typeof e&&(n=e,e=null),e&&r.query(e),n&&r.end(n),r},_.head=function(t,e,n){var r=_("HEAD",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.options=function(t,e,n){var r=_("OPTIONS",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.del=p,_.delete=p,_.patch=function(t,e,n){var r=_("PATCH",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.post=function(t,e,n){var r=_("POST",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r},_.put=function(t,e,n){var r=_("PUT",t);return"function"==typeof e&&(n=e,e=null),e&&r.send(e),n&&r.end(n),r}},function(t,e,n){var r=n(15);e.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},e.parse=function(t){return this._parser=t,this},e.serialize=function(t){return this._serializer=t,this},e.timeout=function(t){return this._timeout=t,this},e.then=function(t,e){if(!this._fullfilledPromise){var n=this;this._fullfilledPromise=new Promise(function(t,e){n.end(function(n,r){n?e(n):t(r)})})}return this._fullfilledPromise.then(t,e)},e.catch=function(t){return this.then(void 0,t)},e.use=function(t){return t(this),this},e.get=function(t){return this._header[t.toLowerCase()]},e.getHeader=e.get,e.set=function(t,e){if(r(t)){for(var n in t)this.set(n,t[n]);return this}return this._header[t.toLowerCase()]=e,this.header[t]=e,this},e.unset=function(t){return delete this._header[t.toLowerCase()],delete this.header[t],this},e.field=function(t,e){if(null===t||void 0===t)throw new Error(".field(name, val) name can not be empty");if(r(t)){for(var n in t)this.field(n,t[n]);return this}if(null===e||void 0===e)throw new Error(".field(name, val) val can not be empty");return this._getFormData().append(t,e),this},e.abort=function(){return this._aborted?this:(this._aborted=!0,this.xhr&&this.xhr.abort(),this.req&&this.req.abort(),this.clearTimeout(),this.emit("abort"),this)},e.withCredentials=function(){return this._withCredentials=!0,this},e.redirects=function(t){return this._maxRedirects=t,this},e.toJSON=function(){return{method:this.method,url:this.url,data:this._data,headers:this._header}},e._isHost=function(t){switch({}.toString.call(t)){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}},e.send=function(t){var e=r(t),n=this._header["content-type"];if(e&&r(this._data))for(var i in t)this._data[i]=t[i];else"string"==typeof t?(n||this.type("form"),n=this._header["content-type"],this._data="application/x-www-form-urlencoded"==n?this._data?this._data+"&"+t:t:(this._data||"")+t):this._data=t;return!e||this._isHost(t)?this:(n||this.type("json"),this)}},function(t,e){function n(t,e,n){return"function"==typeof n?new t("GET",e).end(n):2==arguments.length?new t("GET",e):new t(e,n)}t.exports=n},function(t,e,n){var r,i;n(191),r=n(36);var o=n(163);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(170),r=n(39);var o=n(140);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(169),r=n(41);var o=n(139);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(189),r=n(42);var o=n(161);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(175),r=n(45);var o=n(145);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(190),r=n(48);var o=n(162);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(182),r=n(54);var o=n(154);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;r=n(55);var o=n(151);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(179),r=n(61);var o=n(150);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(167),r=n(63);var o=n(134);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;r=n(64);var o=n(138);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(176),r=n(65);var o=n(146);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e,n){var r,i;n(184),r=n(67);var o=n(156);i=r=r||{},"object"!=typeof r.default&&"function"!=typeof r.default||(i=r=r.default),"function"==typeof i&&(i=i.options),i.render=o.render,i.staticRenderFns=o.staticRenderFns,t.exports=r},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{class:{clickable:!t.isClicked},attrs:{id:"chartWrapper"}},[n("div",{staticClass:"shield",on:{click:function(e){e.preventDefault(),t.click(e)}}}),n("svg",{attrs:{id:"chart",width:"960",height:t.height}})])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Daterange")]),n("div",[n("label",{attrs:{for:"from"}},[t._v("From")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.from,expression:"from"}],domProps:{value:t.from},on:{input:function(e){e.target.composing||(t.from=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"to"}},[t._v("To")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.to,expression:"to"}],domProps:{value:t.to},on:{input:function(e){e.target.composing||(t.to=e.target.value)}}})])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.progress?n("div",{staticClass:"progressbarWrapper"},[n("p",[n("strong",[t._v(t._s(t.round(t.progress))+"%")])]),n("div",{staticClass:"progressbar"},[n("div",{style:{width:t.progress+"%"}})])]):t._e()},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"mx1"},[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Exchange:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.exchange,expression:"exchange"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.exchange=e.target.multiple?n:n[0]}}},t._l(t.exchanges,function(e,r){return n("option",[t._v(t._s(r))])}))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("label",{attrs:{for:"currency"}},[t._v("Currency:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.currency,expression:"currency"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.currency=e.target.multiple?n:n[0]}}},t._l(t.currencies,function(e){return n("option",[t._v(t._s(e))])}))])]),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("label",{attrs:{for:"asset"}},[t._v("Asset:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.asset,expression:"asset"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.asset=e.target.multiple?n:n[0]}}},t._l(t.assets,function(e){return n("option",[t._v(t._s(e))])}))])])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-3-6"},[n("table",{staticClass:"p1"},[n("tr",[n("th",[t._v("amount of trades")]),n("td",[t._v(t._s(t.report.trades))])]),n("tr",[n("th",[t._v("sharpe ratio")]),n("td",[t._v(t._s(t.round2(t.report.sharpe)))])]),n("tr",[n("th",[t._v("start balance")]),n("td",[t._v(t._s(t.round(t.report.startBalance))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("final balance")]),n("td",[t._v(t._s(t.round(t.report.balance))+" "+t._s(t.report.currency))])]),t._m(0)]),n("div",{staticClass:"big txt--right price",class:t.profitClass},[t._v(t._s(t.round(t.report.relativeProfit))+"%")])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",[n("th",[t._v("simulated profit")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("h2",[t._v("Config")]),n("div",{staticClass:"hr"}),n("h3",[t._v("Available API keys")]),t.apiKeySets.length?t._e():n("p",[n("em",[t._v("You don't have any API keys yet.")])]),n("ul",t._l(t.apiKeySets,function(e){return n("li",[t._v(t._s(e)+" ("),n("a",{attrs:{href:"#"},on:{click:function(n){n.preventDefault(),t.removeApiKey(e)}}},[t._v("remove")]),t._v(")")])})),t.addApiToggle?t._e():n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.openAddApi(e)}}},[t._v("Add an API key")]),t.addApiToggle?[n("div",{staticClass:"hr"}),n("apiConfigBuilder")]:t._e(),n("div",{staticClass:"hr"})],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("footer",{staticClass:"p2 bg--off-white"},[n("div",{staticClass:"contain"},[t._m(0),n("p",[t._v("Using Gekko v"+t._s(t.version.gekko)+" and Gekko UI v"+t._s(t.version.ui)+".")])])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("p",[n("em",[t._v("Use Gekko at your own risk.")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("div",{staticClass:"grd-row summary"},[n("div",{staticClass:"grd-row-col-3-6"},[n("table",{staticClass:"p1"},[n("tr",[n("th",[t._v("start time")]),n("td",[t._v(t._s(t.report.startTime))])]),n("tr",[n("th",[t._v("end time")]),n("td",[t._v(t._s(t.report.endTime))])]),n("tr",[n("th",[t._v("timespan")]),n("td",[t._v(t._s(t.report.timespan))])]),n("tr",[n("th",[t._v("start price")]),n("td",[t._v(t._s(t.round(t.report.startPrice))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("end price")]),n("td",[t._v(t._s(t.round(t.report.endPrice))+" "+t._s(t.report.currency))])]),n("tr",[n("th",[t._v("market")]),n("td",[t._v(t._s(t.round(t.report.market))+"%")])])])]),n("paperTradeSummary",{attrs:{report:t.report}})],1)])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"hr contain"}),t._m(0),n("result-summary",{attrs:{report:t.result.report}}),n("div",{staticClass:"hr contain"}),n("chart",{attrs:{data:t.result,height:"500"}}),n("div",{staticClass:"hr contain"}),n("roundtripTable",{attrs:{roundtrips:t.result.roundtrips}})],1)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("h3",[t._v("Backtest result")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[n("h3",[t._v("Start a new gekko")]),n("gekko-config-builder",{on:{config:t.updateConfig}}),n("div",{staticClass:"hr"}),t.config.valid?n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.start(e)}}},[t._v("Start")])]):t._e()],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.intro)}}),n("div",{staticClass:"hr"}),n("h3",[t._v("Currently running imports")]),0===t.imports.length?n("p",[t._v("You currently don't have any imports running.")]):t._e(),t.imports.length?n("ul",t._l(t.imports,function(e){return n("li",[n("router-link",{attrs:{to:"/data/importer/import/"+e.id}},[t._v(t._s(e.watch.exchange)+":"+t._s(e.watch.currency)+"/"+t._s(e.watch.asset))])],1)})):t._e(),n("div",{staticClass:"hr"}),n("h3",[t._v("Start a new import")]),n("import-config-builder",{on:{config:t.updateConfig}}),n("div",{staticClass:"hr"}),n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.run(e)}}},[t._v("Import")])])],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Daterange")]),"scan"===t.tab?[t.scanned?t._e():n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]),"fetching"==t.scanned?n("div",{staticClass:"txt--center"},[n("p",{staticClass:"scan-btn"},[t._v("Scanning..")])]):t._e(),1==t.scanned?[0===t.ranges.length?[n("p",[n("strong",[t._v('Unable to find any local data, do you have local data available for\n"'+t._s(t.config.watch.exchange)+":"+t._s(t.config.watch.currency)+"/"+t._s(t.config.watch.asset)+'"?')])])]:[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Run simulation over:")]),n("form",{staticClass:"radio grd"},t._l(t.ranges,function(e,r){return n("div",{staticClass:"grd-row m1"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.selectedRangeIndex,expression:"selectedRangeIndex"}],staticClass:"grd-row-col-1-6",attrs:{type:"radio"},domProps:{value:r,checked:t._q(t.selectedRangeIndex,r)},on:{__c:function(e){t.selectedRangeIndex=r}}}),n("label",{staticClass:"grd-row-col-5-6",attrs:{for:r}},[t._v(t._s(t.printRange(e)))])])}))],n("p",[n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("rescan")])])])]:t._e(),n("p",{staticClass:"txt--center"},[n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.tab="manual"}}},[t._v("Or manually set a daterange")])])])]:t._e(),"manual"===t.tab?[n("div",[n("label",{attrs:{for:"from"}},[t._v("From:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.from,expression:"from"}],domProps:{value:t.from},on:{input:function(e){e.target.composing||(t.from=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"to"}},[t._v("To:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.to,expression:"to"}],domProps:{value:t.to},on:{input:function(e){e.target.composing||(t.to=e.target.value)}}})]),n("p",{staticClass:"txt--center"}),n("em",[n("a",{attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.tab="scan"}}},[t._v("Or scan for a daterange")])])]:t._e()],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.intro)}}),n("div",{staticClass:"hr"}),n("h2",[t._v("Available datasets")]),"idle"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]):t._e(),"scanning"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("spinner")],1):t._e(),"scanned"===t.datasetScanstate?n("div",{staticClass:"my2"},[t.unscannableMakets.length?n("div",{staticClass:"bg--orange p1 warning my1"},[t.viewUnscannable?t._e():n("p",{staticClass:"clickable",on:{click:function(e){e.preventDefault(),t.toggleUnscannable(e)}}},[t._v("Some markets were unscannable, click here for details.")]),t.viewUnscannable?[n("p",[t._v("Unable to find datasets in the following markets:")]),t._l(t.unscannableMakets,function(e){return n("div",{staticClass:"mx2"},[t._v("- "+t._s(e.exchange)+":"+t._s(e.currency)+":"+t._s(e.asset))])})]:t._e()],2):t._e(),t.datasets.length?[n("table",{staticClass:"full data"},[t._m(0),n("tbody",t._l(t.datasets,function(e){return n("tr",[n("td",[t._v(t._s(e.exchange))]),n("td",[t._v(t._s(e.currency))]),n("td",[t._v(t._s(e.asset))]),n("td",[t._v(t._s(t.fmt(e.from)))]),n("td",[t._v(t._s(t.fmt(e.to)))]),n("td",[t._v(t._s(t.humanizeDuration(e.to.diff(e.from))))])])}))])]:t._e(),t.datasets.length?t._e():[n("p",[t._v("It looks like you don't have any local data yet.")])]],2):t._e(),n("div",{staticClass:"my2"},[n("h2",[t._v("Import more data")]),n("p",{staticClass:"text"},[t._v("You can easily import more market data directly from exchanges using the importer.")]),n("router-link",{staticClass:"btn--primary",attrs:{to:"/data/importer"}},[t._v("Go to the importer!")])],1)])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("from")]),n("th",[t._v("to")]),n("th",[t._v("duration")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Market")]),n("market-picker",{staticClass:"contain",attrs:{"only-importable":"true"},on:{market:t.updateMarketConfig}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("range-creator",{on:{range:t.updateRange}})],1)])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{attrs:{id:"top"}}),t._m(0),n("nav",{staticClass:"bg--light-gray"},[n("div",{staticClass:"menu contain"},[n("router-link",{staticClass:"py1",attrs:{to:"/home"}},[t._v("Home")]),n("router-link",{staticClass:"py1",attrs:{to:"/live-gekkos"}},[t._v("Live Gekkos")]),n("router-link",{staticClass:"py1",attrs:{to:"/backtest"}},[t._v("Backtest")]),n("router-link",{staticClass:"py1",attrs:{to:"/data"}},[t._v("Local data")]),n("router-link",{staticClass:"py1",attrs:{to:"/config"}},[t._v("Config")]),n("a",{staticClass:"py1",attrs:{href:"https://gekko.wizb.it/docs/introduction/about_gekko.html",target:"_blank"}},[t._v("Documentation")])],1)])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("header",{staticClass:"bg--off-white grd"},[n("div",{staticClass:"contain grd-row"},[n("h3",{staticClass:"py1 px2 col-2"},[t._v("Gekko UI")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("section",{staticClass:"contain grd-row"},[n("div",{staticClass:"grd-row-col-3-6",domProps:{innerHTML:t._s(t.left)}}),t._m(0)])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-3-6 txt--center"},[n("img",{attrs:{src:"/assets/gekko.jpg"}}),n("p",[n("em",[t._v("The most valuable commodity I know of is information.")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h2",{staticClass:"contain"},[t._v("Backtest")]),n("div",{staticClass:"hr contain"}),n("config-builder",{on:{config:t.check}}),t.backtestable?n("div",[n("div",{staticClass:"txt--center"},["fetching"!==t.backtestState?n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.run(e)}}},[t._v("Backtest")]):t._e(),"fetching"===t.backtestState?n("div",{staticClass:"scan-btn"},[n("p",[t._v("Running backtest..")]),n("spinner")],1):t._e()])]):t._e(),t.backtestResult&&"fetched"===t.backtestState?n("result",{attrs:{result:t.backtestResult}}):t._e()],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement;t._self._c;return t._m(0)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"spinner"},[n("div",{staticClass:"rect1"}),n("div",{staticClass:"rect2"}),n("div",{staticClass:"rect3"}),n("div",{staticClass:"rect4"})])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Type")]),[n("label",{staticClass:"wrapper",attrs:{for:"type"}},[t._v("What do you want to do with gekko?")]),n("form",{staticClass:"radio grd"},t._l(t.types,function(e,r){return n("div",{staticClass:"grd-row m1"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.selectedTypeIndex,expression:"selectedTypeIndex"}],staticClass:"grd-row-col-1-6",attrs:{type:"radio"},domProps:{value:r,checked:t._q(t.selectedTypeIndex,r)},on:{__c:function(e){t.selectedTypeIndex=r}}}),n("label",{staticClass:"grd-row-col-5-6",attrs:{for:r}},[t._v(t._s(e))])])}))]],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"mx1"},[n("label",{staticClass:"wrapper",attrs:{for:"exchange"}},[t._v("Exchange:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.exchange,expression:"exchange"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.exchange=e.target.multiple?n:n[0]}}},t._l(t.exchanges,function(e,r){return n("option",[t._v(t._s(r))])}))])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{attrs:{id:"app"}},[n("top"),n("div",{staticClass:"fill"},[n("router-view",{staticClass:"view"})],1),n("bottom"),n("modal")],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain py2"},[n("div",{staticClass:"text",domProps:{innerHTML:t._s(t.text)}}),n("div",{staticClass:"hr"}),n("h3",[t._v("Market watchers")]),t.watchers.length?t._e():n("div",{staticClass:"text"},[n("p",[t._v("You are currently not watching any markets.")])]),t.watchers.length?n("table",{staticClass:"full clickable"},[t._m(0),n("tbody",t._l(t.watchers,function(e){return n("tr",{staticClass:"clickable",on:{click:function(n){t.$router.push({path:"live-gekkos/watcher/"+e.id})}}},[n("td",[t._v(t._s(e.watch.exchange))]),n("td",[t._v(t._s(e.watch.currency))]),n("td",[t._v(t._s(e.watch.asset))]),n("td",[e.firstCandle?[t._v(t._s(t.fmt(e.firstCandle.start)))]:t._e()],2),n("td",[e.lastCandle?[t._v(t._s(t.fmt(e.lastCandle.start)))]:t._e()],2),n("td",[e.firstCandle&&e.lastCandle?[t._v(t._s(t.timespan(e.lastCandle.start,e.firstCandle.start)))]:t._e()],2)])}))]):t._e(),n("h3",[t._v("Strat runners")]),t.stratrunners.length?t._e():n("div",{staticClass:"text"},[n("p",[t._v("You are currently not running any strategies.")])]),t.stratrunners.length?n("table",{staticClass:"full"},[t._m(1),n("tbody",t._l(t.stratrunners,function(e){return n("tr",{staticClass:"clickable",on:{click:function(n){t.$router.push({path:"live-gekkos/stratrunner/"+e.id})}}},[n("td",[t._v(t._s(e.watch.exchange))]),n("td",[t._v(t._s(e.watch.currency))]),n("td",[t._v(t._s(e.watch.asset))]),n("td",[e.lastCandle?[t._v(t._s(t.fmt(e.lastCandle.start)))]:t._e()],2),n("td",[e.firstCandle&&e.lastCandle?[t._v(t._s(t.timespan(e.lastCandle.start,e.firstCandle.start)))]:t._e()],2),n("td",[t._v(t._s(e.strat.name))]),n("td",[e.report?t._e():[t._v("0")],e.report?[t._v(t._s(t.round(e.report.profit))+" "+t._s(e.watch.currency))]:t._e()],2)])}))]):t._e(),n("div",{staticClass:"hr"}),n("h2",[t._v("Start a new live Gekko")]),n("router-link",{staticClass:"btn--primary",attrs:{to:"/live-gekkos/new"}},[t._v("Start a new live Gekko!")])],1)},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("started at")]),n("th",[t._v("last update")]),n("th",[t._v("duration")])])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("last update")]),n("th",[t._v("duration")]),n("th",[t._v("strategy")]),n("th",[t._v("profit")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h3",[t._v("Select a dataset")]),"idle"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("a",{staticClass:"w100--s btn--primary scan-btn",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.scan(e)}}},[t._v("Scan available data")])]):t._e(),"scanning"===t.datasetScanstate?n("div",{staticClass:"txt--center my2"},[n("spinner")],1):t._e(),"scanned"===t.datasetScanstate?n("div",{staticClass:"my2"},[0!=t.datasets.length?n("div",[n("table",{staticClass:"full"},[t._m(0),n("tbody",t._l(t.datasets,function(e,r){return n("tr",[n("td",{staticClass:"radio"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.setIndex,expression:"setIndex"}],attrs:{type:"radio",name:"dataset",id:e.id},domProps:{value:r,checked:t._q(t.setIndex,r)},on:{__c:function(e){t.setIndex=r}}})]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.exchange))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.currency))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(e.asset))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.fmt(e.from)))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.fmt(e.to)))])]),n("td",[n("label",{attrs:{for:e.id}},[t._v(t._s(t.humanizeDuration(e.to.diff(e.from))))])])])}))]),t.rangeVisible?t._e():n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.openRange(e)}}},[t._v("Adjust range")]),t.rangeVisible?[n("div",[n("label",{attrs:{for:"customFrom"}},[t._v("From:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.customFrom,expression:"customFrom"}],domProps:{value:t.customFrom},on:{input:function(e){e.target.composing||(t.customFrom=e.target.value)}}})]),n("div",[n("label",{attrs:{for:"customTo"}},[t._v("To:")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.customTo,expression:"customTo"}],domProps:{value:t.customTo},on:{input:function(e){e.target.composing||(t.customTo=e.target.value)}}})])]:t._e()],2):n("em",[t._v("No Data found "),n("a",{attrs:{href:"#/data/importer"}},[t._v("Lets add some")])])]):t._e()])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("thead",[n("tr",[n("th"),n("th",[t._v("exchange")]),n("th",[t._v("currency")]),n("th",[t._v("asset")]),n("th",[t._v("from")]),n("th",[t._v("to")]),n("th",[t._v("duration")])])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"my2"},[t.data?t._e():n("div",{staticClass:"contain"},[n("h1",[t._v("Unknown Strat runner")]),n("p",[t._v("Gekko doesn't know what strat runner this is...")])]),t.data?n("div",[n("h2",{staticClass:"contain"},[t._v("Strat runner")]),n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Market")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Exchange")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Currency")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Asset")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.data.watch.asset))])])]),n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Runtime")]),t.isLoading?n("spinner"):t._e(),t.isLoading?t._e():[t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Watching since")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.firstCandle.start)))])]):t._e(),t.data.lastCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Received data until")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.lastCandle.start)))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Data spanning")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.humanizeDuration(t.moment(t.data.lastCandle.start).diff(t.moment(t.data.firstCandle.start)))))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Amount of trades")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.trades.length))])]):t._e()]],2)]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Strategy")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Name")]),n("div",{staticClass:"grd-row-col-3-6"},[n("strong",[t._v(t._s(t.stratName))])])]),t._v("Parameters"),n("pre",[t._v(t._s(t.stratParams))])]),n("div",{staticClass:"grd-row-col-3-6"},[n("h3",[t._v("Profit report")]),t.report?t._e():[t._m(0)],t.report?[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Start balance")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.startBalance)))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Current balance")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.balance)))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Market")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.market))+" "+t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Profit")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.profit))+" "+t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[t._v("Alpha")]),n("div",{staticClass:"grd-row-col-3-6"},[t._v(t._s(t.round(t.report.alpha))+" "+t._s(t.data.watch.currency))])])]:t._e()],2)]),t.watcher?n("p",[n("em",[t._v("This strat runner gets data from "),n("router-link",{attrs:{to:"/live-gekkos/watcher/"+t.watcher.id}},[t._v("this market watcher")])],1),t._v(".")]):t._e()]),t.isLoading?t._e():[n("h3",{staticClass:"contain"},[t._v("Market graph")]),"fetching"===t.candleFetch?n("spinner"):t._e(),"fetched"===t.candleFetch?[n("chart",{attrs:{data:t.chartData,height:300}})]:t._e(),n("roundtrips",{attrs:{roundtrips:t.data.roundtrips}})]],2):t._e()])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("p",[n("em",[t._v("Waiting for at least one trade..")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.active?n("div",[n("div",{attrs:{id:"modal-background"}}),n("div",{staticClass:"modal",attrs:{id:"modal"}},[n("div",{staticClass:"modal-guts",domProps:{innerHTML:t._s(t.content)}})])]):t._e()},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd"},[n("div",{staticClass:"px1"},[n("h3",[t._v("Paper trader")]),"closed"===t.toggle?n("a",{staticClass:"btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.switchToggle(e)}}},[t._v("Change paper trader settings")]):t._e(),"open"===t.toggle?[n("p",[t._v("Settings:")]),n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.rawPaperTraderParams,expression:"rawPaperTraderParams"}],staticClass:"params",domProps:{value:t.rawPaperTraderParams},on:{input:function(e){e.target.composing||(t.rawPaperTraderParams=e.target.value)}}}),t.rawPaperTraderParamsError?n("p",{staticClass:"bg--red p1"},[t._v(t._s(t.rawPaperTraderParamsError.message))]):t._e()]:t._e()],2)])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain my2"},[t.data&&!t.data.done?n("div",[n("h2",[t._v("Importing data..")]),n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[t._m(0),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[t._m(1),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.currency)+"/"+t._s(t.data.watch.asset))])])]),n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[t._m(2),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.from)))])]),n("div",{staticClass:"grd-row"},[t._m(3),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.to)))])]),t.initialized?n("div",{staticClass:"grd-row"},[t._m(4),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.latest)))])]):t._e(),t.initialized?n("div",{staticClass:"grd-row"},[t._m(5),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fromEnd))])]):t._e()]),t.initialized?t._e():n("spinner"),t.initialized?n("div",{staticClass:"contain"},[n("progressBar",{attrs:{progress:t.progress}})],1):t._e(),n("p",[n("em",[t._v("(you don't have to wait until the import is done,\nyou can already start "),n("router-link",{attrs:{to:"/backtest"}},[t._v("backtesting")]),t._v(").")],1)])],1):t._e(),t.data&&t.data.done?n("div",{staticClass:"txt--center"},[n("h2",[t._v("Import done")]),n("p",[t._v(" \nGo and "),n("router-link",{attrs:{to:"/backtest"}},[t._v("backtest")]),t._v(" with your new data!")],1)]):t._e(),t.data?t._e():n("div",{staticClass:"txt--center"},[n("h2",[t._v("ERROR: Uknown import")]),n("p",[n("I",[t._v("don't know this import..")])],1)])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Market:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Currency/Asset:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("From:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("To:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Imported data until:")])])},function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd-row-col-2-6"},[n("strong",[t._v("Remaining:")])])}]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 px1"},[n("h3",[t._v("Strategy")]),n("div",[n("label",{staticClass:"wrapper",attrs:{for:"strat"}},[t._v("Strategy:")]),n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.strategy,expression:"strategy"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.strategy=e.target.multiple?n:n[0]}}},t._l(t.strategies,function(e){return n("option",[t._v(t._s(e.name))])}))])]),n("div",[n("label",{attrs:{for:"candleSize"}},[t._v("Candle Size")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6"},[n("input",{directives:[{name:"model",rawName:"v-model",value:t.rawCandleSize,expression:"rawCandleSize"}],domProps:{value:t.rawCandleSize},on:{input:function(e){e.target.composing||(t.rawCandleSize=e.target.value)}}})]),n("div",{staticClass:"grd-row-col-3-6 align"},[n("div",{staticClass:"custom-select button"},[n("select",{directives:[{name:"model",rawName:"v-model",value:t.candleSizeUnit,expression:"candleSizeUnit"}],on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,function(t){return t.selected}).map(function(t){return"_value"in t?t._value:t.value});t.candleSizeUnit=e.target.multiple?n:n[0]}}},[n("option",[t._v("minutes")]),n("option",[t._v("hours")]),n("option",[t._v("days")])])])])])]),n("div",[n("label",{attrs:{for:"historySize"}},[t._v("Warmup period (in "+t._s(t.rawCandleSize)+" "+t._s(t.singularCandleSizeUnit)+" candles):")]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.historySize,expression:"historySize"}],domProps:{value:t.historySize},on:{input:function(e){e.target.composing||(t.historySize=e.target.value)}}}),n("em",{staticClass:"label-like"},[t._v("(will use "+t._s(t.humanizeDuration(t.candleSize*t.historySize*1e3*60))+" of data as history)")])])]),n("div",{staticClass:"grd-row-col-2-6 px1"},[n("div",[n("h3",[t._v("Parameters")]),n("p",[t._v(t._s(t.strategy)+" Parameters:")]),n("textarea",{directives:[{name:"model",rawName:"v-model",value:t.rawStratParams,expression:"rawStratParams"}],staticClass:"params",domProps:{value:t.rawStratParams},on:{input:function(e){e.target.composing||(t.rawStratParams=e.target.value)}}}),t.rawStratParamsError?n("p",{staticClass:"bg--red p1"},[t._v(t._s(t.rawStratParamsError.message))]):t._e()])])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"my2"},[t.data?t._e():n("div",{staticClass:"contain"},[n("h1",[t._v("Unknown Watcher")]),n("p",[t._v("Gekko doesn't know what whatcher this is...")])]),t.data?n("div",[n("h2",{staticClass:"contain"},[t._v("Market Watcher")]),n("div",{staticClass:"grd contain"},[n("h3",[t._v("Market")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Exchange")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.exchange))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Currency")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.currency))])]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Asset")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.data.watch.asset))])]),n("h3",[t._v("Statistics")]),t.isLoading?n("spinner"):t._e(),t.isLoading?t._e():[t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Watching since")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.firstCandle.start)))])]):t._e(),t.data.lastCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Received data until")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.fmt(t.data.lastCandle.start)))])]):t._e(),t.data.lastCandle&&t.data.firstCandle?n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-2-6"},[t._v("Data spanning")]),n("div",{staticClass:"grd-row-col-4-6"},[t._v(t._s(t.humanizeDuration(t.moment(t.data.lastCandle.start).diff(t.moment(t.data.firstCandle.start)))))])]):t._e()]],2),t.isLoading?t._e():[n("h3",{staticClass:"contain"},[t._v("Market graph")]),"fetching"===t.candleFetch?n("spinner"):t._e(),t.candles.length?[n("chart",{attrs:{data:t.chartData,height:500}})]:t._e()]],2):t._e()])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("h3",[t._v("Add an API key")]),n("p",[t._v("Make sure that the API key has the permissions to create and cancel orders and view balances.")]),n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Exchange")]),n("exchange-picker",{staticClass:"contain",attrs:{"only-tradable":"true"},on:{exchange:t.updateExchange}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Credentials")]),t._l(t.requires,function(e){return[n("label",[t._v(t._s(e))]),n("input",{directives:[{name:"model",rawName:"v-model",value:t.credentials[e],expression:"credentials[cred]"}],domProps:{value:t.credentials[e]},on:{input:function(n){n.target.composing||t.$set(t.credentials,e,n.target.value)}}})]})],2)]),n("div",{staticClass:"txt--center"},[n("a",{staticClass:"w100--s my1 btn--primary",attrs:{href:"#"},on:{click:function(e){e.preventDefault(),t.upload(e)}}},[t._v("Add")])])])},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"grd contain"},[n("div",{staticClass:"grd-row"},[n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("h3",[t._v("Market")]),n("market-picker",{staticClass:"contain",attrs:{"only-tradable":t.isTradebot},on:{market:t.updateMarketConfig}})],1),n("div",{staticClass:"grd-row-col-3-6 mx1"},[n("type-picker",{on:{type:t.updateType}})],1)]),"market watcher"!==t.type?[n("div",{staticClass:"hr"}),n("strat-picker",{staticClass:"contain my2",on:{stratConfig:t.updateStrat}}),"paper trader"===t.type?n("div",{staticClass:"hr"}):t._e(),"paper trader"===t.type?n("paper-trader",{on:{settings:t.updatePaperTrader}}):t._e()]:t._e()],2)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain"},[n("dataset-picker",{staticClass:"contain my2",on:{dataset:t.updateDataset}}),n("div",{staticClass:"hr"}),n("strat-picker",{staticClass:"contain my2",on:{stratConfig:t.updateStrat}}),n("div",{staticClass:"hr"}),n("paper-trader",{on:{settings:t.updatePaperTrader}}),n("div",{staticClass:"hr"})],1)},staticRenderFns:[]}},function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"contain roundtrips"},[n("h2",[t._v("Roundtrips")]),t.roundtrips.length?n("table",[n("thead",[t._m(0),t._l(t.roundtrips,function(e){return n("tr",[n("td",[t._v(t._s(t.fmt(e.entryAt)))]),n("td",[t._v(t._s(t.fmt(e.exitAt)))]),n("td",[t._v(t._s(t.diff(e.duration)))]),n("td",[t._v(t._s(t.round(e.entryBalance)))]),n("td",[t._v(t._s(t.round(e.exitBalance)))]),-1===Math.sign(e.pnl)?[n("td",{staticClass:"loss"},[t._v(t._s(Math.sign(e.pnl)*e.pnl.toFixed(2)))]),n("td",{staticClass:"loss"},[t._v(t._s(e.profit.toFixed(2))+"%")])]:[n("td",{staticClass:"profit"},[t._v(t._s(e.pnl.toFixed(2)))]),n("td",{staticClass:"profit"},[t._v(t._s(e.profit.toFixed(2))+"%")])]],2)})],2)]):t._e(),t.roundtrips.length?t._e():n("div",[n("p",[t._v("Not enough data to display")])])])},staticRenderFns:[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",[n("th",[t._v("Entry at (UTC)")]),n("th",[t._v("Exit at (UTC)")]),n("th",[t._v("Exposure")]),n("th",[t._v("Entry balance")]),n("th",[t._v("Exit balance")]),n("th",[t._v("P&L")]),n("th",[t._v("Profit")])])}]}},function(t,e,n){var r=n(84);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(85);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(86);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(87);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(88);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(89);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(90);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(91);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(92);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(93);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(94);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(95);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(96);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(97);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(98);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(99);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(100);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(101);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(102);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(103);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(104);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(105);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(106);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(107);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(108);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(109);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(110);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(111);"string"==typeof r&&(r=[[t.i,r,""]]);n(1)(r,{});r.locals&&(t.exports=r.locals)},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}}]);
\ No newline at end of file