You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
6.0 KiB

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-18a60fce"],{1148:function(e,t,r){"use strict";var o=r("a691"),n=r("1d80");e.exports="".repeat||function(e){var t=String(n(this)),r="",a=o(e);if(a<0||a==1/0)throw RangeError("Wrong number of repetitions");for(;a>0;(a>>>=1)&&(t+=t))1&a&&(r+=t);return r}},"159b":function(e,t,r){var o=r("da84"),n=r("fdbc"),a=r("17c2"),i=r("9112");for(var c in n){var s=o[c],l=s&&s.prototype;if(l&&l.forEach!==a)try{i(l,"forEach",a)}catch(u){l.forEach=a}}},"408a":function(e,t,r){var o=r("c6b6");e.exports=function(e){if("number"!=typeof e&&"Number"!=o(e))throw TypeError("Incorrect invocation");return+e}},"4e82":function(e,t,r){"use strict";var o=r("23e7"),n=r("1c0b"),a=r("7b0b"),i=r("d039"),c=r("b301"),s=[],l=s.sort,u=i((function(){s.sort(void 0)})),d=i((function(){s.sort(null)})),f=c("sort"),h=u||!d||f;o({target:"Array",proto:!0,forced:h},{sort:function(e){return void 0===e?l.call(a(this)):l.call(a(this),n(e))}})},a15b:function(e,t,r){"use strict";var o=r("23e7"),n=r("44ad"),a=r("fc6a"),i=r("b301"),c=[].join,s=n!=Object,l=i("join",",");o({target:"Array",proto:!0,forced:s||l},{join:function(e){return c.call(a(this),void 0===e?",":e)}})},b680:function(e,t,r){"use strict";var o=r("23e7"),n=r("a691"),a=r("408a"),i=r("1148"),c=r("d039"),s=1..toFixed,l=Math.floor,u=function(e,t,r){return 0===t?r:t%2===1?u(e,t-1,r*e):u(e*e,t/2,r)},d=function(e){var t=0,r=e;while(r>=4096)t+=12,r/=4096;while(r>=2)t+=1,r/=2;return t},f=s&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!c((function(){s.call({})}));o({target:"Number",proto:!0,forced:f},{toFixed:function(e){var t,r,o,c,s=a(this),f=n(e),h=[0,0,0,0,0,0],x="",p="0",b=function(e,t){var r=-1,o=t;while(++r<6)o+=e*h[r],h[r]=o%1e7,o=l(o/1e7)},y=function(e){var t=6,r=0;while(--t>=0)r+=h[t],h[t]=l(r/e),r=r%e*1e7},m=function(){var e=6,t="";while(--e>=0)if(""!==t||0===e||0!==h[e]){var r=String(h[e]);t=""===t?r:t+i.call("0",7-r.length)+r}return t};if(f<0||f>20)throw RangeError("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return String(s);if(s<0&&(x="-",s=-s),s>1e-21)if(t=d(s*u(2,69,1))-69,r=t<0?s*u(2,-t,1):s/u(2,t,1),r*=4503599627370496,t=52-t,t>0){b(0,r),o=f;while(o>=7)b(1e7,0),o-=7;b(u(10,o,1),0),o=t-1;while(o>=23)y(1<<23),o-=23;y(1<<o),b(1,1),y(2),p=m()}else b(0,r),b(1<<-t,0),p=m()+i.call("0",f);return f>0?(c=p.length,p=x+(c<=f?"0."+i.call("0",f-c)+p:p.slice(0,c-f)+"."+p.slice(c-f))):p=x+p,p}})},cec7:function(e,t,r){"use strict";r.r(t);r("99af"),r("4de4"),r("4160"),r("a15b"),r("d81d"),r("13d5"),r("4e82"),r("b680"),r("b64b"),r("e25e"),r("ac1f"),r("1276"),r("159b");var o=r("391c"),n={backgroundColor:"#21202D",legend:{data:["日K","MA5","MA10","MA20","MA30"],inactiveColor:"#777",textStyle:{color:"#fff"}},tooltip:{trigger:"axis",axisPointer:{animation:!1,type:"cross",lineStyle:{color:"#376df4",width:2,opacity:1}}},xAxis:[{type:"category",axisLine:{lineStyle:{color:"#8392A5"}}},{type:"category",axisLine:{lineStyle:{color:"#8392A5"}},gridIndex:1},{type:"category",axisLabel:{show:!1},gridIndex:2}],yAxis:[{scale:!0,axisLine:{lineStyle:{color:"#8392A5"}},splitLine:{show:!1}},{id:"sumY",scale:!0,axisLine:{lineStyle:{color:"#8392A5"}},splitLine:{show:!1},gridIndex:1},{scale:!0,axisLine:{show:!1,onZeroAxisIndex:"sumY"},axisLabel:{show:!1},axisTick:{show:!1},splitLine:{show:!1},gridIndex:2}],grid:[{left:"5%",right:"5%",height:"50%"},{left:"5%",right:"5%",bottom:"20%",height:"15%"},{left:"5%",right:"5%",bottom:"20%",height:"15%"}],dataZoom:[{textStyle:{color:"#8392A5"},startValue:200,endValue:250,handleIcon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4v1.3h1.3v-1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z",handleSize:"80%",dataBackground:{areaStyle:{color:"#8392A5"},lineStyle:{opacity:.8,color:"#8392A5"}},xAxisIndex:[0,1,2],handleStyle:{color:"#fff",shadowBlur:3,shadowColor:"rgba(0, 0, 0, 0.6)",shadowOffsetX:2,shadowOffsetY:2}},{type:"inside"}],animation:!1,series:[{type:"candlestick",name:"日K",itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}]};function a(e,t){return parseInt(e["日期"].split("-").join(""))-parseInt(t["日期"].split("-").join(""))}function i(e,t){for(var r=[],o=0,n=t.length;o<n;o++)if(o<e)r.push("-");else{for(var a=0,i=0;i<e;i++)a+=t[o-i]["收盘价"];r.push(+(a/e).toFixed(3))}return r}t["default"]=function(e){var t=e.data,r=e.daySum,c=e.ma,s=Object(o["cloneDeep"])(t);s.sort(a),n.xAxis.forEach((function(e){e.data=s.map((function(e){return e["日期"]}))}));var l=40;n.dataZoom[0].startValue=s.length-l,n.dataZoom[0].endValue=s.length,n.series=[],n.series.push({type:"candlestick",name:"日K",data:s.map((function(e){return[e["开盘价"],e["收盘价"],e["最低价"],e["最高价"]]})),itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}),n.legend.data=Object.keys(s[0]).map((function(e){if(e==="sum_".concat(r))return e})).filter((function(e){return void 0!=e})),n.series=n.series.concat(n.legend.data.map((function(e){return{name:e,type:"line",data:s.map((function(t){return t[e]})),smooth:!0,xAxisIndex:1,yAxisIndex:1}})));var u=n.series[1].data.reduce((function(e,t){return t>e?t:e}),-1/0),d=n.series[1].data.reduce((function(e,t){return t<e?t:e}),1/0),f=Math.max(Math.abs(u),Math.abs(d));n.yAxis[1].max=Math.abs(f),n.yAxis[1].min=-1*Math.abs(f),n.series=n.series.concat({name:"priceChange",type:"bar",data:s.map((function(e,t){return t?parseInt(100*(e["收盘价"]-s[t-1]["收盘价"]))/100:0})),xAxisIndex:2,yAxisIndex:2,label:{show:!1}});var h=n.series[2].data.reduce((function(e,t){return t>e?t:e}),-1/0),x=n.series[2].data.reduce((function(e,t){return t<e?t:e}),1/0),p=Math.max(Math.abs(h),Math.abs(x));return n.yAxis[2].max=Math.abs(p),n.yAxis[2].min=-1*Math.abs(p),n.series=n.series.concat(c.map((function(e){return{name:"MA".concat(e),type:"line",data:i(e,s),smooth:!0,lineStyle:{normal:{opacity:.5}}}}))),n}}}]);
//# sourceMappingURL=chunk-18a60fce.d9e66e9a.js.map