st-comp 0.0.204 → 0.0.205

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/es/ChartLayout.js +4 -4
  2. package/es/CustomFunction.cjs +1 -1
  3. package/es/CustomFunction.js +29 -29
  4. package/es/FactorWarning.cjs +1 -1
  5. package/es/FactorWarning.js +210 -201
  6. package/es/Kline.js +17 -17
  7. package/es/KlineBasic.js +26 -26
  8. package/es/KlineConfig.js +61 -61
  9. package/es/KlineNew.js +16 -16
  10. package/es/KlinePlus.js +19 -19
  11. package/es/Map.cjs +1 -1
  12. package/es/Map.js +102944 -1
  13. package/es/Pagination.js +73 -73
  14. package/es/PasswordPrompt.js +3 -3
  15. package/es/Table.js +38 -38
  16. package/es/User.js +44 -44
  17. package/es/VarSelectDialog.js +24 -24
  18. package/es/VarietyAutoComplete.js +10 -10
  19. package/es/VarietySearch.js +34 -34
  20. package/es/VarietyTextCopy.js +12 -12
  21. package/es/VirtualTable.js +70 -70
  22. package/es/{_initCloneObject-4ff4ab39.js → _initCloneObject-eaef9418.js} +7 -7
  23. package/es/{base-ff0e366f.js → base-a5af3db3.js} +40 -40
  24. package/es/{castArray-15070be9.js → castArray-7741a212.js} +1 -1
  25. package/es/{config-provider-1a9362d1.js → config-provider-b16efd62.js} +6 -6
  26. package/es/{debounce-e9e47f9a.js → debounce-8d53f4dd.js} +1 -1
  27. package/es/{dropdown-b3b26078.js → dropdown-a59bba73.js} +13 -13
  28. package/es/{el-autocomplete-a52b6885.js → el-autocomplete-ba808eb6.js} +16 -16
  29. package/es/{el-button-65aa0485.js → el-button-c95adb85.js} +39 -39
  30. package/es/{el-checkbox-feb78213.js → el-checkbox-7421ccd3.js} +31 -31
  31. package/es/{el-dialog-234e3137.js → el-dialog-41ab8417.js} +15 -15
  32. package/es/{el-divider-4fe55ebe.js → el-divider-4e059794.js} +1 -1
  33. package/es/{el-empty-ceecb81c.js → el-empty-33cb66f1.js} +5 -5
  34. package/es/{el-form-item-a68893fa.js → el-form-item-c53c374d.js} +34 -34
  35. package/es/{el-input-77c46a8a.js → el-input-2f75c4ba.js} +55 -55
  36. package/es/{el-input-number-23da18a4.js → el-input-number-5193fe6d.js} +31 -31
  37. package/es/{el-loading-025e8c34.js → el-loading-f6022062.js} +5 -5
  38. package/es/{el-menu-item-b1e678ba.js → el-menu-item-7e881203.js} +22 -22
  39. package/es/{el-message-box-db6c3469.js → el-message-box-a93d2f6a.js} +11 -11
  40. package/es/{el-message-8d817082.js → el-message-e544a8f5.js} +23 -23
  41. package/es/{el-overlay-3ebd4a6a.js → el-overlay-09ad71cd.js} +56 -56
  42. package/es/{el-popconfirm-5d93ad96.js → el-popconfirm-81dcd202.js} +20 -20
  43. package/es/{el-popper-ba55a170.js → el-popper-b4f97157.js} +109 -109
  44. package/es/{el-segmented-2813a6dc.js → el-segmented-b868d074.js} +8 -8
  45. package/es/{el-select-71af6fab.js → el-select-95627997.js} +64 -64
  46. package/es/{el-table-column-5d64176c.js → el-table-column-376cd907.js} +15 -15
  47. package/es/{el-tag-ca50befb.js → el-tag-66cab138.js} +15 -15
  48. package/es/{el-text-697ca5b5.js → el-text-ac60d0f2.js} +2 -2
  49. package/es/{index-923df02f.js → index-1f7d4f70.js} +2 -2
  50. package/es/{index-fca9441b.js → index-57672682.js} +3 -3
  51. package/es/{index-730c5d79.js → index-844bdd85.js} +34 -34
  52. package/es/{index-c30bd093.js → index-88546436.js} +17 -17
  53. package/es/{index-269b8a8c.js → index-960806da.js} +36 -36
  54. package/es/{index-8525fbd3.js → index-a871c3eb.js} +27 -27
  55. package/es/{index-93a8960e.js → index-d77a7336.js} +1 -1
  56. package/es/{index-56abb80d.js → index-d91dc23f.js} +12 -12
  57. package/es/{index-7b6ba27d.js → index-e5566b94.js} +43 -43
  58. package/es/raf-80ef0c0a.js +6 -0
  59. package/es/{scroll-41b4f625.js → scroll-679bd6bf.js} +5 -5
  60. package/es/style.css +1 -1
  61. package/es/{use-form-common-props-b342410c.js → use-form-common-props-815d48a6.js} +67 -67
  62. package/es/{use-global-config-409a5a22.js → use-global-config-b5e9d3d5.js} +14 -14
  63. package/es/{validator-46456823.js → validator-764a9db0.js} +1 -1
  64. package/es/{vnode-06571d5b.js → vnode-5ddb7ed1.js} +1 -1
  65. package/es/{zh-cn-87c8697d.js → zh-cn-e963c628.js} +2 -2
  66. package/lib/bundle.js +1 -1
  67. package/lib/bundle.umd.cjs +1 -1
  68. package/lib/{index-41eb55d2.js → index-ca5075d2.js} +16 -7
  69. package/lib/{python-89c64241.js → python-d88672d8.js} +1 -1
  70. package/lib/style.css +1 -1
  71. package/package.json +1 -1
  72. package/packages/FactorWarning/index.vue +14 -3
  73. package/src/pages/FactorWarning/index.vue +73 -84
  74. package/es/raf-8e05a7f4.js +0 -6
@@ -137,7 +137,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`),{initialZIndex:i,curr
137
137
  入参: ${JSON.stringify(u.method==="post"?u.data:u.params)}
138
138
  返参: ${JSON.stringify(l)}`)))},a=>{const{response:l={},config:u={}}=a;o instanceof Function&&o(a);let d=a.message;return d==="Network Error"?d="服务器网络故障":d.includes("timeout")?d="服务器接口超时":d.includes("Request failed with status code")&&(d="服务器接口"+d.substr(d.length-3)+"异常"),qE.error(d),Promise.reject(new Error(`服务器异常-${a.message} status: ${l==null?void 0:l.status}
139
139
  接口: ${u.url}
140
- 入参: ${JSON.stringify(u.method==="post"?u.data:u.params)}`))}),{get:(a,l={},u={})=>s({method:"GET",url:`${sJ(n)}${a.startsWith("/middleLayer/")?"":"/middleLayer/get"}${a}`,params:l,...u}),post:(a,l={},u={})=>s({method:"POST",url:`${sJ(n)}${a.startsWith("/middleLayer/")?"":"/middleLayer/post"}${a}`,data:l,...u})}},wet=Object.freeze(Object.defineProperty({__proto__:null,initRequest:Cet},Symbol.toStringTag,{value:"Module"}));var xet=Object.defineProperty,Det=(n,e,t)=>e in n?xet(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,_4=(n,e,t)=>Det(n,typeof e!="symbol"?e+"":e,t);class aJ{constructor(e,t={}){_4(this,"dom"),_4(this,"resizeRo"),_4(this,"callback"),_4(this,"visibilitychangeFn"),_4(this,"timer"),_4(this,"config",{debounce:50}),this.dom=e,this.config={...this.config,...t}}listen(e){this.callback=e;let t=!0;this.resizeRo=new ResizeObserver(()=>{if(t){t=!1;return}clearTimeout(this.timer),this.timer=setTimeout(()=>{this.callback&&this.callback(),clearTimeout(this.timer)},this.config.debounce)}),this.resizeRo.observe(this.dom),this.visibilitychangeFn=()=>{(document.visibilityState==="visible"||!document.hidden)&&this.callback&&this.callback()},document.addEventListener("visibilitychange",this.visibilitychangeFn)}dispose(){var e;(e=this.resizeRo)==null||e.disconnect(),document.removeEventListener("visibilitychange",this.visibilitychangeFn)}}const Net=n=>new aJ(n),Eet=Object.freeze(Object.defineProperty({__proto__:null,ResizeListener:aJ,addResizeListener:Net},Symbol.toStringTag,{value:"Module"}));`${new Date().getTime()}${Math.floor(Math.random()*1e9)}`;const ket=n=>{n?PH("token",n):console.error("token不能为空")},Let=n=>{n?PH("userData",n):console.error("用户数据不能为空")},lJ=()=>BH("token"),uJ=n=>{const e=BH("userData");return n?e==null?void 0:e[n]:e},Met=()=>!!lJ(),Tet=()=>{const n=uJ();return(n==null?void 0:n.username)==="admin"},cJ=(n="")=>location.href=`${location.origin}/login/index.html?url=${encodeURIComponent(n||location.href)}`,Aet=(n=!0,e)=>{if(VH("token"),VH("userData"),n){cJ();return}e&&(location.href=e)},Iet=Object.freeze(Object.defineProperty({__proto__:null,getToken:lJ,getUserData:uJ,isAdmin:Tet,isLogin:Met,login:cJ,loginout:Aet,setToken:ket,setUserData:Let},Symbol.toStringTag,{value:"Module"})),bl=yet,{initRequest:dJ}=wet,{addResizeListener:hJ}=Eet,{setToken:OLt,setUserData:GE,getToken:fJ,getUserData:R1,isLogin:pJ,isAdmin:FLt,login:Ret,loginout:YE}=Iet,F2=(n,e=500,t=!1)=>{let i=null;return function(...r){if(clearTimeout(i),t){const o=!i;i=setTimeout(()=>{i=null},e),o&&n.apply(this,r)}else i=setTimeout(()=>{n.apply(this,r)},e)}},Oet={__name:"index",props:{env:{type:Object,default:()=>({})}},setup(n){const e=r=>{const o=dJ(r,{handleReq:s=>{pJ()&&(s.headers.token=fJ(),s.headers.userId=R1("userId"))},handleRes:s=>{const{data:a}=s;if(a.code===401)return location.origin.includes("localhost")?location.href=`${location.origin}/#/404`:YE(),!0}});return{get:o.get,post:o.post}},t=n,i=c.reactive({env:t.env,request:e(t.env)});return c.watch(()=>t,r=>{Object.assign(i,toRefs(r)),console.log("已更新神兔组件库配置: ",i)},{deep:!0}),console.log("%c√ 已成功注入神兔组件库配置: ","color: green",i),c.provide("stConfig",i),(r,o)=>c.renderSlot(r.$slots,"default")}},Fet={install(n){n.component("st-configProvider",Oet)}},PLt="",Pet=vn({__name:"index",emits:["close","open"],setup(n,{emit:e}){const t=e,i=c.ref(),r=c.ref(),o=c.ref({x:0,y:0}),s=c.ref(!1),a=c.computed(()=>({display:s.value?"block":"none",top:`${o.value.y}px`,left:`${o.value.x}px`})),l=()=>{s.value=!1,t("close"),document.removeEventListener("click",l)},u=f=>{var p;(p=r.value)!=null&&p.contains(f.relatedTarget)||l()},d=async f=>{if(f.preventDefault(),s.value&&r.value){const _=r.value.getBoundingClientRect();if(f.clientX>=_.left&&f.clientX<=_.right&&f.clientY>=_.top&&f.clientY<=_.bottom)return}const p=i.value.getBoundingClientRect();let g=f.clientX-p.left,m=f.clientY-p.top;o.value={x:g,y:m},s.value=!0,t("open"),await c.nextTick(),h(),document.addEventListener("click",l)},h=()=>{if(!r.value||!i.value)return;const f=i.value.getBoundingClientRect(),p=r.value.getBoundingClientRect();let{x:g,y:m}=o.value;g+p.width>f.width&&(g=Math.max(0,g-p.width)),m+p.height>f.height&&(m=Math.max(0,m-p.height)),g<0&&(g=0),m<0&&(m=0),o.value={x:g,y:m}};return(f,p)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"contextmenuRef",ref:i,class:"contextmenu",onMouseleave:u,onContextmenu:d},[c.renderSlot(f.$slots,"default",{},void 0,!0),s.value?(c.openBlock(),c.createElementBlock("div",{key:0,ref_key:"contextmenuContentRef",ref:r,class:"contextmenu-popover",style:c.normalizeStyle(a.value),onContextmenu:p[0]||(p[0]=c.withModifiers(()=>{},["stop"]))},[c.renderSlot(f.$slots,"popover",{},void 0,!0)],36)):c.createCommentVNode("",!0)],544))}},[["__scopeId","data-v-34926651"]]),Bet={install(n){n.component("st-contextmenu",Pet)}},VLt="",zLt="",HLt="",jLt="",WLt="",$Lt="",ULt="",qLt="",KLt="",GLt="",YLt="",QLt="",ZLt="",XLt="",JLt="",eMt="",tMt="",nMt="",iMt="",rMt="",gJ=n=>(c.pushScopeId("data-v-ff7c4544"),n=n(),c.popScopeId(),n),Vet={class:"custom-function"},zet={class:"func-option"},Het={class:"icons"},jet={class:"custom-header"},Wet={class:"left"},$et=["id"],Uet={class:"right"},qet={class:"func-name"},Ket={class:"left"},Get=gJ(()=>c.createElementVNode("span",null,"函数名称:",-1)),Yet={class:"right"},Qet=gJ(()=>c.createElementVNode("div",{class:"tip-box"},"Tip: 公式里可以使用变量, 变量名命名格式: ${变量名}, 后续可在应用函数时填写具体值, 系统会自动换算",-1)),Zet={class:"dialog-footer"},Xet={class:"custom-header"},Jet={class:"left"},ett=["id"],ttt={class:"right"},ntt={class:"content"},itt={class:"dialog-footer"},rtt=vn({__name:"index",props:{size:{type:String,default:"small"},selectWidth:{type:String,default:"200px"}},emits:["insert"],setup(n,{emit:e}){const{request:t}=c.inject("stConfig"),i=c.ref(null),r=c.ref(null),o=e,s=c.ref(null),a=c.ref(""),l=c.ref([]),u=c.ref(!1),d=c.reactive({id:null,funcName:"",funcExpression:""}),h=c.ref(!1),f=c.ref(!1),p=c.ref(!1),g=c.reactive({result:null,detail:"",code:""}),m=async()=>{const{body:E}=await t.post("/common/qt/querySearchFunctions");if(l.value=E??[],s.value===null)a.value="";else{const k=l.value.find(({id:A})=>A===s.value);a.value=k?k.funcName:""}},_=E=>{var k;E?s.value=(k=l.value.find(A=>A.funcName===E))==null?void 0:k.id:s.value=null},b=async E=>{await t.post("/common/qt/deleteSearchFunctionById",{id:E.id}),m()},C=(E,k)=>{switch(!!E){case!1:{Object.assign(d,{id:null,funcName:"",funcExpression:""});break}case!0:{Object.assign(d,{id:E.id,funcName:E.funcName,funcExpression:E.funcExpression});break}}k&&(d.id=null,d.funcName=`${d.funcName}-复制`),u.value=!0},y=async()=>{try{if(h.value=!0,d.funcExpression=i.value.getValue(),!d.funcName)return An.error("函数名称不可为空");if(!d.funcExpression)return An.error("函数内容不可为空");await t.post("/common/qt/saveOrUpdateSearchFunction",d),An.success("操作成功"),u.value=!1,await m()}finally{h.value=!1}},v=()=>{if(!a.value)return An.error("请先选择自定义函数后, 再执行插入");const{funcName:E,funcExpression:k}=l.value.find(A=>A.funcName===a.value);o("insert",E,k)},w=E=>{const k=/\$\{([^}]*)\}/g,A=[];let R;for(;(R=k.exec(E))!==null;)A.push(R[1]);return[...new Set(A)]},x=(E,k)=>E.replace(/\$\{([^}]*)\}/g,(A,R)=>k[R]!==void 0?k[R]:A),S=E=>new Promise(k=>{const A=c.ref(E.reduce((M,O)=>(M[O]="",M),{})),R=c.ref({}),B=()=>{let M=!0;const O={};return E.forEach(F=>{var $;($=A.value[F])!=null&&$.trim()||(O[F]=`请输入${F}的值`,M=!1)}),R.value=O,M},I={setup(){return()=>c.h("div",[c.h(Hh,{model:A.value},()=>E.map(M=>c.h(jh,{label:`${M}: `,prop:M,error:R.value[M],"label-width":"90px"},()=>c.h(xs,{modelValue:A.value[M],"onUpdate:modelValue":O=>{A.value[M]=O,R.value[M]&&delete R.value[M]},placeholder:`请输入 ${M} 的值`,status:R.value[M]?"error":""}))))])}};lD({title:"填写变量值用于接口测试",message:c.h(I),showCancelButton:!0,confirmButtonText:"确定",cancelButtonText:"取消",customClass:"variable-input-dialog",beforeClose:async(M,O,F)=>{M!=="confirm"&&(k(!1),F()),await c.nextTick(),B()&&(k({...A.value}),F())}}).catch(()=>k(!1))}),N=async()=>{try{p.value=!0;let E=i.value.getValue();if(!E)return An.error("函数内容不可为空");if(/\$\{[^}]*\}/.test(E)){const B=w(E),I=await S(B);if(!I)return;E=x(E,I)}const{body:k}=await t.post("/common/qt/testFactorSelect",{factorSelectExpr:E}),{result:A,detail:R}=k;Object.assign(g,{result:A,detail:R,code:E}),A===1?An.success("测试通过"):(An.error("测试未能通过"),f.value=!0)}finally{p.value=!1}},D=()=>{if(g.result===null)return An.warning("请先进行测试, 等待测试完成后可查看日志");f.value=!0},L=()=>{r.value.open(i.value)};return c.onMounted(()=>{m()}),c.watch(()=>u.value,E=>{switch(E){case!0:{c.nextTick(()=>{var k,A;(k=i.value)==null||k.setValue(d.funcExpression),(A=i.value)==null||A.resize()}),Object.assign(g,{result:null,detail:""});break}case!1:{r.value.close();break}}}),(E,k)=>{const A=fn,R=CS,B=Gl,I=Kl,M=so,O=xs,F=c.resolveComponent("st-monacoEditor"),$=ql,Y=s1,U=nS,z=c.resolveComponent("st-varSelectDialog");return c.openBlock(),c.createElementBlock("div",Vet,[c.createVNode(I,{modelValue:a.value,"onUpdate:modelValue":k[0]||(k[0]=ne=>a.value=ne),size:n.size,placeholder:"自定义函数","no-match-text":"无匹配选项","no-data-text":"无选项数据",clearable:"",filterable:"",onChange:_,style:c.normalizeStyle({width:n.selectWidth})},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(l.value,ne=>(c.openBlock(),c.createBlock(B,{key:ne.id,label:ne.funcName,value:ne.funcName,onClick:v},{default:c.withCtx(()=>[c.createElementVNode("div",zet,[c.createElementVNode("span",null,c.toDisplayString(ne.funcName),1),c.createElementVNode("div",Het,[c.createVNode(A,{onClick:c.withModifiers(le=>C(ne,!0),["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(Mge))]),_:2},1032,["onClick"]),c.createVNode(A,{onClick:c.withModifiers(le=>C(ne),["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(Rge))]),_:2},1032,["onClick"]),c.createVNode(R,{title:"确认是否删除?","confirm-button-text":"确认","cancel-button-text":"取消",onConfirm:le=>b(ne)},{reference:c.withCtx(()=>[c.createVNode(A,{onClick:c.withModifiers(()=>{},["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(kge))]),_:1})]),_:2},1032,["onConfirm"])])])]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","size","style"]),c.createVNode(M,{type:"primary",size:n.size,onClick:v},{default:c.withCtx(()=>[c.createTextVNode(" 插入 ")]),_:1},8,["size"]),c.createVNode(M,{type:"primary",size:n.size,onClick:k[1]||(k[1]=ne=>C())},{default:c.withCtx(()=>[c.createTextVNode(" 新建 ")]),_:1},8,["size"]),c.createVNode($,{"modal-class":"add-or-edit-dialog",modelValue:u.value,"onUpdate:modelValue":k[4]||(k[4]=ne=>u.value=ne),width:"1000","align-center":"","append-to-body":"",draggable:"",overflow:"",modal:!1,"modal-penetrable":!0,"show-close":!1},{header:c.withCtx(({titleId:ne,titleClass:le})=>[c.createElementVNode("div",jet,[c.createElementVNode("div",Wet,[c.createElementVNode("span",{id:ne,class:c.normalizeClass(le)},c.toDisplayString(d.id?"编辑自定义函数":"新建自定义函数"),11,$et)]),c.createElementVNode("div",Uet,[c.createVNode(M,{size:"small",type:"primary",onClick:L},{default:c.withCtx(()=>[c.createTextVNode(" 变量选择器 ")]),_:1}),c.createVNode(A,{onClick:k[2]||(k[2]=ue=>u.value=!1)},{default:c.withCtx(()=>[c.createVNode(c.unref(r1))]),_:1})])])]),footer:c.withCtx(()=>[c.createElementVNode("div",Zet,[c.createVNode(M,{type:"primary",loading:h.value,onClick:y},{default:c.withCtx(()=>[c.createTextVNode(" 确定 ")]),_:1},8,["loading"])])]),default:c.withCtx(()=>[c.createElementVNode("div",qet,[c.createElementVNode("div",Ket,[Get,c.createVNode(O,{modelValue:d.funcName,"onUpdate:modelValue":k[3]||(k[3]=ne=>d.funcName=ne)},null,8,["modelValue"])]),c.createElementVNode("div",Yet,[c.createVNode(M,{type:"primary",loading:p.value,onClick:N},{default:c.withCtx(()=>[c.createTextVNode(" 测试 ")]),_:1},8,["loading"]),c.createVNode(M,{icon:c.unref(Age),onClick:D},{default:c.withCtx(()=>[c.createTextVNode(" 日志明细 ")]),_:1},8,["icon"])])]),Qet,c.createVNode(F,{ref_key:"stMonacoEditorRef",ref:i,language:"lua",style:{width:"968px",height:"400px"}},null,512)]),_:1},8,["modelValue"]),c.createVNode($,{"modal-class":"log-dialog",modelValue:f.value,"onUpdate:modelValue":k[7]||(k[7]=ne=>f.value=ne),width:"830","align-center":"","append-to-body":"",draggable:"",overflow:"",modal:!1,"modal-penetrable":!0,"show-close":!1},{header:c.withCtx(({titleId:ne,titleClass:le})=>[c.createElementVNode("div",Xet,[c.createElementVNode("div",Jet,[c.createElementVNode("span",{id:ne,class:c.normalizeClass(le)}," 日志明细 ",10,ett)]),c.createElementVNode("div",ttt,[c.createVNode(A,{onClick:k[5]||(k[5]=ue=>f.value=!1)},{default:c.withCtx(()=>[c.createVNode(c.unref(r1))]),_:1})])])]),footer:c.withCtx(()=>[c.createElementVNode("div",itt,[c.createVNode(M,{onClick:k[6]||(k[6]=ne=>f.value=!1)},{default:c.withCtx(()=>[c.createTextVNode(" 关闭 ")]),_:1})])]),default:c.withCtx(()=>[c.createElementVNode("div",ntt,[c.createVNode(Y,{class:"code",height:"600px"},{default:c.withCtx(()=>[c.createElementVNode("pre",null,c.toDisplayString(g.code),1)]),_:1}),c.createVNode(U,{direction:"vertical"}),c.createVNode(Y,{height:"600px"},{default:c.withCtx(()=>[c.createElementVNode("pre",{class:c.normalizeClass(g.result===1?"success-log":"error-log")},c.toDisplayString(g.result===1?"测试通过 √":g.detail),3)]),_:1})])]),_:1},8,["modelValue"]),c.createVNode(z,{ref_key:"stVarSelectDialogRef",ref:r},null,512)])}}},[["__scopeId","data-v-ff7c4544"]]),ott={install(n){n.component("st-customFunction",rtt)}},sMt="",aMt="",lMt="",uMt="",cMt="",dMt="",hMt="",fMt="",pMt="";var QE={name:"zh-cn",el:{breadcrumb:{label:"面包屑"},colorpicker:{confirm:"确定",clear:"清空",defaultLabel:"颜色选择器",description:"当前颜色 {color},按 Enter 键选择新颜色",alphaLabel:"选择透明度的值"},datepicker:{now:"此刻",today:"今天",cancel:"取消",clear:"清空",confirm:"确定",dateTablePrompt:"使用方向键与 Enter 键可选择日期",monthTablePrompt:"使用方向键与 Enter 键可选择月份",yearTablePrompt:"使用方向键与 Enter 键可选择年份",selectedDate:"已选日期",selectDate:"选择日期",selectTime:"选择时间",startDate:"开始日期",startTime:"开始时间",endDate:"结束日期",endTime:"结束时间",prevYear:"前一年",nextYear:"后一年",prevMonth:"上个月",nextMonth:"下个月",year:"年",month1:"1 月",month2:"2 月",month3:"3 月",month4:"4 月",month5:"5 月",month6:"6 月",month7:"7 月",month8:"8 月",month9:"9 月",month10:"10 月",month11:"11 月",month12:"12 月",weeks:{sun:"日",mon:"一",tue:"二",wed:"三",thu:"四",fri:"五",sat:"六"},weeksFull:{sun:"星期日",mon:"星期一",tue:"星期二",wed:"星期三",thu:"星期四",fri:"星期五",sat:"星期六"},months:{jan:"一月",feb:"二月",mar:"三月",apr:"四月",may:"五月",jun:"六月",jul:"七月",aug:"八月",sep:"九月",oct:"十月",nov:"十一月",dec:"十二月"}},inputNumber:{decrease:"减少数值",increase:"增加数值"},select:{loading:"加载中",noMatch:"无匹配数据",noData:"无数据",placeholder:"请选择"},dropdown:{toggleDropdown:"切换下拉选项"},mention:{loading:"加载中"},cascader:{noMatch:"无匹配数据",loading:"加载中",placeholder:"请选择",noData:"暂无数据"},pagination:{goto:"前往",pagesize:"条/页",total:"共 {total} 条",pageClassifier:"页",page:"页",prev:"上一页",next:"下一页",currentPage:"第 {pager} 页",prevPages:"向前 {pager} 页",nextPages:"向后 {pager} 页",deprecationWarning:"你使用了一些已被废弃的用法,请参考 el-pagination 的官方文档"},dialog:{close:"关闭此对话框"},drawer:{close:"关闭此对话框"},messagebox:{title:"提示",confirm:"确定",cancel:"取消",error:"输入的数据不合法!",close:"关闭此对话框"},upload:{deleteTip:"按 Delete 键可删除",delete:"删除",preview:"查看图片",continue:"继续上传"},slider:{defaultLabel:"滑块介于 {min} 至 {max}",defaultRangeStartLabel:"选择起始值",defaultRangeEndLabel:"选择结束值"},table:{emptyText:"暂无数据",confirmFilter:"筛选",resetFilter:"重置",clearFilter:"全部",sumText:"合计"},tour:{next:"下一步",previous:"上一步",finish:"结束导览",close:"关闭此对话框"},tree:{emptyText:"暂无数据"},transfer:{noMatch:"无匹配数据",noData:"无数据",titles:["列表 1","列表 2"],filterPlaceholder:"请输入搜索内容",noCheckedFormat:"共 {total} 项",hasCheckedFormat:"已选 {checked}/{total} 项"},image:{error:"加载失败"},pageHeader:{title:"返回"},popconfirm:{confirmButtonText:"确定",cancelButtonText:"取消"},carousel:{leftArrow:"上一张幻灯片",rightArrow:"下一张幻灯片",indicator:"幻灯片切换至索引 {index}"}}};const stt={ruleFormPrice:!0,ruleFormMark:!0,tableStatus:!0,tableCreateTime:!0,tableMark:!0,tableEnable:!0},gMt="",f_=n=>(c.pushScopeId("data-v-b57c57a6"),n=n(),c.popScopeId(),n),att={class:"st-factorWarning"},ltt={class:"custom-header"},utt=f_(()=>c.createElementVNode("span",{style:{"margin-right":"4px"}},"因子预警",-1)),ctt={class:"factor-name"},dtt=["onClick"],htt={class:"factor-name"},ftt=["onClick"],ptt={style:{display:"flex","align-items":"start"}},gtt={key:0,style:{flex:"1"}},mtt=f_(()=>c.createElementVNode("span",{style:{margin:"0 5px"}},"~",-1)),btt={key:0,style:{color:"#f56c6c"}},_tt={key:1,style:{color:"#67c23a"}},ytt={key:0},vtt={key:1},Ctt={key:2},wtt={class:"shortcut-title"},xtt=f_(()=>c.createElementVNode("span",null,"我的配置",-1)),Stt={class:"shortcut-config"},Dtt={key:1,class:"empty"},Ntt={class:"shortcut-title"},Ett=f_(()=>c.createElementVNode("span",null,"新增配置",-1)),ktt={class:"custom-footer"},Ltt=vn({__name:"index",props:c.mergeModels({title:{type:[String,null],default:null},moreFactorOptions:{type:Array,default:()=>[]},emptyFactorOptions:{type:Array,default:()=>[]},tableData:{type:Array,default:()=>[]},shortcutData:{type:Array,default:()=>[]},showConfig:{type:Object,default:()=>({})},allowOperation:{type:Boolean,default:!0}},{visible:{default:!1},visibleModifiers:{}}),emits:c.mergeModels(["add","delete","enabled","closed","shortcutAdd","shortcutDelete"],["update:visible"]),setup(n,{emit:e}){const t=c.ref("ruleForm"),i=c.useModel(n,"visible"),r=e,o=n,s=Object.assign(stt,o.showConfig),a=c.ref(null),l=c.ref({factorType:1,factorSelectedList:[],totalCount:1,minPrice:null,maxPrice:null,mark:null}),u=c.ref({factorType:[{required:!0,message:"请选择交易类型",trigger:"blur"}],factorSelectedList:[{required:!0,message:"请选择预警因子",trigger:"blur"}],totalCount:[{required:!0,message:"请填写预警次数",trigger:"blur"}]}),d=c.ref(null),h=c.ref({shortcutName:null,factorType:1,factorSelectedList:[],totalCount:1}),f=c.ref({factorType:[{required:!0,message:"请选择交易类型",trigger:"blur"}],factorSelectedList:[{required:!0,message:"请选择预警因子",trigger:"blur"}],totalCount:[{required:!0,message:"请填写预警次数",trigger:"blur"}],shortcutName:[{required:!0,message:"请填写配置名称",trigger:"blur"}]}),p=()=>{l.value={factorType:1,factorSelectedList:[],totalCount:1,minPrice:null,maxPrice:null,mark:null},h.value={shortcutName:null,factorType:1,factorSelectedList:[],totalCount:1}},g=async v=>{Object.assign(l.value,{factorSelectedList:[v],totalCount:3});const w={factorSelectedList:l.value.factorSelectedList.map(S=>({factorName:S,...l.value}))},x=()=>{const S=l.value.factorType;p(),l.value.factorType=S};_(a.value,w,x)},m=async v=>{const w=JSON.parse(v.data);Object.assign(l.value,{factorType:w.factorType,factorSelectedList:w.factorSelectedList,totalCount:w.totalCount});const x={factorSelectedList:l.value.factorSelectedList.map(N=>{let D=w.totalCount;const L=o.tableData.find(({factorExtendName:E})=>E===N);if(L){const E=L.totalCount-L.currentCount;E===0?D=w.totalCount:D=Math.min(w.totalCount,10-E>=0?10-E:0)}return{factorName:N,...l.value,totalCount:D}})},S=()=>p();_(a.value,x,S)},_=F2(async(v,w,x)=>{v&&await v.validate(S=>{if(!S)return!1;const N=w??{factorSelectedList:l.value.factorSelectedList.map(D=>({factorName:D,...l.value}))};r("add",N),x?x():i.value=!1})},200),b=async v=>{v&&await v.validate(w=>{if(!w)return!1;const x={shortcutName:h.value.shortcutName,data:JSON.stringify(h.value)};r("shortcutAdd",x),p()})},C=v=>{h.value=JSON.parse(v.data)},y=v=>{lD.confirm(`是否确认删除配置: ${v.shortcutName} ?`,"删除提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>r("shortcutDelete",v))};return c.watch(()=>i.value,v=>{v&&(t.value=o.allowOperation?"ruleForm":"table",p())},{immediate:!0}),(v,w)=>{const x=LH,S=so,N=jh,D=u1,L=mV,E=R6,k=G6,A=xs,R=Hh,B=QS,I=CS,M=YS,O=fn,F=xa,$=k6,Y=ql,U=Xx;return c.openBlock(),c.createElementBlock("div",att,[c.createVNode(U,{locale:c.unref(QE)},{default:c.withCtx(()=>[c.createVNode(Y,{modelValue:i.value,"onUpdate:modelValue":w[17]||(w[17]=z=>i.value=z),width:"1020","align-center":"","destroy-on-close":"",onClosed:w[18]||(w[18]=z=>r("closed"))},{header:c.withCtx(({close:z,titleId:ne,titleClass:le})=>[c.createElementVNode("div",ltt,[c.createElementVNode("div",{class:c.normalizeClass(le)},[utt,c.createElementVNode("span",null,c.toDisplayString(n.title),1)],2),c.createVNode(x,{modelValue:t.value,"onUpdate:modelValue":w[0]||(w[0]=ue=>t.value=ue),size:"default",options:[{label:"添加",value:"ruleForm",disabled:!n.allowOperation},{label:"管理",value:"table",disabled:!1},{label:"快捷配置",value:"shortcut",disabled:!n.allowOperation}]},null,8,["modelValue","options"])])]),footer:c.withCtx(()=>[c.createElementVNode("div",ktt,[c.createVNode(S,{size:"default",onClick:w[14]||(w[14]=z=>i.value=!1)},{default:c.withCtx(()=>[c.createTextVNode("关闭")]),_:1}),t.value==="ruleForm"?(c.openBlock(),c.createBlock(S,{key:0,size:"default",type:"primary",onClick:w[15]||(w[15]=z=>c.unref(_)(a.value))},{default:c.withCtx(()=>[c.createTextVNode(" 确认 ")]),_:1})):c.createCommentVNode("",!0),t.value==="shortcut"?(c.openBlock(),c.createBlock(S,{key:1,size:"default",type:"primary",onClick:w[16]||(w[16]=z=>b(d.value))},{default:c.withCtx(()=>[c.createTextVNode(" 保存配置 ")]),_:1})):c.createCommentVNode("",!0)])]),default:c.withCtx(()=>[t.value==="ruleForm"?(c.openBlock(),c.createBlock(R,{key:0,ref_key:"ruleFormRef",ref:a,model:l.value,rules:u.value,size:"default","label-width":"90px"},{default:c.withCtx(()=>[c.createVNode(N,{label:"交易类型:",prop:"factorType"},{default:c.withCtx(()=>[c.createVNode(S,{type:"danger",plain:l.value.factorType!==1,onClick:w[1]||(w[1]=()=>{l.value.factorType===-1&&(l.value.factorSelectedList=[]),l.value.factorType=1})},{default:c.withCtx(()=>[c.createTextVNode(" 多 ")]),_:1},8,["plain"]),c.createVNode(S,{type:"success",plain:l.value.factorType!==-1,onClick:w[2]||(w[2]=()=>{l.value.factorType===1&&(l.value.factorSelectedList=[]),l.value.factorType=-1})},{default:c.withCtx(()=>[c.createTextVNode(" 空 ")]),_:1},8,["plain"])]),_:1}),c.createVNode(N,{label:"预警因子:",prop:"factorSelectedList"},{default:c.withCtx(()=>[c.createVNode(L,{modelValue:l.value.factorSelectedList,"onUpdate:modelValue":w[3]||(w[3]=z=>l.value.factorSelectedList=z)},{default:c.withCtx(()=>[l.value.factorType===1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.moreFactorOptions,(z,ne)=>(c.openBlock(),c.createElementBlock("div",{class:"factor-checkbox",key:ne},[c.createVNode(D,{label:z.factorTypeName,value:z.factorTypeName},{default:c.withCtx(()=>[c.createElementVNode("span",ctt,c.toDisplayString(z.factorTypeName),1)]),_:2},1032,["label","value"]),c.createElementVNode("span",{class:"tag-button",onClick:le=>g(z.factorTypeName)},"+3",8,dtt)]))),128)):c.createCommentVNode("",!0),l.value.factorType===-1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:1},c.renderList(n.emptyFactorOptions,(z,ne)=>(c.openBlock(),c.createElementBlock("div",{class:"factor-checkbox",key:ne},[c.createVNode(D,{label:z.factorTypeName,value:z.factorTypeName},{default:c.withCtx(()=>[c.createElementVNode("span",htt,c.toDisplayString(z.factorTypeName),1)]),_:2},1032,["label","value"]),c.createElementVNode("span",{class:"tag-button",onClick:le=>g(z.factorTypeName)},"+3",8,ftt)]))),128)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1}),c.createVNode(N,{label:"预警次数:",prop:"totalCount"},{default:c.withCtx(()=>[c.createElementVNode("div",ptt,[c.createVNode(E,{modelValue:l.value.totalCount,"onUpdate:modelValue":w[4]||(w[4]=z=>l.value.totalCount=z),min:1,"controls-position":"right",style:{"margin-right":"20px"}},null,8,["modelValue"]),n.shortcutData.length?(c.openBlock(),c.createElementBlock("div",gtt,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.shortcutData,z=>(c.openBlock(),c.createBlock(S,{key:z.id,onClick:ne=>m(z),style:{margin:"0 12px 4px 0"}},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(z.shortcutName),1)]),_:2},1032,["onClick"]))),128))])):(c.openBlock(),c.createBlock(k,{key:1,type:"primary",style:{cursor:"pointer"},onClick:w[5]||(w[5]=()=>t.value="shortcut")},{default:c.withCtx(()=>[c.createTextVNode(" 暂无快捷配置, 是否点击前往自定义配置? ")]),_:1}))])]),_:1}),c.unref(s).ruleFormPrice?(c.openBlock(),c.createBlock(N,{key:0,label:"价格范围:"},{default:c.withCtx(()=>[c.createVNode(E,{modelValue:l.value.minPrice,"onUpdate:modelValue":w[6]||(w[6]=z=>l.value.minPrice=z),min:-999,placeholder:"请输入",max:999,"controls-position":"right"},null,8,["modelValue"]),mtt,c.createVNode(E,{modelValue:l.value.maxPrice,"onUpdate:modelValue":w[7]||(w[7]=z=>l.value.maxPrice=z),placeholder:"请输入",min:-999,max:999,"controls-position":"right"},null,8,["modelValue"])]),_:1})):c.createCommentVNode("",!0),c.unref(s).ruleFormMark?(c.openBlock(),c.createBlock(N,{key:1,label:"备注:"},{default:c.withCtx(()=>[c.createVNode(A,{modelValue:l.value.mark,"onUpdate:modelValue":w[8]||(w[8]=z=>l.value.mark=z),type:"textarea",placeholder:"请输入关键字",rows:2,style:{width:"380px"}},null,8,["modelValue"])]),_:1})):c.createCommentVNode("",!0)]),_:1},8,["model","rules"])):c.createCommentVNode("",!0),t.value==="table"?(c.openBlock(),c.createBlock(M,{key:1,data:n.tableData,size:"small"},{default:c.withCtx(()=>[c.createVNode(B,{label:"预警周期",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.freqName||"-"),1)]),_:1}),c.createVNode(B,{label:"交易类型",width:"70"},{default:c.withCtx(z=>[z.row.factorExtendValue==1?(c.openBlock(),c.createElementBlock("span",btt,"多")):(c.openBlock(),c.createElementBlock("span",_tt,"空"))]),_:1}),c.createVNode(B,{label:"预警因子"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.factorExtendName||"-"),1)]),_:1}),c.createVNode(B,{label:"预警次数",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(`${z.row.currentCount} / ${z.row.totalCount}`),1)]),_:1}),c.unref(s).tableStatus?(c.openBlock(),c.createBlock(B,{key:0,label:"状态",width:"70"},{default:c.withCtx(z=>[c.createElementVNode("div",null,[z.row.enable===1?(c.openBlock(),c.createElementBlock("span",ytt,"未触发")):z.row.enable===2?(c.openBlock(),c.createElementBlock("span",vtt,"已触发")):(c.openBlock(),c.createElementBlock("span",Ctt,"-"))])]),_:1})):c.createCommentVNode("",!0),c.unref(s).tableCreateTime?(c.openBlock(),c.createBlock(B,{key:1,label:"设置时间",width:"136"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.createdTime||"-"),1)]),_:1})):c.createCommentVNode("",!0),c.unref(s).tableMark?(c.openBlock(),c.createBlock(B,{key:2,label:"备注",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.mark||"-"),1)]),_:1})):c.createCommentVNode("",!0),n.allowOperation?(c.openBlock(),c.createBlock(B,{key:3,label:"操作",width:"140"},{default:c.withCtx(z=>[c.unref(s).tableEnable?(c.openBlock(),c.createBlock(S,{key:0,disabled:z.row.currentCount!==z.row.totalCount,size:"small",onClick:ne=>r("enabled",z.row)},{default:c.withCtx(()=>[c.createTextVNode(" 启用 ")]),_:2},1032,["disabled","onClick"])):c.createCommentVNode("",!0),c.createVNode(I,{title:"确定删除?",onConfirm:ne=>r("delete",z.row)},{reference:c.withCtx(()=>[c.createVNode(S,{size:"small"},{default:c.withCtx(()=>[c.createTextVNode("删除")]),_:1})]),_:2},1032,["onConfirm"])]),_:1})):c.createCommentVNode("",!0)]),_:1},8,["data"])):c.createCommentVNode("",!0),t.value==="shortcut"?(c.openBlock(),c.createElementBlock(c.Fragment,{key:2},[c.createElementVNode("div",wtt,[xtt,c.createVNode(F,{effect:"dark",content:"如有配置数据, 可点击查看该配置的具体信息",placement:"right-start"},{default:c.withCtx(()=>[c.createVNode(O,null,{default:c.withCtx(()=>[c.createVNode(c.unref(Ed))]),_:1})]),_:1})]),c.createElementVNode("div",Stt,[n.shortcutData.length?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.shortcutData,z=>(c.openBlock(),c.createBlock($,{key:z.id,type:"primary",size:"default",closable:"",onClick:ne=>C(z),onClose:ne=>y(z)},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(z.shortcutName),1)]),_:2},1032,["onClick","onClose"]))),128)):(c.openBlock(),c.createElementBlock("span",Dtt,"暂无数据"))]),c.createElementVNode("div",Ntt,[Ett,c.createVNode(F,{effect:"dark",content:"同名配置将会进行覆盖",placement:"right-start"},{default:c.withCtx(()=>[c.createVNode(O,null,{default:c.withCtx(()=>[c.createVNode(c.unref(Ed))]),_:1})]),_:1})]),c.createVNode(R,{ref_key:"shortcut_ruleFormRef",ref:d,model:h.value,rules:f.value,"label-width":"90px",size:"default"},{default:c.withCtx(()=>[c.createVNode(N,{label:"配置名称:",prop:"shortcutName"},{default:c.withCtx(()=>[c.createVNode(A,{modelValue:h.value.shortcutName,"onUpdate:modelValue":w[9]||(w[9]=z=>h.value.shortcutName=z),maxlength:"6","show-word-limit":"",style:{width:"160px"}},null,8,["modelValue"])]),_:1}),c.createVNode(N,{label:"交易类型:",prop:"factorType"},{default:c.withCtx(()=>[c.createVNode(S,{type:"danger",plain:h.value.factorType!==1,onClick:w[10]||(w[10]=()=>{h.value.factorType===-1&&(h.value.factorSelectedList=[]),h.value.factorType=1})},{default:c.withCtx(()=>[c.createTextVNode(" 多 ")]),_:1},8,["plain"]),c.createVNode(S,{type:"success",plain:h.value.factorType!==-1,onClick:w[11]||(w[11]=()=>{h.value.factorType===1&&(h.value.factorSelectedList=[]),h.value.factorType=-1})},{default:c.withCtx(()=>[c.createTextVNode(" 空 ")]),_:1},8,["plain"])]),_:1}),c.createVNode(N,{label:"预警因子:",prop:"factorSelectedList"},{default:c.withCtx(()=>[c.createVNode(L,{modelValue:h.value.factorSelectedList,"onUpdate:modelValue":w[12]||(w[12]=z=>h.value.factorSelectedList=z)},{default:c.withCtx(()=>[h.value.factorType===1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.moreFactorOptions,(z,ne)=>(c.openBlock(),c.createBlock(D,{key:ne,label:z.factorTypeName,value:z.factorTypeName,style:{width:"200px"}},null,8,["label","value"]))),128)):c.createCommentVNode("",!0),h.value.factorType===-1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:1},c.renderList(n.emptyFactorOptions,(z,ne)=>(c.openBlock(),c.createBlock(D,{key:ne,label:z.factorTypeName,value:z.factorTypeName,style:{width:"200px"}},null,8,["label","value"]))),128)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1}),c.createVNode(N,{label:"预警次数:",prop:"totalCount"},{default:c.withCtx(()=>[c.createVNode(E,{modelValue:h.value.totalCount,"onUpdate:modelValue":w[13]||(w[13]=z=>h.value.totalCount=z),min:1,max:10,"controls-position":"right",style:{"margin-right":"20px"}},null,8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])],64)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1},8,["locale"])])}}},[["__scopeId","data-v-b57c57a6"]]),Mtt={install(n){n.component("st-factorWarning",Ltt)}},Ttt=c.defineComponent({__name:"index",props:{data:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})}},setup(n,{expose:e}){const t={tooltipFormatter:null,dataZoom:null,grid:{left:"60px",bottom:"20px",right:"0",top:0}};let i,r;const o=n,s=c.ref(),a=c.computed(()=>({...t,...o.config}));c.watch(()=>[o.data],()=>{l()},{deep:!0}),c.onMounted(()=>{i=qr.init(s.value),l();let u=!0;r=new ResizeObserver(()=>{if(u){u=null;return}i.resize()}),r.observe(s.value)}),c.onUnmounted(()=>{i.dispose(),r.disconnect(),r=null});const l=()=>{i.setOption({tooltip:{confine:!0,formatter:a.value.tooltipFormatter?u=>a.value.tooltipFormatter(u,o.data):null},grid:a.value.grid,xAxis:{type:"category",data:o.data.date},yAxis:{type:"category",inverse:!0,data:o.data.data.map(u=>u.name)},visualMap:{type:"piecewise",show:!1,inRange:[]},dataZoom:a.value.dataZoom,series:[{name:"热力图",type:"heatmap",info:o.data,data:o.data.data.reduce((u,d,h)=>[...u,...d.data.reduce((f,p,g)=>p===null?f:[...f,{value:[g,h,p.value],itemStyle:{color:p.color}}],[])],[]),label:{show:!1}}]})};return e({reset:()=>{l()}}),(u,d)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"chartRef",ref:s,class:"chart"},null,512))}}),bMt="",Att=vn(Ttt,[["__scopeId","data-v-4c74604d"]]),Itt={install(n){n.component("st-heatMap",Att)}},_Mt="",yMt="",Rtt={class:"st-kline-tips"},Ott={class:"st-kline-tips-row"},Ftt=c.defineComponent({__name:"index",props:{data:{type:Array,default:()=>[]}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",Rtt,[c.createElementVNode("div",Ott,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,i=>(c.openBlock(),c.createElementBlock("div",{class:"st-kline-tips-row-item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),256))])]))}}),vMt="",ZE=vn(Ftt,[["__scopeId","data-v-78aed210"]]),Ptt=c.defineComponent({__name:"index",emits:["closeContextMenuCallBack"],setup(n,{emit:e}){const t=e,i=c.ref(),r=c.ref(),o=c.ref({display:"none",top:"0px",left:"0px"}),s=()=>{o.value.display="none",t("closeContextMenuCallBack"),document.removeEventListener("click",s)},a=l=>{if(l.preventDefault(),l.stopPropagation(),o.value.display==="block"){const{offsetX:u,offsetY:d}=l,{offsetWidth:h,offsetHeight:f}=r.value;if(u<=h&&d<=f)return}i.value.click(),o.value={display:"block",top:`${l.offsetY}px`,left:`${l.offsetX}px`},c.nextTick(()=>{const{bottom:u,height:d,right:h,width:f}=r.value.getBoundingClientRect();u>window.innerHeight?o.value={display:"block",top:`${l.offsetY-d}px`,left:`${l.offsetX}px`}:h>window.innerWidth&&(o.value={display:"block",top:`${l.offsetY}px`,left:`${l.offsetX-f}px`})}),document.addEventListener("click",s)};return(l,u)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"contextmenuRef",ref:i,class:"contextmenu",onContextmenu:a,onMouseleave:s},[c.renderSlot(l.$slots,"default",{},void 0,!0),o.value.display!=="none"?(c.openBlock(),c.createElementBlock("div",{key:0,ref_key:"contextmenuContentRef",ref:r,class:"contextmenu-popover",style:c.normalizeStyle(o.value)},[c.renderSlot(l.$slots,"popover",{},void 0,!0)],4)):c.createCommentVNode("",!0)],544))}}),CMt="",Btt=vn(Ptt,[["__scopeId","data-v-249fd104"]]);var XE=function(){var n=typeof document<"u"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename<"u"&&(n=n||__filename),function(e){e=e||{};var t=typeof e<"u"?e:{},i,r;t.ready=new Promise(function(Ee,Te){i=Ee,r=Te});var o={},s;for(s in t)t.hasOwnProperty(s)&&(o[s]=t[s]);var a=function(Ee,Te){throw Te},l=!1,u=!1,d=!1,h=!1;l=typeof window=="object",u=typeof importScripts=="function",d=typeof process=="object"&&typeof process.versions=="object"&&typeof process.versions.node=="string",h=!l&&!d&&!u;var f="";function p(Ee){return t.locateFile?t.locateFile(Ee,f):f+Ee}var g,m,_,b;d?(u?f=require("path").dirname(f)+"/":f=__dirname+"/",g=function(Te,Ue){return _||(_=require("fs")),b||(b=require("path")),Te=b.normalize(Te),_.readFileSync(Te,Ue?null:"utf8")},m=function(Te){var Ue=g(Te,!0);return Ue.buffer||(Ue=new Uint8Array(Ue)),R(Ue.buffer),Ue},process.argv.length>1&&process.argv[1].replace(/\\/g,"/"),process.argv.slice(2),process.on("uncaughtException",function(Ee){if(!(Ee instanceof Ne))throw Ee}),process.on("unhandledRejection",fe),a=function(Ee){process.exit(Ee)},t.inspect=function(){return"[Emscripten Module object]"}):h?(typeof read<"u"&&(g=function(Te){return read(Te)}),m=function(Te){var Ue;return typeof readbuffer=="function"?new Uint8Array(readbuffer(Te)):(Ue=read(Te,"binary"),R(typeof Ue=="object"),Ue)},typeof scriptArgs<"u"&&scriptArgs,typeof quit=="function"&&(a=function(Ee){quit(Ee)}),typeof print<"u"&&(typeof console>"u"&&(console={}),console.log=print,console.warn=console.error=typeof printErr<"u"?printErr:print)):(l||u)&&(u?f=self.location.href:document.currentScript&&(f=document.currentScript.src),n&&(f=n),f.indexOf("blob:")!==0?f=f.substr(0,f.lastIndexOf("/")+1):f="",g=function(Te){var Ue=new XMLHttpRequest;return Ue.open("GET",Te,!1),Ue.send(null),Ue.responseText},u&&(m=function(Te){var Ue=new XMLHttpRequest;return Ue.open("GET",Te,!1),Ue.responseType="arraybuffer",Ue.send(null),new Uint8Array(Ue.response)})),t.print||console.log.bind(console);var C=t.printErr||console.warn.bind(console);for(s in o)o.hasOwnProperty(s)&&(t[s]=o[s]);o=null,t.arguments&&t.arguments,t.thisProgram&&t.thisProgram,t.quit&&(a=t.quit);var y=16;function v(Ee,Te){return Te||(Te=y),Math.ceil(Ee/Te)*Te}function w(Ee,Te){if(typeof WebAssembly.Function=="function"){for(var Ue={i:"i32",j:"i64",f:"f32",d:"f64"},tt={parameters:[],results:Te[0]=="v"?[]:[Ue[Te[0]]]},Ut=1;Ut<Te.length;++Ut)tt.parameters.push(Ue[Te[Ut]]);return new WebAssembly.Function(tt,Ee)}var Zt=[1,0,1,96],Lt=Te.slice(0,1),zt=Te.slice(1),nr={i:127,j:126,f:125,d:124};Zt.push(zt.length);for(var Ut=0;Ut<zt.length;++Ut)Zt.push(nr[zt[Ut]]);Lt=="v"?Zt.push(0):Zt=Zt.concat([1,nr[Lt]]),Zt[1]=Zt.length-2;var mi=new Uint8Array([0,97,115,109,1,0,0,0].concat(Zt,[2,7,1,1,101,1,102,0,0,7,5,1,1,102,0,0])),lr=new WebAssembly.Module(mi),e1=new WebAssembly.Instance(lr,{e:{f:Ee}}),t3=e1.exports.f;return t3}var x=[],S;function N(Ee,Te){var Ue=ve;if(!S){S=new WeakMap;for(var tt=0;tt<Ue.length;tt++){var Ut=Ue.get(tt);Ut&&S.set(Ut,tt)}}if(S.has(Ee))return S.get(Ee);var Zt;if(x.length)Zt=x.pop();else{Zt=Ue.length;try{Ue.grow(1)}catch(zt){throw zt instanceof RangeError?"Unable to grow wasm table. Set ALLOW_TABLE_GROWTH.":zt}}try{Ue.set(Zt,Ee)}catch(zt){if(!(zt instanceof TypeError))throw zt;var Lt=w(Ee,Te);Ue.set(Zt,Lt)}return S.set(Ee,Zt),Zt}function D(Ee,Te){return N(Ee,Te)}var L;t.wasmBinary&&(L=t.wasmBinary);var E;t.noExitRuntime&&(E=t.noExitRuntime),typeof WebAssembly!="object"&&fe("no native wasm support detected");var k,ve,A=!1;function R(Ee,Te){Ee||fe("Assertion failed: "+Te)}function B(Ee){var Te=t["_"+Ee];return R(Te,"Cannot call unknown function "+Ee+", make sure it is exported"),Te}function I(Ee,Te,Ue,tt,Ut){var Zt={string:function(ya){var Sd=0;if(ya!=null&&ya!==0){var va=(ya.length<<2)+1;Sd=Fe(va),z(ya,Sd,va)}return Sd},array:function(ya){var Sd=Fe(ya.length);return ne(ya,Sd),Sd}};function Lt(ya){return Te==="string"?Y(ya):Te==="boolean"?!!ya:ya}var zt=B(Ee),nr=[],mi=0;if(tt)for(var lr=0;lr<tt.length;lr++){var e1=Zt[Ue[lr]];e1?(mi===0&&(mi=Jc()),nr[lr]=e1(tt[lr])):nr[lr]=tt[lr]}var t3=zt.apply(null,nr);return t3=Lt(t3),mi!==0&&Qa(mi),t3}var M=1;function O(Ee,Te){var Ue;return Te==M?Ue=Fe(Ee.length):Ue=qo(Ee.length),Ee.subarray||Ee.slice?oe.set(Ee,Ue):oe.set(new Uint8Array(Ee),Ue),Ue}var F=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0;function $(Ee,Te,Ue){for(var tt=Te+Ue,Ut=Te;Ee[Ut]&&!(Ut>=tt);)++Ut;if(Ut-Te>16&&Ee.subarray&&F)return F.decode(Ee.subarray(Te,Ut));for(var Zt="";Te<Ut;){var Lt=Ee[Te++];if(!(Lt&128)){Zt+=String.fromCharCode(Lt);continue}var zt=Ee[Te++]&63;if((Lt&224)==192){Zt+=String.fromCharCode((Lt&31)<<6|zt);continue}var nr=Ee[Te++]&63;if((Lt&240)==224?Lt=(Lt&15)<<12|zt<<6|nr:Lt=(Lt&7)<<18|zt<<12|nr<<6|Ee[Te++]&63,Lt<65536)Zt+=String.fromCharCode(Lt);else{var mi=Lt-65536;Zt+=String.fromCharCode(55296|mi>>10,56320|mi&1023)}}return Zt}function Y(Ee,Te){return Ee?$(oe,Ee,Te):""}function U(Ee,Te,Ue,tt){if(!(tt>0))return 0;for(var Ut=Ue,Zt=Ue+tt-1,Lt=0;Lt<Ee.length;++Lt){var zt=Ee.charCodeAt(Lt);if(zt>=55296&&zt<=57343){var nr=Ee.charCodeAt(++Lt);zt=65536+((zt&1023)<<10)|nr&1023}if(zt<=127){if(Ue>=Zt)break;Te[Ue++]=zt}else if(zt<=2047){if(Ue+1>=Zt)break;Te[Ue++]=192|zt>>6,Te[Ue++]=128|zt&63}else if(zt<=65535){if(Ue+2>=Zt)break;Te[Ue++]=224|zt>>12,Te[Ue++]=128|zt>>6&63,Te[Ue++]=128|zt&63}else{if(Ue+3>=Zt)break;Te[Ue++]=240|zt>>18,Te[Ue++]=128|zt>>12&63,Te[Ue++]=128|zt>>6&63,Te[Ue++]=128|zt&63}}return Te[Ue]=0,Ue-Ut}function z(Ee,Te,Ue){return U(Ee,oe,Te,Ue)}function ne(Ee,Te){X.set(Ee,Te)}var le=65536,ue,X,oe;function de(Ee){ue=Ee,t.HEAP8=X=new Int8Array(Ee),t.HEAP16=new Int16Array(Ee),t.HEAP32=new Int32Array(Ee),t.HEAPU8=oe=new Uint8Array(Ee),t.HEAPU16=new Uint16Array(Ee),t.HEAPU32=new Uint32Array(Ee),t.HEAPF32=new Float32Array(Ee),t.HEAPF64=new Float64Array(Ee)}var pe=5247776;t.___heap_base=5247776;var he=t.INITIAL_MEMORY||16777216;t.wasmMemory?k=t.wasmMemory:k=new WebAssembly.Memory({initial:he/le,maximum:he/le}),k&&(ue=k.buffer),he=ue.byteLength,de(ue);var ve=new WebAssembly.Table({initial:1,element:"anyfunc"}),Le=[],re=[],W=[],ee=[],te=!1;function J(){if(t.preRun)for(typeof t.preRun=="function"&&(t.preRun=[t.preRun]);t.preRun.length;)Z(t.preRun.shift());be(Le)}function ie(){te=!0,be(re)}function G(){be(W)}function Q(){if(t.postRun)for(typeof t.postRun=="function"&&(t.postRun=[t.postRun]);t.postRun.length;)P(t.postRun.shift());be(ee)}function Z(Ee){Le.unshift(Ee)}function P(Ee){ee.unshift(Ee)}var V=0,q=null;function K(Ee){V++,t.monitorRunDependencies&&t.monitorRunDependencies(V)}function ae(Ee){if(V--,t.monitorRunDependencies&&t.monitorRunDependencies(V),V==0&&q){var Te=q;q=null,Te()}}t.preloadedImages={},t.preloadedAudios={},t.preloadedWasm={},Z(Fl);function fe(Ee){t.onAbort&&t.onAbort(Ee),Ee+="",C(Ee),A=!0,Ee="abort("+Ee+"). Build with -s ASSERTIONS=1 for more info.";var Te=new WebAssembly.RuntimeError(Ee);throw r(Te),Te}function we(Ee,Te){return String.prototype.startsWith?Ee.startsWith(Te):Ee.indexOf(Te)===0}var _e="data:application/octet-stream;base64,";function xe(Ee){return we(Ee,_e)}var Se="file://";function $e(Ee){return we(Ee,Se)}var Ve="talib.wasm";xe(Ve)||(Ve=p(Ve));function Ie(){try{if(L)return new Uint8Array(L);if(m)return m(Ve);throw"both async and sync fetching of the wasm failed"}catch(Ee){fe(Ee)}}function rt(){return!L&&(l||u)&&typeof fetch=="function"&&!$e(Ve)?fetch(Ve,{credentials:"same-origin"}).then(function(Ee){if(!Ee.ok)throw"failed to load wasm binary file at '"+Ve+"'";return Ee.arrayBuffer()}).catch(function(){return Ie()}):Promise.resolve().then(Ie)}function H(){var Ee={env:xd,wasi_snapshot_preview1:xd};function Te(Lt,zt){var nr=Lt.exports;nr=Uo(nr,1024),t.asm=nr,ae()}K();function Ue(Lt){Te(Lt.instance)}function tt(Lt){return rt().then(function(zt){return WebAssembly.instantiate(zt,Ee)}).then(Lt,function(zt){C("failed to asynchronously prepare wasm: "+zt),fe(zt)})}function Ut(){if(!L&&typeof WebAssembly.instantiateStreaming=="function"&&!xe(Ve)&&!$e(Ve)&&typeof fetch=="function")fetch(Ve,{credentials:"same-origin"}).then(function(Lt){var zt=WebAssembly.instantiateStreaming(Lt,Ee);return zt.then(Ue,function(nr){return C("wasm streaming compile failed: "+nr),C("falling back to ArrayBuffer instantiation"),tt(Ue)})});else return tt(Ue)}if(t.instantiateWasm)try{var Zt=t.instantiateWasm(Ee,Te);return Zt}catch(Lt){return C("Module.instantiateWasm callback failed with error: "+Lt),!1}return Ut(),{}}function be(Ee){for(;Ee.length>0;){var Te=Ee.shift();if(typeof Te=="function"){Te(t);continue}var Ue=Te.func;typeof Ue=="number"?Te.arg===void 0?ve.get(Ue)():ve.get(Ue)(Te.arg):Ue(Te.arg===void 0?null:Te.arg)}}function De(Ee,Te,Ue){return Ue&&Ue.length?t["dynCall_"+Ee].apply(null,[Te].concat(Ue)):t["dynCall_"+Ee].call(null,Te)}function je(Ee,Te,Ue){return Ee.indexOf("j")!=-1?De(Ee,Te,Ue):ve.get(Te).apply(null,Ue)}var lt={nextHandle:1,loadedLibs:{},loadedLibNames:{}};function Dt(Ee){return function(){var Te=Jc();try{return je(Ee,arguments[0],Array.prototype.slice.call(arguments,1))}catch(Ue){if(Qa(Te),Ue!==Ue+0&&Ue!=="longjmp")throw Ue;_setThrew(1,0)}}}function Ni(Ee){if(te)return qo(Ee);var Te=t.___heap_base,Ue=Te+Ee+15&-16;return t.___heap_base=Ue,Te}function Uo(Ee,Te,Ue){var tt={};for(var Ut in Ee){var Zt=Ee[Ut];typeof Zt=="object"&&(Zt=Zt.value),typeof Zt=="number"&&(Zt+=Te),tt[Ut]=Zt,Ue&&(Ue["_"+Ut]=Zt)}return tt}function _a(Ee){var Te=["setTempRet0","getTempRet0","stackAlloc","stackSave","stackRestore"];return Ee.indexOf("dynCall_")==0||Te.indexOf(Ee)!=-1?Ee:"_"+Ee}function Ga(Ee,Te){var Ue=new Uint32Array(new Uint8Array(Ee.subarray(0,24)).buffer);R(Ue[0]==1836278016,"need to see wasm magic number"),R(Ee[8]===0,"need the dylink section to be first");var tt=9;function Ut(){for(var va=0,yg=1;;){var Sh=Ee[tt++];if(va+=(Sh&127)*yg,yg*=128,!(Sh&128))break}return va}Ut(),R(Ee[tt]===6),tt++,R(Ee[tt]==="d".charCodeAt(0)),tt++,R(Ee[tt]==="y".charCodeAt(0)),tt++,R(Ee[tt]==="l".charCodeAt(0)),tt++,R(Ee[tt]==="i".charCodeAt(0)),tt++,R(Ee[tt]==="n".charCodeAt(0)),tt++,R(Ee[tt]==="k".charCodeAt(0)),tt++;var Zt=Ut(),Lt=Ut(),zt=Ut();Ut();for(var nr=Ut(),mi=[],lr=0;lr<nr;++lr){var e1=Ut(),t3=Ee.subarray(tt,tt+e1);tt+=e1;var ya=$(t3,0);mi.push(ya)}function Sd(){Lt=Math.pow(2,Lt),Lt=Math.max(Lt,y);var va=v(Ni(Zt+Lt),Lt),yg=xd,Sh=ve,KO=Sh.length,nLt=Sh;Sh.grow(zt),R(Sh===nLt);for(var n3=va;n3<va+Zt;n3++)X[n3]=0;for(var n3=KO;n3<KO+zt;n3++)Sh.set(n3,null);var GO={},YO=function(_s,Ca,Dh){Dh&&(_s="orig$"+_s);var Gs=t.asm[_s];if(!Gs){var K8=_a(_s);Gs=t[K8],Gs||(Gs=GO[K8]),!Gs&&_s.startsWith("invoke_")&&(Gs=Dt(_s.split("_")[1]))}return Gs};for(var QO in t)QO in yg||(yg[QO]=t[QO]);var iLt={get:function(_s,Ca){switch(Ca){case"__memory_base":return va;case"__table_base":return KO}if(Ca in _s)return _s[Ca];if(Ca.startsWith("g$")){var Dh=Ca.substr(2);return _s[Ca]=function(){return YO(Dh)}}if(Ca.startsWith("fp$")){var Gs=Ca.split("$");R(Gs.length==3);var Dh=Gs[1],K8=Gs[2],oLt=K8.indexOf("j")>=0,ZO=0;return _s[Ca]=function(){if(!ZO){var sLt=YO(Dh,"function",oLt);ZO=D(sLt,K8)}return ZO}}return _s[Ca]=function(){return YO(Ca).apply(null,arguments)}}},h0e=new Proxy(yg,iLt),f0e={global:{NaN:NaN,Infinity:1/0},"global.Math":Math,env:h0e,wasi_snapshot_preview1:h0e};function p0e(_s,Ca){var Dh=Uo(_s.exports,va,Ca),Gs=Dh.__post_instantiate;return Gs&&(te?Gs():re.push(Gs)),Dh}if(Te.loadAsync)return WebAssembly.instantiate(Ee,f0e).then(function(_s){return p0e(_s.instance,GO)});var rLt=new WebAssembly.Instance(new WebAssembly.Module(Ee),f0e);return p0e(rLt,GO)}return Te.loadAsync?Promise.all(mi.map(function(va){return ms(va,Te)})).then(function(){return Sd()}):(mi.forEach(function(va){ms(va,Te)}),Sd())}function Ya(Ee){return fetch(Ee,{credentials:"same-origin"}).then(function(Te){if(!Te.ok)throw"failed to load binary file at '"+Ee+"'";return Te.arrayBuffer()}).then(function(Te){return new Uint8Array(Te)})}function ms(Ee,Te){Ee=="__self__"&&!lt.loadedLibNames[Ee]&&(lt.loadedLibs[-1]={refcount:1/0,name:"__self__",module:t.asm,global:!0},lt.loadedLibNames.__self__=-1),Te=Te||{global:!0,nodelete:!0};var Ue=lt.loadedLibNames[Ee],tt;if(Ue)return tt=lt.loadedLibs[Ue],Te.global&&!tt.global&&(tt.global=!0,tt.module!=="loading"&&zt(tt.module)),Te.nodelete&&tt.refcount!==1/0&&(tt.refcount=1/0),tt.refcount++,Te.loadAsync?Promise.resolve(Ue):Ue;Ue=lt.nextHandle++,tt={refcount:Te.nodelete?1/0:1,name:Ee,module:"loading",global:Te.global},lt.loadedLibNames[Ee]=Ue,lt.loadedLibs[Ue]=tt;function Ut(mi){if(Te.fs){var lr=Te.fs.readFile(mi,{encoding:"binary"});return lr instanceof Uint8Array||(lr=new Uint8Array(lib_data)),Te.loadAsync?Promise.resolve(lr):lr}return Te.loadAsync?Ya(mi):m(mi)}function Zt(mi){return Ga(mi,Te)}function Lt(){if(t.preloadedWasm!==void 0&&t.preloadedWasm[Ee]!==void 0){var mi=t.preloadedWasm[Ee];return Te.loadAsync?Promise.resolve(mi):mi}return Te.loadAsync?Ut(Ee).then(function(lr){return Zt(lr)}):Zt(Ut(Ee))}function zt(mi){for(var lr in mi)if(mi.hasOwnProperty(lr)){var e1=_a(lr);t.hasOwnProperty(e1)||(t[e1]=mi[lr])}}function nr(mi){tt.global&&zt(mi),tt.module=mi}return Te.loadAsync?Lt().then(function(mi){return nr(mi),Ue}):(nr(Lt()),Ue)}function Fl(){var Ee=[];if(t.dynamicLibraries&&(Ee=Ee.concat(t.dynamicLibraries)),!!Ee.length){if(!m){K(),Promise.all(Ee.map(function(Te){return ms(Te,{loadAsync:!0,global:!0,nodelete:!0})})).then(function(){ae()});return}Ee.forEach(function(Te){ms(Te,{global:!0,nodelete:!0})})}}function bs(Ee,Te,Ue){oe.copyWithin(Ee,Te,Te+Ue)}function $u(Ee){fe("OOM")}function Uu(Ee){$u()}function qu(){return t.___heap_base}re.push({func:function(){ot()}},{func:function(){Ku()}});var xd={__indirect_function_table:ve,__memory_base:1024,__stack_pointer:pe,__table_base:1,emscripten_memcpy_big:bs,emscripten_resize_heap:Uu,g$__heap_base:qu,memory:k};H();var Ku=t.___wasm_call_ctors=function(){return(Ku=t.___wasm_call_ctors=t.asm.__wasm_call_ctors).apply(null,arguments)};t._TA_ACCBANDS=function(){return(t._TA_ACCBANDS=t.asm.TA_ACCBANDS).apply(null,arguments)};var qo=t._malloc=function(){return(qo=t._malloc=t.asm.malloc).apply(null,arguments)};t._free=function(){return(t._free=t.asm.free).apply(null,arguments)},t._TA_SMA=function(){return(t._TA_SMA=t.asm.TA_SMA).apply(null,arguments)},t._TA_ACOS=function(){return(t._TA_ACOS=t.asm.TA_ACOS).apply(null,arguments)},t._TA_AD=function(){return(t._TA_AD=t.asm.TA_AD).apply(null,arguments)},t._TA_ADD=function(){return(t._TA_ADD=t.asm.TA_ADD).apply(null,arguments)},t._TA_ADOSC=function(){return(t._TA_ADOSC=t.asm.TA_ADOSC).apply(null,arguments)},t._TA_ADX=function(){return(t._TA_ADX=t.asm.TA_ADX).apply(null,arguments)},t._TA_ADXR=function(){return(t._TA_ADXR=t.asm.TA_ADXR).apply(null,arguments)},t._TA_APO=function(){return(t._TA_APO=t.asm.TA_APO).apply(null,arguments)},t._TA_MA=function(){return(t._TA_MA=t.asm.TA_MA).apply(null,arguments)},t._TA_AROON=function(){return(t._TA_AROON=t.asm.TA_AROON).apply(null,arguments)},t._TA_AROONOSC=function(){return(t._TA_AROONOSC=t.asm.TA_AROONOSC).apply(null,arguments)},t._TA_ASIN=function(){return(t._TA_ASIN=t.asm.TA_ASIN).apply(null,arguments)},t._TA_ATAN=function(){return(t._TA_ATAN=t.asm.TA_ATAN).apply(null,arguments)},t._TA_ATR=function(){return(t._TA_ATR=t.asm.TA_ATR).apply(null,arguments)},t._TA_TRANGE=function(){return(t._TA_TRANGE=t.asm.TA_TRANGE).apply(null,arguments)},t._TA_AVGDEV=function(){return(t._TA_AVGDEV=t.asm.TA_AVGDEV).apply(null,arguments)},t._TA_AVGPRICE=function(){return(t._TA_AVGPRICE=t.asm.TA_AVGPRICE).apply(null,arguments)},t._TA_BBANDS=function(){return(t._TA_BBANDS=t.asm.TA_BBANDS).apply(null,arguments)},t._TA_STDDEV=function(){return(t._TA_STDDEV=t.asm.TA_STDDEV).apply(null,arguments)},t._TA_BETA=function(){return(t._TA_BETA=t.asm.TA_BETA).apply(null,arguments)},t._TA_BOP=function(){return(t._TA_BOP=t.asm.TA_BOP).apply(null,arguments)},t._TA_CCI=function(){return(t._TA_CCI=t.asm.TA_CCI).apply(null,arguments)},t._TA_CDL2CROWS=function(){return(t._TA_CDL2CROWS=t.asm.TA_CDL2CROWS).apply(null,arguments)},t._TA_CDL3BLACKCROWS=function(){return(t._TA_CDL3BLACKCROWS=t.asm.TA_CDL3BLACKCROWS).apply(null,arguments)},t._TA_CDL3INSIDE=function(){return(t._TA_CDL3INSIDE=t.asm.TA_CDL3INSIDE).apply(null,arguments)},t._TA_CDL3LINESTRIKE=function(){return(t._TA_CDL3LINESTRIKE=t.asm.TA_CDL3LINESTRIKE).apply(null,arguments)},t._TA_CDL3OUTSIDE=function(){return(t._TA_CDL3OUTSIDE=t.asm.TA_CDL3OUTSIDE).apply(null,arguments)},t._TA_CDL3STARSINSOUTH=function(){return(t._TA_CDL3STARSINSOUTH=t.asm.TA_CDL3STARSINSOUTH).apply(null,arguments)},t._TA_CDL3WHITESOLDIERS=function(){return(t._TA_CDL3WHITESOLDIERS=t.asm.TA_CDL3WHITESOLDIERS).apply(null,arguments)},t._TA_CDLABANDONEDBABY=function(){return(t._TA_CDLABANDONEDBABY=t.asm.TA_CDLABANDONEDBABY).apply(null,arguments)},t._TA_CDLADVANCEBLOCK=function(){return(t._TA_CDLADVANCEBLOCK=t.asm.TA_CDLADVANCEBLOCK).apply(null,arguments)},t._TA_CDLBELTHOLD=function(){return(t._TA_CDLBELTHOLD=t.asm.TA_CDLBELTHOLD).apply(null,arguments)},t._TA_CDLBREAKAWAY=function(){return(t._TA_CDLBREAKAWAY=t.asm.TA_CDLBREAKAWAY).apply(null,arguments)},t._TA_CDLCLOSINGMARUBOZU=function(){return(t._TA_CDLCLOSINGMARUBOZU=t.asm.TA_CDLCLOSINGMARUBOZU).apply(null,arguments)},t._TA_CDLCONCEALBABYSWALL=function(){return(t._TA_CDLCONCEALBABYSWALL=t.asm.TA_CDLCONCEALBABYSWALL).apply(null,arguments)},t._TA_CDLCOUNTERATTACK=function(){return(t._TA_CDLCOUNTERATTACK=t.asm.TA_CDLCOUNTERATTACK).apply(null,arguments)},t._TA_CDLDARKCLOUDCOVER=function(){return(t._TA_CDLDARKCLOUDCOVER=t.asm.TA_CDLDARKCLOUDCOVER).apply(null,arguments)},t._TA_CDLDOJI=function(){return(t._TA_CDLDOJI=t.asm.TA_CDLDOJI).apply(null,arguments)},t._TA_CDLDOJISTAR=function(){return(t._TA_CDLDOJISTAR=t.asm.TA_CDLDOJISTAR).apply(null,arguments)},t._TA_CDLDRAGONFLYDOJI=function(){return(t._TA_CDLDRAGONFLYDOJI=t.asm.TA_CDLDRAGONFLYDOJI).apply(null,arguments)},t._TA_CDLENGULFING=function(){return(t._TA_CDLENGULFING=t.asm.TA_CDLENGULFING).apply(null,arguments)},t._TA_CDLEVENINGDOJISTAR=function(){return(t._TA_CDLEVENINGDOJISTAR=t.asm.TA_CDLEVENINGDOJISTAR).apply(null,arguments)},t._TA_CDLEVENINGSTAR=function(){return(t._TA_CDLEVENINGSTAR=t.asm.TA_CDLEVENINGSTAR).apply(null,arguments)},t._TA_CDLGAPSIDESIDEWHITE=function(){return(t._TA_CDLGAPSIDESIDEWHITE=t.asm.TA_CDLGAPSIDESIDEWHITE).apply(null,arguments)},t._TA_CDLGRAVESTONEDOJI=function(){return(t._TA_CDLGRAVESTONEDOJI=t.asm.TA_CDLGRAVESTONEDOJI).apply(null,arguments)},t._TA_CDLHAMMER=function(){return(t._TA_CDLHAMMER=t.asm.TA_CDLHAMMER).apply(null,arguments)},t._TA_CDLHANGINGMAN=function(){return(t._TA_CDLHANGINGMAN=t.asm.TA_CDLHANGINGMAN).apply(null,arguments)},t._TA_CDLHARAMI=function(){return(t._TA_CDLHARAMI=t.asm.TA_CDLHARAMI).apply(null,arguments)},t._TA_CDLHARAMICROSS=function(){return(t._TA_CDLHARAMICROSS=t.asm.TA_CDLHARAMICROSS).apply(null,arguments)},t._TA_CDLHIGHWAVE=function(){return(t._TA_CDLHIGHWAVE=t.asm.TA_CDLHIGHWAVE).apply(null,arguments)},t._TA_CDLHIKKAKE=function(){return(t._TA_CDLHIKKAKE=t.asm.TA_CDLHIKKAKE).apply(null,arguments)},t._TA_CDLHIKKAKEMOD=function(){return(t._TA_CDLHIKKAKEMOD=t.asm.TA_CDLHIKKAKEMOD).apply(null,arguments)},t._TA_CDLHOMINGPIGEON=function(){return(t._TA_CDLHOMINGPIGEON=t.asm.TA_CDLHOMINGPIGEON).apply(null,arguments)},t._TA_CDLIDENTICAL3CROWS=function(){return(t._TA_CDLIDENTICAL3CROWS=t.asm.TA_CDLIDENTICAL3CROWS).apply(null,arguments)},t._TA_CDLINNECK=function(){return(t._TA_CDLINNECK=t.asm.TA_CDLINNECK).apply(null,arguments)},t._TA_CDLINVERTEDHAMMER=function(){return(t._TA_CDLINVERTEDHAMMER=t.asm.TA_CDLINVERTEDHAMMER).apply(null,arguments)},t._TA_CDLKICKING=function(){return(t._TA_CDLKICKING=t.asm.TA_CDLKICKING).apply(null,arguments)},t._TA_CDLKICKINGBYLENGTH=function(){return(t._TA_CDLKICKINGBYLENGTH=t.asm.TA_CDLKICKINGBYLENGTH).apply(null,arguments)},t._TA_CDLLADDERBOTTOM=function(){return(t._TA_CDLLADDERBOTTOM=t.asm.TA_CDLLADDERBOTTOM).apply(null,arguments)},t._TA_CDLLONGLEGGEDDOJI=function(){return(t._TA_CDLLONGLEGGEDDOJI=t.asm.TA_CDLLONGLEGGEDDOJI).apply(null,arguments)},t._TA_CDLLONGLINE=function(){return(t._TA_CDLLONGLINE=t.asm.TA_CDLLONGLINE).apply(null,arguments)},t._TA_CDLMARUBOZU=function(){return(t._TA_CDLMARUBOZU=t.asm.TA_CDLMARUBOZU).apply(null,arguments)},t._TA_CDLMATCHINGLOW=function(){return(t._TA_CDLMATCHINGLOW=t.asm.TA_CDLMATCHINGLOW).apply(null,arguments)},t._TA_CDLMATHOLD=function(){return(t._TA_CDLMATHOLD=t.asm.TA_CDLMATHOLD).apply(null,arguments)},t._TA_CDLMORNINGDOJISTAR=function(){return(t._TA_CDLMORNINGDOJISTAR=t.asm.TA_CDLMORNINGDOJISTAR).apply(null,arguments)},t._TA_CDLMORNINGSTAR=function(){return(t._TA_CDLMORNINGSTAR=t.asm.TA_CDLMORNINGSTAR).apply(null,arguments)},t._TA_CDLONNECK=function(){return(t._TA_CDLONNECK=t.asm.TA_CDLONNECK).apply(null,arguments)},t._TA_CDLPIERCING=function(){return(t._TA_CDLPIERCING=t.asm.TA_CDLPIERCING).apply(null,arguments)},t._TA_CDLRICKSHAWMAN=function(){return(t._TA_CDLRICKSHAWMAN=t.asm.TA_CDLRICKSHAWMAN).apply(null,arguments)},t._TA_CDLRISEFALL3METHODS=function(){return(t._TA_CDLRISEFALL3METHODS=t.asm.TA_CDLRISEFALL3METHODS).apply(null,arguments)},t._TA_CDLSEPARATINGLINES=function(){return(t._TA_CDLSEPARATINGLINES=t.asm.TA_CDLSEPARATINGLINES).apply(null,arguments)},t._TA_CDLSHOOTINGSTAR=function(){return(t._TA_CDLSHOOTINGSTAR=t.asm.TA_CDLSHOOTINGSTAR).apply(null,arguments)},t._TA_CDLSHORTLINE=function(){return(t._TA_CDLSHORTLINE=t.asm.TA_CDLSHORTLINE).apply(null,arguments)},t._TA_CDLSPINNINGTOP=function(){return(t._TA_CDLSPINNINGTOP=t.asm.TA_CDLSPINNINGTOP).apply(null,arguments)},t._TA_CDLSTALLEDPATTERN=function(){return(t._TA_CDLSTALLEDPATTERN=t.asm.TA_CDLSTALLEDPATTERN).apply(null,arguments)},t._TA_CDLSTICKSANDWICH=function(){return(t._TA_CDLSTICKSANDWICH=t.asm.TA_CDLSTICKSANDWICH).apply(null,arguments)},t._TA_CDLTAKURI=function(){return(t._TA_CDLTAKURI=t.asm.TA_CDLTAKURI).apply(null,arguments)},t._TA_CDLTASUKIGAP=function(){return(t._TA_CDLTASUKIGAP=t.asm.TA_CDLTASUKIGAP).apply(null,arguments)},t._TA_CDLTHRUSTING=function(){return(t._TA_CDLTHRUSTING=t.asm.TA_CDLTHRUSTING).apply(null,arguments)},t._TA_CDLTRISTAR=function(){return(t._TA_CDLTRISTAR=t.asm.TA_CDLTRISTAR).apply(null,arguments)},t._TA_CDLUNIQUE3RIVER=function(){return(t._TA_CDLUNIQUE3RIVER=t.asm.TA_CDLUNIQUE3RIVER).apply(null,arguments)},t._TA_CDLUPSIDEGAP2CROWS=function(){return(t._TA_CDLUPSIDEGAP2CROWS=t.asm.TA_CDLUPSIDEGAP2CROWS).apply(null,arguments)},t._TA_CDLXSIDEGAP3METHODS=function(){return(t._TA_CDLXSIDEGAP3METHODS=t.asm.TA_CDLXSIDEGAP3METHODS).apply(null,arguments)},t._TA_CEIL=function(){return(t._TA_CEIL=t.asm.TA_CEIL).apply(null,arguments)},t._TA_CMO=function(){return(t._TA_CMO=t.asm.TA_CMO).apply(null,arguments)},t._TA_CORREL=function(){return(t._TA_CORREL=t.asm.TA_CORREL).apply(null,arguments)},t._TA_COS=function(){return(t._TA_COS=t.asm.TA_COS).apply(null,arguments)},t._TA_COSH=function(){return(t._TA_COSH=t.asm.TA_COSH).apply(null,arguments)},t._TA_DEMA=function(){return(t._TA_DEMA=t.asm.TA_DEMA).apply(null,arguments)},t._TA_DIV=function(){return(t._TA_DIV=t.asm.TA_DIV).apply(null,arguments)},t._TA_DX=function(){return(t._TA_DX=t.asm.TA_DX).apply(null,arguments)},t._TA_EMA=function(){return(t._TA_EMA=t.asm.TA_EMA).apply(null,arguments)},t._TA_EXP=function(){return(t._TA_EXP=t.asm.TA_EXP).apply(null,arguments)},t._TA_FLOOR=function(){return(t._TA_FLOOR=t.asm.TA_FLOOR).apply(null,arguments)},t._TA_HT_DCPERIOD=function(){return(t._TA_HT_DCPERIOD=t.asm.TA_HT_DCPERIOD).apply(null,arguments)},t._TA_HT_DCPHASE=function(){return(t._TA_HT_DCPHASE=t.asm.TA_HT_DCPHASE).apply(null,arguments)},t._TA_HT_PHASOR=function(){return(t._TA_HT_PHASOR=t.asm.TA_HT_PHASOR).apply(null,arguments)},t._TA_HT_SINE=function(){return(t._TA_HT_SINE=t.asm.TA_HT_SINE).apply(null,arguments)},t._TA_HT_TRENDLINE=function(){return(t._TA_HT_TRENDLINE=t.asm.TA_HT_TRENDLINE).apply(null,arguments)},t._TA_HT_TRENDMODE=function(){return(t._TA_HT_TRENDMODE=t.asm.TA_HT_TRENDMODE).apply(null,arguments)},t._TA_IMI=function(){return(t._TA_IMI=t.asm.TA_IMI).apply(null,arguments)},t._TA_KAMA=function(){return(t._TA_KAMA=t.asm.TA_KAMA).apply(null,arguments)},t._TA_LINEARREG=function(){return(t._TA_LINEARREG=t.asm.TA_LINEARREG).apply(null,arguments)},t._TA_LINEARREG_ANGLE=function(){return(t._TA_LINEARREG_ANGLE=t.asm.TA_LINEARREG_ANGLE).apply(null,arguments)},t._TA_LINEARREG_INTERCEPT=function(){return(t._TA_LINEARREG_INTERCEPT=t.asm.TA_LINEARREG_INTERCEPT).apply(null,arguments)},t._TA_LINEARREG_SLOPE=function(){return(t._TA_LINEARREG_SLOPE=t.asm.TA_LINEARREG_SLOPE).apply(null,arguments)},t._TA_LN=function(){return(t._TA_LN=t.asm.TA_LN).apply(null,arguments)},t._TA_LOG10=function(){return(t._TA_LOG10=t.asm.TA_LOG10).apply(null,arguments)},t._TA_WMA=function(){return(t._TA_WMA=t.asm.TA_WMA).apply(null,arguments)},t._TA_TEMA=function(){return(t._TA_TEMA=t.asm.TA_TEMA).apply(null,arguments)},t._TA_TRIMA=function(){return(t._TA_TRIMA=t.asm.TA_TRIMA).apply(null,arguments)},t._TA_MAMA=function(){return(t._TA_MAMA=t.asm.TA_MAMA).apply(null,arguments)},t._TA_T3=function(){return(t._TA_T3=t.asm.TA_T3).apply(null,arguments)},t._TA_MACD=function(){return(t._TA_MACD=t.asm.TA_MACD).apply(null,arguments)},t._TA_MACDEXT=function(){return(t._TA_MACDEXT=t.asm.TA_MACDEXT).apply(null,arguments)},t._TA_MACDFIX=function(){return(t._TA_MACDFIX=t.asm.TA_MACDFIX).apply(null,arguments)},t._TA_MAVP=function(){return(t._TA_MAVP=t.asm.TA_MAVP).apply(null,arguments)},t._TA_MAX=function(){return(t._TA_MAX=t.asm.TA_MAX).apply(null,arguments)},t._TA_MAXINDEX=function(){return(t._TA_MAXINDEX=t.asm.TA_MAXINDEX).apply(null,arguments)},t._TA_MEDPRICE=function(){return(t._TA_MEDPRICE=t.asm.TA_MEDPRICE).apply(null,arguments)},t._TA_MFI=function(){return(t._TA_MFI=t.asm.TA_MFI).apply(null,arguments)},t._TA_MIDPOINT=function(){return(t._TA_MIDPOINT=t.asm.TA_MIDPOINT).apply(null,arguments)},t._TA_MIDPRICE=function(){return(t._TA_MIDPRICE=t.asm.TA_MIDPRICE).apply(null,arguments)},t._TA_MIN=function(){return(t._TA_MIN=t.asm.TA_MIN).apply(null,arguments)},t._TA_MININDEX=function(){return(t._TA_MININDEX=t.asm.TA_MININDEX).apply(null,arguments)},t._TA_MINMAX=function(){return(t._TA_MINMAX=t.asm.TA_MINMAX).apply(null,arguments)},t._TA_MINMAXINDEX=function(){return(t._TA_MINMAXINDEX=t.asm.TA_MINMAXINDEX).apply(null,arguments)},t._TA_MINUS_DI=function(){return(t._TA_MINUS_DI=t.asm.TA_MINUS_DI).apply(null,arguments)},t._TA_MINUS_DM=function(){return(t._TA_MINUS_DM=t.asm.TA_MINUS_DM).apply(null,arguments)},t._TA_MOM=function(){return(t._TA_MOM=t.asm.TA_MOM).apply(null,arguments)},t._TA_MULT=function(){return(t._TA_MULT=t.asm.TA_MULT).apply(null,arguments)},t._TA_NATR=function(){return(t._TA_NATR=t.asm.TA_NATR).apply(null,arguments)},t._TA_OBV=function(){return(t._TA_OBV=t.asm.TA_OBV).apply(null,arguments)},t._TA_PLUS_DI=function(){return(t._TA_PLUS_DI=t.asm.TA_PLUS_DI).apply(null,arguments)},t._TA_PLUS_DM=function(){return(t._TA_PLUS_DM=t.asm.TA_PLUS_DM).apply(null,arguments)},t._TA_PPO=function(){return(t._TA_PPO=t.asm.TA_PPO).apply(null,arguments)},t._TA_ROC=function(){return(t._TA_ROC=t.asm.TA_ROC).apply(null,arguments)},t._TA_ROCP=function(){return(t._TA_ROCP=t.asm.TA_ROCP).apply(null,arguments)},t._TA_ROCR=function(){return(t._TA_ROCR=t.asm.TA_ROCR).apply(null,arguments)},t._TA_ROCR100=function(){return(t._TA_ROCR100=t.asm.TA_ROCR100).apply(null,arguments)},t._TA_RSI=function(){return(t._TA_RSI=t.asm.TA_RSI).apply(null,arguments)},t._TA_SAR=function(){return(t._TA_SAR=t.asm.TA_SAR).apply(null,arguments)},t._TA_SAREXT=function(){return(t._TA_SAREXT=t.asm.TA_SAREXT).apply(null,arguments)},t._TA_SIN=function(){return(t._TA_SIN=t.asm.TA_SIN).apply(null,arguments)},t._TA_SINH=function(){return(t._TA_SINH=t.asm.TA_SINH).apply(null,arguments)},t._TA_SQRT=function(){return(t._TA_SQRT=t.asm.TA_SQRT).apply(null,arguments)},t._TA_STOCH=function(){return(t._TA_STOCH=t.asm.TA_STOCH).apply(null,arguments)},t._TA_STOCHF=function(){return(t._TA_STOCHF=t.asm.TA_STOCHF).apply(null,arguments)},t._TA_STOCHRSI=function(){return(t._TA_STOCHRSI=t.asm.TA_STOCHRSI).apply(null,arguments)},t._TA_SUB=function(){return(t._TA_SUB=t.asm.TA_SUB).apply(null,arguments)},t._TA_SUM=function(){return(t._TA_SUM=t.asm.TA_SUM).apply(null,arguments)},t._TA_TAN=function(){return(t._TA_TAN=t.asm.TA_TAN).apply(null,arguments)},t._TA_TANH=function(){return(t._TA_TANH=t.asm.TA_TANH).apply(null,arguments)},t._TA_TRIX=function(){return(t._TA_TRIX=t.asm.TA_TRIX).apply(null,arguments)},t._TA_TSF=function(){return(t._TA_TSF=t.asm.TA_TSF).apply(null,arguments)},t._TA_TYPPRICE=function(){return(t._TA_TYPPRICE=t.asm.TA_TYPPRICE).apply(null,arguments)},t._TA_ULTOSC=function(){return(t._TA_ULTOSC=t.asm.TA_ULTOSC).apply(null,arguments)},t._TA_VAR=function(){return(t._TA_VAR=t.asm.TA_VAR).apply(null,arguments)},t._TA_WCLPRICE=function(){return(t._TA_WCLPRICE=t.asm.TA_WCLPRICE).apply(null,arguments)},t._TA_WILLR=function(){return(t._TA_WILLR=t.asm.TA_WILLR).apply(null,arguments)};var Jc=t.stackSave=function(){return(Jc=t.stackSave=t.asm.stackSave).apply(null,arguments)},Qa=t.stackRestore=function(){return(Qa=t.stackRestore=t.asm.stackRestore).apply(null,arguments)},Fe=t.stackAlloc=function(){return(Fe=t.stackAlloc=t.asm.stackAlloc).apply(null,arguments)},ot=t.___assign_got_enties=function(){return(ot=t.___assign_got_enties=t.asm.__assign_got_enties).apply(null,arguments)};t._TA_Globals=1448,t.___data_end=4888;for(var ln in["TA_Globals","__data_end"])(function(Ee){t["g$"+Ee]=function(){return t[Ee]}})(ln);t.ccall=I,t.allocate=O;var ut;function Ne(Ee){this.name="ExitStatus",this.message="Program terminated with exit("+Ee+")",this.status=Ee}q=function Ee(){ut||at(),ut||(q=Ee)};function Qe(Ee){var Te=t._main;if(Te){var Ue=0,tt=0;try{var Ut=Te(Ue,tt);Bn(Ut,!0)}catch(Lt){if(Lt instanceof Ne)return;if(Lt=="unwind"){E=!0;return}else{var Zt=Lt;Lt&&typeof Lt=="object"&&Lt.stack&&(Zt=[Lt,Lt.stack]),C("exception thrown: "+Zt),a(1,Lt)}}finally{}}}function at(Ee){if(V>0||(J(),V>0))return;function Te(){ut||(ut=!0,t.calledRun=!0,!A&&(ie(),G(),i(t),t.onRuntimeInitialized&&t.onRuntimeInitialized(),gi&&Qe(),Q()))}t.setStatus?(t.setStatus("Running..."),setTimeout(function(){setTimeout(function(){t.setStatus("")},1),Te()},1)):Te()}t.run=at;function Bn(Ee,Te){Te&&E&&Ee===0||(E||(t.onExit&&t.onExit(Ee),A=!0),a(Ee,new Ne(Ee)))}if(t.preInit)for(typeof t.preInit=="function"&&(t.preInit=[t.preInit]);t.preInit.length>0;)t.preInit.pop()();var gi=!0;return t.noInitialRun&&(gi=!1),E=!0,at(),e.ready}}();const Re={ACCBANDS:{name:"ACCBANDS",camelCaseName:"accBands",group:"Overlap Studies",description:"Acceleration Bands",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:20,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"upperBand",type:"Double[]",plotHint:"limit_upper"},{name:"middleBand",type:"Double[]",plotHint:"line"},{name:"lowerBand",type:"Double[]",plotHint:"limit_lower"}]},ACOS:{name:"ACOS",camelCaseName:"acos",group:"Math Transform",description:"Vector Trigonometric ACos",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AD:{name:"AD",camelCaseName:"ad",group:"Volume Indicators",description:"Chaikin A/D Line",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADD:{name:"ADD",camelCaseName:"add",group:"Math Operators",description:"Vector Arithmetic Add",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADOSC:{name:"ADOSC",camelCaseName:"adOsc",group:"Volume Indicators",description:"Chaikin A/D Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:3,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:10,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADX:{name:"ADX",camelCaseName:"adx",group:"Momentum Indicators",description:"Average Directional Movement Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADXR:{name:"ADXR",camelCaseName:"adxr",group:"Momentum Indicators",description:"Average Directional Movement Index Rating",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},APO:{name:"APO",camelCaseName:"apo",group:"Momentum Indicators",description:"Absolute Price Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AROON:{name:"AROON",camelCaseName:"aroon",group:"Momentum Indicators",description:"Aroon",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"aroonDown",type:"Double[]",plotHint:"line_dash"},{name:"aroonUp",type:"Double[]",plotHint:"line"}]},AROONOSC:{name:"AROONOSC",camelCaseName:"aroonOsc",group:"Momentum Indicators",description:"Aroon Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ASIN:{name:"ASIN",camelCaseName:"asin",group:"Math Transform",description:"Vector Trigonometric ASin",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ATAN:{name:"ATAN",camelCaseName:"atan",group:"Math Transform",description:"Vector Trigonometric ATan",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ATR:{name:"ATR",camelCaseName:"atr",group:"Volatility Indicators",description:"Average True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AVGDEV:{name:"AVGDEV",camelCaseName:"avgDev",group:"Price Transform",description:"Average Deviation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AVGPRICE:{name:"AVGPRICE",camelCaseName:"avgPrice",group:"Price Transform",description:"Average Price",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},BBANDS:{name:"BBANDS",camelCaseName:"bbands",group:"Overlap Studies",description:"Bollinger Bands",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"nbDevUp",displayName:"Deviations up",defaultValue:2,hint:"Deviation multiplier for upper band",type:"Double",range:{min:-3e37,max:3e37}},{name:"nbDevDn",displayName:"Deviations down",defaultValue:2,hint:"Deviation multiplier for lower band",type:"Double",range:{min:-3e37,max:3e37}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"upperBand",type:"Double[]",plotHint:"limit_upper"},{name:"middleBand",type:"Double[]",plotHint:"line"},{name:"lowerBand",type:"Double[]",plotHint:"limit_lower"}]},BETA:{name:"BETA",camelCaseName:"beta",group:"Statistic Functions",description:"Beta",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},BOP:{name:"BOP",camelCaseName:"bop",group:"Momentum Indicators",description:"Balance Of Power",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CCI:{name:"CCI",camelCaseName:"cci",group:"Momentum Indicators",description:"Commodity Channel Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CDL2CROWS:{name:"CDL2CROWS",camelCaseName:"cdl2Crows",group:"Pattern Recognition",description:"Two Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3BLACKCROWS:{name:"CDL3BLACKCROWS",camelCaseName:"cdl3BlackCrows",group:"Pattern Recognition",description:"Three Black Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3INSIDE:{name:"CDL3INSIDE",camelCaseName:"cdl3Inside",group:"Pattern Recognition",description:"Three Inside Up/Down",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3LINESTRIKE:{name:"CDL3LINESTRIKE",camelCaseName:"cdl3LineStrike",group:"Pattern Recognition",description:"Three-Line Strike ",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3OUTSIDE:{name:"CDL3OUTSIDE",camelCaseName:"cdl3Outside",group:"Pattern Recognition",description:"Three Outside Up/Down",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3STARSINSOUTH:{name:"CDL3STARSINSOUTH",camelCaseName:"cdl3StarsInSouth",group:"Pattern Recognition",description:"Three Stars In The South",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3WHITESOLDIERS:{name:"CDL3WHITESOLDIERS",camelCaseName:"cdl3WhiteSoldiers",group:"Pattern Recognition",description:"Three Advancing White Soldiers",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLABANDONEDBABY:{name:"CDLABANDONEDBABY",camelCaseName:"cdlAbandonedBaby",group:"Pattern Recognition",description:"Abandoned Baby",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLADVANCEBLOCK:{name:"CDLADVANCEBLOCK",camelCaseName:"cdlAdvanceBlock",group:"Pattern Recognition",description:"Advance Block",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLBELTHOLD:{name:"CDLBELTHOLD",camelCaseName:"cdlBeltHold",group:"Pattern Recognition",description:"Belt-hold",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLBREAKAWAY:{name:"CDLBREAKAWAY",camelCaseName:"cdlBreakaway",group:"Pattern Recognition",description:"Breakaway",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCLOSINGMARUBOZU:{name:"CDLCLOSINGMARUBOZU",camelCaseName:"cdlClosingMarubozu",group:"Pattern Recognition",description:"Closing Marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCONCEALBABYSWALL:{name:"CDLCONCEALBABYSWALL",camelCaseName:"cdlConcealBabysWall",group:"Pattern Recognition",description:"Concealing Baby Swallow",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCOUNTERATTACK:{name:"CDLCOUNTERATTACK",camelCaseName:"cdlCounterAttack",group:"Pattern Recognition",description:"Counterattack",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDARKCLOUDCOVER:{name:"CDLDARKCLOUDCOVER",camelCaseName:"cdlDarkCloudCover",group:"Pattern Recognition",description:"Dark Cloud Cover",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.5,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDOJI:{name:"CDLDOJI",camelCaseName:"cdlDoji",group:"Pattern Recognition",description:"Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDOJISTAR:{name:"CDLDOJISTAR",camelCaseName:"cdlDojiStar",group:"Pattern Recognition",description:"Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDRAGONFLYDOJI:{name:"CDLDRAGONFLYDOJI",camelCaseName:"cdlDragonflyDoji",group:"Pattern Recognition",description:"Dragonfly Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLENGULFING:{name:"CDLENGULFING",camelCaseName:"cdlEngulfing",group:"Pattern Recognition",description:"Engulfing Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLEVENINGDOJISTAR:{name:"CDLEVENINGDOJISTAR",camelCaseName:"cdlEveningDojiStar",group:"Pattern Recognition",description:"Evening Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLEVENINGSTAR:{name:"CDLEVENINGSTAR",camelCaseName:"cdlEveningStar",group:"Pattern Recognition",description:"Evening Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLGAPSIDESIDEWHITE:{name:"CDLGAPSIDESIDEWHITE",camelCaseName:"cdlGapSideSideWhite",group:"Pattern Recognition",description:"Up/Down-gap side-by-side white lines",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLGRAVESTONEDOJI:{name:"CDLGRAVESTONEDOJI",camelCaseName:"cdlGravestoneDoji",group:"Pattern Recognition",description:"Gravestone Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHAMMER:{name:"CDLHAMMER",camelCaseName:"cdlHammer",group:"Pattern Recognition",description:"Hammer",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHANGINGMAN:{name:"CDLHANGINGMAN",camelCaseName:"cdlHangingMan",group:"Pattern Recognition",description:"Hanging Man",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHARAMI:{name:"CDLHARAMI",camelCaseName:"cdlHarami",group:"Pattern Recognition",description:"Harami Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHARAMICROSS:{name:"CDLHARAMICROSS",camelCaseName:"cdlHaramiCross",group:"Pattern Recognition",description:"Harami Cross Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIGHWAVE:{name:"CDLHIGHWAVE",camelCaseName:"cdlHignWave",group:"Pattern Recognition",description:"High-Wave Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIKKAKE:{name:"CDLHIKKAKE",camelCaseName:"cdlHikkake",group:"Pattern Recognition",description:"Hikkake Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIKKAKEMOD:{name:"CDLHIKKAKEMOD",camelCaseName:"cdlHikkakeMod",group:"Pattern Recognition",description:"Modified Hikkake Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHOMINGPIGEON:{name:"CDLHOMINGPIGEON",camelCaseName:"cdlHomingPigeon",group:"Pattern Recognition",description:"Homing Pigeon",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLIDENTICAL3CROWS:{name:"CDLIDENTICAL3CROWS",camelCaseName:"cdlIdentical3Crows",group:"Pattern Recognition",description:"Identical Three Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLINNECK:{name:"CDLINNECK",camelCaseName:"cdlInNeck",group:"Pattern Recognition",description:"In-Neck Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLINVERTEDHAMMER:{name:"CDLINVERTEDHAMMER",camelCaseName:"cdlInvertedHammer",group:"Pattern Recognition",description:"Inverted Hammer",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLKICKING:{name:"CDLKICKING",camelCaseName:"cdlKicking",group:"Pattern Recognition",description:"Kicking",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLKICKINGBYLENGTH:{name:"CDLKICKINGBYLENGTH",camelCaseName:"cdlKickingByLength",group:"Pattern Recognition",description:"Kicking - bull/bear determined by the longer marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLADDERBOTTOM:{name:"CDLLADDERBOTTOM",camelCaseName:"cdlLadderBottom",group:"Pattern Recognition",description:"Ladder Bottom",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLONGLEGGEDDOJI:{name:"CDLLONGLEGGEDDOJI",camelCaseName:"cdlLongLeggedDoji",group:"Pattern Recognition",description:"Long Legged Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLONGLINE:{name:"CDLLONGLINE",camelCaseName:"cdlLongLine",group:"Pattern Recognition",description:"Long Line Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMARUBOZU:{name:"CDLMARUBOZU",camelCaseName:"cdlMarubozu",group:"Pattern Recognition",description:"Marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMATCHINGLOW:{name:"CDLMATCHINGLOW",camelCaseName:"cdlMatchingLow",group:"Pattern Recognition",description:"Matching Low",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMATHOLD:{name:"CDLMATHOLD",camelCaseName:"cdlMatHold",group:"Pattern Recognition",description:"Mat Hold",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.5,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMORNINGDOJISTAR:{name:"CDLMORNINGDOJISTAR",camelCaseName:"cdlMorningDojiStar",group:"Pattern Recognition",description:"Morning Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMORNINGSTAR:{name:"CDLMORNINGSTAR",camelCaseName:"cdlMorningStar",group:"Pattern Recognition",description:"Morning Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLONNECK:{name:"CDLONNECK",camelCaseName:"cdlOnNeck",group:"Pattern Recognition",description:"On-Neck Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLPIERCING:{name:"CDLPIERCING",camelCaseName:"cdlPiercing",group:"Pattern Recognition",description:"Piercing Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLRICKSHAWMAN:{name:"CDLRICKSHAWMAN",camelCaseName:"cdlRickshawMan",group:"Pattern Recognition",description:"Rickshaw Man",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLRISEFALL3METHODS:{name:"CDLRISEFALL3METHODS",camelCaseName:"cdlRiseFall3Methods",group:"Pattern Recognition",description:"Rising/Falling Three Methods",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSEPARATINGLINES:{name:"CDLSEPARATINGLINES",camelCaseName:"cdlSeperatingLines",group:"Pattern Recognition",description:"Separating Lines",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSHOOTINGSTAR:{name:"CDLSHOOTINGSTAR",camelCaseName:"cdlShootingStar",group:"Pattern Recognition",description:"Shooting Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSHORTLINE:{name:"CDLSHORTLINE",camelCaseName:"cdlShortLine",group:"Pattern Recognition",description:"Short Line Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSPINNINGTOP:{name:"CDLSPINNINGTOP",camelCaseName:"cdlSpinningTop",group:"Pattern Recognition",description:"Spinning Top",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSTALLEDPATTERN:{name:"CDLSTALLEDPATTERN",camelCaseName:"cdlStalledPattern",group:"Pattern Recognition",description:"Stalled Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSTICKSANDWICH:{name:"CDLSTICKSANDWICH",camelCaseName:"cdlStickSandwhich",group:"Pattern Recognition",description:"Stick Sandwich",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTAKURI:{name:"CDLTAKURI",camelCaseName:"cdlTakuri",group:"Pattern Recognition",description:"Takuri (Dragonfly Doji with very long lower shadow)",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTASUKIGAP:{name:"CDLTASUKIGAP",camelCaseName:"cdlTasukiGap",group:"Pattern Recognition",description:"Tasuki Gap",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTHRUSTING:{name:"CDLTHRUSTING",camelCaseName:"cdlThrusting",group:"Pattern Recognition",description:"Thrusting Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTRISTAR:{name:"CDLTRISTAR",camelCaseName:"cdlTristar",group:"Pattern Recognition",description:"Tristar Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLUNIQUE3RIVER:{name:"CDLUNIQUE3RIVER",camelCaseName:"cdlUnique3River",group:"Pattern Recognition",description:"Unique 3 River",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLUPSIDEGAP2CROWS:{name:"CDLUPSIDEGAP2CROWS",camelCaseName:"cdlUpsideGap2Crows",group:"Pattern Recognition",description:"Upside Gap Two Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLXSIDEGAP3METHODS:{name:"CDLXSIDEGAP3METHODS",camelCaseName:"cdlXSideGap3Methods",group:"Pattern Recognition",description:"Upside/Downside Gap Three Methods",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CEIL:{name:"CEIL",camelCaseName:"ceil",group:"Math Transform",description:"Vector Ceil",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CMO:{name:"CMO",camelCaseName:"cmo",group:"Momentum Indicators",description:"Chande Momentum Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CORREL:{name:"CORREL",camelCaseName:"correl",group:"Statistic Functions",description:"Pearson's Correlation Coefficient (r)",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},COS:{name:"COS",camelCaseName:"cos",group:"Math Transform",description:"Vector Trigonometric Cos",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},COSH:{name:"COSH",camelCaseName:"cosh",group:"Math Transform",description:"Vector Trigonometric Cosh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DEMA:{name:"DEMA",camelCaseName:"dema",group:"Overlap Studies",description:"Double Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DIV:{name:"DIV",camelCaseName:"div",group:"Math Operators",description:"Vector Arithmetic Div",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DX:{name:"DX",camelCaseName:"dx",group:"Momentum Indicators",description:"Directional Movement Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},EMA:{name:"EMA",camelCaseName:"ema",group:"Overlap Studies",description:"Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},EXP:{name:"EXP",camelCaseName:"exp",group:"Math Transform",description:"Vector Arithmetic Exp",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},FLOOR:{name:"FLOOR",camelCaseName:"floor",group:"Math Transform",description:"Vector Floor",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_DCPERIOD:{name:"HT_DCPERIOD",camelCaseName:"htDcPeriod",group:"Cycle Indicators",description:"Hilbert Transform - Dominant Cycle Period",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_DCPHASE:{name:"HT_DCPHASE",camelCaseName:"htDcPhase",group:"Cycle Indicators",description:"Hilbert Transform - Dominant Cycle Phase",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_PHASOR:{name:"HT_PHASOR",camelCaseName:"htPhasor",group:"Cycle Indicators",description:"Hilbert Transform - Phasor Components",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"inPhase",type:"Double[]",plotHint:"line"},{name:"quadrature",type:"Double[]",plotHint:"line_dash"}]},HT_SINE:{name:"HT_SINE",camelCaseName:"htSine",group:"Cycle Indicators",description:"Hilbert Transform - SineWave",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"sine",type:"Double[]",plotHint:"line"},{name:"leadSine",type:"Double[]",plotHint:"line_dash"}]},HT_TRENDLINE:{name:"HT_TRENDLINE",camelCaseName:"htTrendline",group:"Overlap Studies",description:"Hilbert Transform - Instantaneous Trendline",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_TRENDMODE:{name:"HT_TRENDMODE",camelCaseName:"htTrendMode",group:"Cycle Indicators",description:"Hilbert Transform - Trend vs Cycle Mode",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},IMI:{name:"IMI",camelCaseName:"imi",group:"Momentum Indicators",description:"Intraday Momentum Index",inputs:[{name:"open",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},KAMA:{name:"KAMA",camelCaseName:"kama",group:"Overlap Studies",description:"Kaufman Adaptive Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG:{name:"LINEARREG",camelCaseName:"linearReg",group:"Statistic Functions",description:"Linear Regression",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_ANGLE:{name:"LINEARREG_ANGLE",camelCaseName:"linearRegAngle",group:"Statistic Functions",description:"Linear Regression Angle",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_INTERCEPT:{name:"LINEARREG_INTERCEPT",camelCaseName:"linearRegIntercept",group:"Statistic Functions",description:"Linear Regression Intercept",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_SLOPE:{name:"LINEARREG_SLOPE",camelCaseName:"linearRegSlope",group:"Statistic Functions",description:"Linear Regression Slope",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LN:{name:"LN",camelCaseName:"ln",group:"Math Transform",description:"Vector Log Natural",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LOG10:{name:"LOG10",camelCaseName:"log10",group:"Math Transform",description:"Vector Log10",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MA:{name:"MA",camelCaseName:"movingAverage",group:"Overlap Studies",description:"Moving average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MACD:{name:"MACD",camelCaseName:"macd",group:"Momentum Indicators",description:"Moving Average Convergence/Divergence",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MACDEXT:{name:"MACDEXT",camelCaseName:"macdExt",group:"Momentum Indicators",description:"MACD with controllable MA type",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"fastMAType",displayName:"Fast MA",defaultValue:0,hint:"Type of Moving Average for fast MA",type:"MAType"},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowMAType",displayName:"Slow MA",defaultValue:0,hint:"Type of Moving Average for slow MA",type:"MAType"},{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}},{name:"signalMAType",displayName:"Signal MA",defaultValue:0,hint:"Type of Moving Average for signal line",type:"MAType"}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MACDFIX:{name:"MACDFIX",camelCaseName:"macdFix",group:"Momentum Indicators",description:"Moving Average Convergence/Divergence Fix 12/26",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MAMA:{name:"MAMA",camelCaseName:"mama",group:"Overlap Studies",description:"MESA Adaptive Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastLimit",displayName:"Fast Limit",defaultValue:.5,hint:"Upper limit use in the adaptive algorithm",type:"Double",range:{min:.01,max:.99}},{name:"slowLimit",displayName:"Slow Limit",defaultValue:.05,hint:"Lower limit use in the adaptive algorithm",type:"Double",range:{min:.01,max:.99}}],outputs:[{name:"MAMA",type:"Double[]",plotHint:"line"},{name:"FAMA",type:"Double[]",plotHint:"line_dash"}]},MAVP:{name:"MAVP",camelCaseName:"movingAverageVariablePeriod",group:"Overlap Studies",description:"Moving average with variable period",inputs:[{name:"inReal",type:"Double[]"},{name:"inPeriods",type:"Double[]"}],options:[{name:"minPeriod",displayName:"Minimum Period",defaultValue:2,hint:"Value less than minimum will be changed to Minimum period",type:"Integer",range:{min:2,max:1e5}},{name:"maxPeriod",displayName:"Maximum Period",defaultValue:30,hint:"Value higher than maximum will be changed to Maximum period",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MAX:{name:"MAX",camelCaseName:"max",group:"Math Operators",description:"Highest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MAXINDEX:{name:"MAXINDEX",camelCaseName:"maxIndex",group:"Math Operators",description:"Index of highest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},MEDPRICE:{name:"MEDPRICE",camelCaseName:"medPrice",group:"Price Transform",description:"Median Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MFI:{name:"MFI",camelCaseName:"mfi",group:"Momentum Indicators",description:"Money Flow Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIDPOINT:{name:"MIDPOINT",camelCaseName:"midPoint",group:"Overlap Studies",description:"MidPoint over period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIDPRICE:{name:"MIDPRICE",camelCaseName:"midPrice",group:"Overlap Studies",description:"Midpoint Price over period",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIN:{name:"MIN",camelCaseName:"min",group:"Math Operators",description:"Lowest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MININDEX:{name:"MININDEX",camelCaseName:"minIndex",group:"Math Operators",description:"Index of lowest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},MINMAX:{name:"MINMAX",camelCaseName:"minMax",group:"Math Operators",description:"Lowest and highest values over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"min",type:"Double[]",plotHint:"line"},{name:"max",type:"Double[]",plotHint:"line"}]},MINMAXINDEX:{name:"MINMAXINDEX",camelCaseName:"minMaxIndex",group:"Math Operators",description:"Indexes of lowest and highest values over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"minIdx",type:"Integer[]",plotHint:"line"},{name:"maxIdx",type:"Integer[]",plotHint:"line"}]},MINUS_DI:{name:"MINUS_DI",camelCaseName:"minusDI",group:"Momentum Indicators",description:"Minus Directional Indicator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MINUS_DM:{name:"MINUS_DM",camelCaseName:"minusDM",group:"Momentum Indicators",description:"Minus Directional Movement",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MOM:{name:"MOM",camelCaseName:"mom",group:"Momentum Indicators",description:"Momentum",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MULT:{name:"MULT",camelCaseName:"mult",group:"Math Operators",description:"Vector Arithmetic Mult",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},NATR:{name:"NATR",camelCaseName:"natr",group:"Volatility Indicators",description:"Normalized Average True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},OBV:{name:"OBV",camelCaseName:"obv",group:"Volume Indicators",description:"On Balance Volume",inputs:[{name:"inReal",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PLUS_DI:{name:"PLUS_DI",camelCaseName:"plusDI",group:"Momentum Indicators",description:"Plus Directional Indicator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PLUS_DM:{name:"PLUS_DM",camelCaseName:"plusDM",group:"Momentum Indicators",description:"Plus Directional Movement",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PPO:{name:"PPO",camelCaseName:"ppo",group:"Momentum Indicators",description:"Percentage Price Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROC:{name:"ROC",camelCaseName:"roc",group:"Momentum Indicators",description:"Rate of change : ((price/prevPrice)-1)*100",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCP:{name:"ROCP",camelCaseName:"rocP",group:"Momentum Indicators",description:"Rate of change Percentage: (price-prevPrice)/prevPrice",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCR:{name:"ROCR",camelCaseName:"rocR",group:"Momentum Indicators",description:"Rate of change ratio: (price/prevPrice)",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCR100:{name:"ROCR100",camelCaseName:"rocR100",group:"Momentum Indicators",description:"Rate of change ratio 100 scale: (price/prevPrice)*100",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},RSI:{name:"RSI",camelCaseName:"rsi",group:"Momentum Indicators",description:"Relative Strength Index",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SAR:{name:"SAR",camelCaseName:"sar",group:"Overlap Studies",description:"Parabolic SAR",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"acceleration",displayName:"Acceleration Factor",defaultValue:.02,hint:"Acceleration Factor used up to the Maximum value",type:"Double",range:{min:0,max:3e37}},{name:"maximum",displayName:"AF Maximum",defaultValue:.2,hint:"Acceleration Factor Maximum value",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SAREXT:{name:"SAREXT",camelCaseName:"sarExt",group:"Overlap Studies",description:"Parabolic SAR - Extended",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"startValue",displayName:"Start Value",defaultValue:0,hint:"Start value and direction. 0 for Auto, >0 for Long, <0 for Short",type:"Double",range:{min:-3e37,max:3e37}},{name:"offsetOnReverse",displayName:"Offset on Reverse",defaultValue:0,hint:"Percent offset added/removed to initial stop on short/long reversal",type:"Double",range:{min:0,max:3e37}},{name:"accelerationInitLong",displayName:"AF Init Long",defaultValue:.02,hint:"Acceleration Factor initial value for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationLong",displayName:"AF Long",defaultValue:.02,hint:"Acceleration Factor for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationMaxLong",displayName:"AF Max Long",defaultValue:.2,hint:"Acceleration Factor maximum value for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationInitShort",displayName:"AF Init Short",defaultValue:.02,hint:"Acceleration Factor initial value for the Short direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationShort",displayName:"AF Short",defaultValue:.02,hint:"Acceleration Factor for the Short direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationMaxShort",displayName:"AF Max Short",defaultValue:.2,hint:"Acceleration Factor maximum value for the Short direction",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SIN:{name:"SIN",camelCaseName:"sin",group:"Math Transform",description:"Vector Trigonometric Sin",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SINH:{name:"SINH",camelCaseName:"sinh",group:"Math Transform",description:"Vector Trigonometric Sinh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SMA:{name:"SMA",camelCaseName:"sma",group:"Overlap Studies",description:"Simple Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SQRT:{name:"SQRT",camelCaseName:"sqrt",group:"Math Transform",description:"Vector Square Root",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},STDDEV:{name:"STDDEV",camelCaseName:"stdDev",group:"Statistic Functions",description:"Standard Deviation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"nbDev",displayName:"Deviations",defaultValue:1,hint:"Nb of deviations",type:"Double",range:{min:-3e37,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},STOCH:{name:"STOCH",camelCaseName:"stoch",group:"Momentum Indicators",description:"Stochastic",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"slowK_Period",displayName:"Slow-K Period",defaultValue:3,hint:"Smoothing for making the Slow-K line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"slowK_MAType",displayName:"Slow-K MA",defaultValue:0,hint:"Type of Moving Average for Slow-K",type:"MAType"},{name:"slowD_Period",displayName:"Slow-D Period",defaultValue:3,hint:"Smoothing for making the Slow-D line",type:"Integer",range:{min:1,max:1e5}},{name:"slowD_MAType",displayName:"Slow-D MA",defaultValue:0,hint:"Type of Moving Average for Slow-D",type:"MAType"}],outputs:[{name:"slowK",type:"Double[]",plotHint:"line_dash"},{name:"slowD",type:"Double[]",plotHint:"line_dash"}]},STOCHF:{name:"STOCHF",camelCaseName:"stochF",group:"Momentum Indicators",description:"Stochastic Fast",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_Period",displayName:"Fast-D Period",defaultValue:3,hint:"Smoothing for making the Fast-D line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_MAType",displayName:"Fast-D MA",defaultValue:0,hint:"Type of Moving Average for Fast-D",type:"MAType"}],outputs:[{name:"fastK",type:"Double[]",plotHint:"line"},{name:"fastD",type:"Double[]",plotHint:"line"}]},STOCHRSI:{name:"STOCHRSI",camelCaseName:"stochRsi",group:"Momentum Indicators",description:"Stochastic Relative Strength Index",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_Period",displayName:"Fast-D Period",defaultValue:3,hint:"Smoothing for making the Fast-D line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_MAType",displayName:"Fast-D MA",defaultValue:0,hint:"Type of Moving Average for Fast-D",type:"MAType"}],outputs:[{name:"fastK",type:"Double[]",plotHint:"line"},{name:"fastD",type:"Double[]",plotHint:"line"}]},SUB:{name:"SUB",camelCaseName:"sub",group:"Math Operators",description:"Vector Arithmetic Substraction",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SUM:{name:"SUM",camelCaseName:"sum",group:"Math Operators",description:"Summation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},T3:{name:"T3",camelCaseName:"t3",group:"Overlap Studies",description:"Triple Exponential Moving Average (T3)",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"VFactor",displayName:"Volume Factor",defaultValue:.7,hint:"Volume Factor",type:"Double",range:{min:0,max:1}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TAN:{name:"TAN",camelCaseName:"tan",group:"Math Transform",description:"Vector Trigonometric Tan",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TANH:{name:"TANH",camelCaseName:"tanh",group:"Math Transform",description:"Vector Trigonometric Tanh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TEMA:{name:"TEMA",camelCaseName:"tema",group:"Overlap Studies",description:"Triple Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRANGE:{name:"TRANGE",camelCaseName:"trueRange",group:"Volatility Indicators",description:"True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRIMA:{name:"TRIMA",camelCaseName:"trima",group:"Overlap Studies",description:"Triangular Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRIX:{name:"TRIX",camelCaseName:"trix",group:"Momentum Indicators",description:"1-day Rate-Of-Change (ROC) of a Triple Smooth EMA",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TSF:{name:"TSF",camelCaseName:"tsf",group:"Statistic Functions",description:"Time Series Forecast",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TYPPRICE:{name:"TYPPRICE",camelCaseName:"typPrice",group:"Price Transform",description:"Typical Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ULTOSC:{name:"ULTOSC",camelCaseName:"ultOsc",group:"Momentum Indicators",description:"Ultimate Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod1",displayName:"First Period",defaultValue:7,hint:"Number of bars for 1st period.",type:"Integer",range:{min:1,max:1e5}},{name:"timePeriod2",displayName:"Second Period",defaultValue:14,hint:"Number of bars fro 2nd period",type:"Integer",range:{min:1,max:1e5}},{name:"timePeriod3",displayName:"Third Period",defaultValue:28,hint:"Number of bars for 3rd period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},VAR:{name:"VAR",camelCaseName:"variance",group:"Statistic Functions",description:"Variance",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}},{name:"nbDev",displayName:"Deviations",defaultValue:1,hint:"Nb of deviations",type:"Double",range:{min:-3e37,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WCLPRICE:{name:"WCLPRICE",camelCaseName:"wclPrice",group:"Price Transform",description:"Weighted Close Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WILLR:{name:"WILLR",camelCaseName:"willR",group:"Momentum Indicators",description:"Williams' %R",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WMA:{name:"WMA",camelCaseName:"wma",group:"Overlap Studies",description:"Weighted Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]}};var XE=XE;let h0;function mJ(n,e){const t=n._malloc(e*8);return n.HEAPF64.set(new Float64Array(e),t/8),{data:n.HEAPF64.subarray(t/8,t/8+e),offset:t}}const Vtt={0:"TA_SUCCESS",1:"TA_LIB_NOT_INITIALIZE",2:"TA_BAD_PARAM",3:"TA_ALLOC_ERR",4:"TA_GROUP_NOT_FOUND",5:"TA_FUNC_NOT_FOUND",6:"TA_INVALID_HANDLE",7:"TA_INVALID_PARAM_HOLDER",8:"TA_INVALID_PARAM_HOLDER_TYPE",9:"TA_INVALID_PARAM_FUNCTION",10:"TA_INPUT_NOT_ALL_INITIALIZE",11:"TA_OUTPUT_NOT_ALL_INITIALIZE",12:"TA_OUT_OF_RANGE_START_INDEX",13:"TA_OUT_OF_RANGE_END_INDEX",14:"TA_INVALID_LIST_TYPE",15:"TA_BAD_OBJECT",16:"TA_NOT_SUPPORTED",5e3:"TA_INTERNAL_ERROR",65535:"TA_UNKNOWN_ERR"};function Oe(n,e){const t=`TA_${n.name}`;if(!h0)throw Error(`${n.name}() called before initialization.`);const i=2+n.inputs.length+n.options.length+2+n.outputs.length,r=new Array(i).fill("number");for(const{name:p}of n.inputs)if(!Array.isArray(e[p]))throw e[p]===void 0?Error(`Bad Param: "${p}" is required`):Error(`Bad Param: "${p}" should be array of number`);for(const{name:p,defaultValue:g,range:m}of n.options)if(e[p]===void 0)e[p]=g;else if(m&&(e[p]<m.min||e[p]>m.max))throw Error(`Bad Param: "${p}" out of range (min: ${m.min}, max: ${m.max})`);let{startIdx:o,endIdx:s}=e;o===void 0&&(o=0);const a=n.inputs.map(({name:p})=>e[p].length);s===void 0&&(s=Math.min(...a));const l=[o,s],u=[];n.inputs.forEach(({name:p})=>{const g=mJ(h0,s-o),m=e[p];for(const _ in m)g.data[_]=m[_];u.push(g),l.push(g.offset)}),n.options.forEach(({name:p})=>l.push(e[p])),l.push(0),l.push(0);const d=n.outputs.map(({name:p})=>{const g=mJ(h0,s-o);return u.push(g),l.push(g.offset),{name:p,array:g}}),h=h0.ccall(t,"number",r,l);u.forEach(p=>h0._free(p.offset));const f=d.reduce((p,g)=>(p[g.name]=Array.from(g.array.data),p),{});if(h===0)return f;throw Error("[C_ERROR] "+Vtt[h])}var JE;(function(n){n[n.SMA=0]="SMA",n[n.EMA=1]="EMA",n[n.WMA=2]="WMA",n[n.DEMA=3]="DEMA",n[n.TEMA=4]="TEMA",n[n.TRIMA=5]="TRIMA",n[n.KAMA=6]="KAMA",n[n.MAMA=7]="MAMA",n[n.T3=8]="T3"})(JE||(JE={}));function ek(n){return h0?Promise.resolve(h0):n&&typeof n!="string"?Promise.reject(new Error('Invalid argument, "init(wasmBinaryFilePath)" expects a string that specifies the location of wasm binary file')):XE({locateFile:n?()=>n:void 0}).then(t=>h0=t).catch(t=>{let i="TA-Lib WASM runtime init fail.";throw t&&t.message?i+=`
140
+ 入参: ${JSON.stringify(u.method==="post"?u.data:u.params)}`))}),{get:(a,l={},u={})=>s({method:"GET",url:`${sJ(n)}${a.startsWith("/middleLayer/")?"":"/middleLayer/get"}${a}`,params:l,...u}),post:(a,l={},u={})=>s({method:"POST",url:`${sJ(n)}${a.startsWith("/middleLayer/")?"":"/middleLayer/post"}${a}`,data:l,...u})}},wet=Object.freeze(Object.defineProperty({__proto__:null,initRequest:Cet},Symbol.toStringTag,{value:"Module"}));var xet=Object.defineProperty,Det=(n,e,t)=>e in n?xet(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,_4=(n,e,t)=>Det(n,typeof e!="symbol"?e+"":e,t);class aJ{constructor(e,t={}){_4(this,"dom"),_4(this,"resizeRo"),_4(this,"callback"),_4(this,"visibilitychangeFn"),_4(this,"timer"),_4(this,"config",{debounce:50}),this.dom=e,this.config={...this.config,...t}}listen(e){this.callback=e;let t=!0;this.resizeRo=new ResizeObserver(()=>{if(t){t=!1;return}clearTimeout(this.timer),this.timer=setTimeout(()=>{this.callback&&this.callback(),clearTimeout(this.timer)},this.config.debounce)}),this.resizeRo.observe(this.dom),this.visibilitychangeFn=()=>{(document.visibilityState==="visible"||!document.hidden)&&this.callback&&this.callback()},document.addEventListener("visibilitychange",this.visibilitychangeFn)}dispose(){var e;(e=this.resizeRo)==null||e.disconnect(),document.removeEventListener("visibilitychange",this.visibilitychangeFn)}}const Net=n=>new aJ(n),Eet=Object.freeze(Object.defineProperty({__proto__:null,ResizeListener:aJ,addResizeListener:Net},Symbol.toStringTag,{value:"Module"}));`${new Date().getTime()}${Math.floor(Math.random()*1e9)}`;const ket=n=>{n?PH("token",n):console.error("token不能为空")},Let=n=>{n?PH("userData",n):console.error("用户数据不能为空")},lJ=()=>BH("token"),uJ=n=>{const e=BH("userData");return n?e==null?void 0:e[n]:e},Met=()=>!!lJ(),Tet=()=>{const n=uJ();return(n==null?void 0:n.username)==="admin"},cJ=(n="")=>location.href=`${location.origin}/login/index.html?url=${encodeURIComponent(n||location.href)}`,Aet=(n=!0,e)=>{if(VH("token"),VH("userData"),n){cJ();return}e&&(location.href=e)},Iet=Object.freeze(Object.defineProperty({__proto__:null,getToken:lJ,getUserData:uJ,isAdmin:Tet,isLogin:Met,login:cJ,loginout:Aet,setToken:ket,setUserData:Let},Symbol.toStringTag,{value:"Module"})),bl=yet,{initRequest:dJ}=wet,{addResizeListener:hJ}=Eet,{setToken:OLt,setUserData:GE,getToken:fJ,getUserData:R1,isLogin:pJ,isAdmin:FLt,login:Ret,loginout:YE}=Iet,F2=(n,e=500,t=!1)=>{let i=null;return function(...r){if(clearTimeout(i),t){const o=!i;i=setTimeout(()=>{i=null},e),o&&n.apply(this,r)}else i=setTimeout(()=>{n.apply(this,r)},e)}},Oet={__name:"index",props:{env:{type:Object,default:()=>({})}},setup(n){const e=r=>{const o=dJ(r,{handleReq:s=>{pJ()&&(s.headers.token=fJ(),s.headers.userId=R1("userId"))},handleRes:s=>{const{data:a}=s;if(a.code===401)return location.origin.includes("localhost")?location.href=`${location.origin}/#/404`:YE(),!0}});return{get:o.get,post:o.post}},t=n,i=c.reactive({env:t.env,request:e(t.env)});return c.watch(()=>t,r=>{Object.assign(i,toRefs(r)),console.log("已更新神兔组件库配置: ",i)},{deep:!0}),console.log("%c√ 已成功注入神兔组件库配置: ","color: green",i),c.provide("stConfig",i),(r,o)=>c.renderSlot(r.$slots,"default")}},Fet={install(n){n.component("st-configProvider",Oet)}},PLt="",Pet=vn({__name:"index",emits:["close","open"],setup(n,{emit:e}){const t=e,i=c.ref(),r=c.ref(),o=c.ref({x:0,y:0}),s=c.ref(!1),a=c.computed(()=>({display:s.value?"block":"none",top:`${o.value.y}px`,left:`${o.value.x}px`})),l=()=>{s.value=!1,t("close"),document.removeEventListener("click",l)},u=f=>{var p;(p=r.value)!=null&&p.contains(f.relatedTarget)||l()},d=async f=>{if(f.preventDefault(),s.value&&r.value){const _=r.value.getBoundingClientRect();if(f.clientX>=_.left&&f.clientX<=_.right&&f.clientY>=_.top&&f.clientY<=_.bottom)return}const p=i.value.getBoundingClientRect();let g=f.clientX-p.left,m=f.clientY-p.top;o.value={x:g,y:m},s.value=!0,t("open"),await c.nextTick(),h(),document.addEventListener("click",l)},h=()=>{if(!r.value||!i.value)return;const f=i.value.getBoundingClientRect(),p=r.value.getBoundingClientRect();let{x:g,y:m}=o.value;g+p.width>f.width&&(g=Math.max(0,g-p.width)),m+p.height>f.height&&(m=Math.max(0,m-p.height)),g<0&&(g=0),m<0&&(m=0),o.value={x:g,y:m}};return(f,p)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"contextmenuRef",ref:i,class:"contextmenu",onMouseleave:u,onContextmenu:d},[c.renderSlot(f.$slots,"default",{},void 0,!0),s.value?(c.openBlock(),c.createElementBlock("div",{key:0,ref_key:"contextmenuContentRef",ref:r,class:"contextmenu-popover",style:c.normalizeStyle(a.value),onContextmenu:p[0]||(p[0]=c.withModifiers(()=>{},["stop"]))},[c.renderSlot(f.$slots,"popover",{},void 0,!0)],36)):c.createCommentVNode("",!0)],544))}},[["__scopeId","data-v-34926651"]]),Bet={install(n){n.component("st-contextmenu",Pet)}},VLt="",zLt="",HLt="",jLt="",WLt="",$Lt="",ULt="",qLt="",KLt="",GLt="",YLt="",QLt="",ZLt="",XLt="",JLt="",eMt="",tMt="",nMt="",iMt="",rMt="",gJ=n=>(c.pushScopeId("data-v-ff7c4544"),n=n(),c.popScopeId(),n),Vet={class:"custom-function"},zet={class:"func-option"},Het={class:"icons"},jet={class:"custom-header"},Wet={class:"left"},$et=["id"],Uet={class:"right"},qet={class:"func-name"},Ket={class:"left"},Get=gJ(()=>c.createElementVNode("span",null,"函数名称:",-1)),Yet={class:"right"},Qet=gJ(()=>c.createElementVNode("div",{class:"tip-box"},"Tip: 公式里可以使用变量, 变量名命名格式: ${变量名}, 后续可在应用函数时填写具体值, 系统会自动换算",-1)),Zet={class:"dialog-footer"},Xet={class:"custom-header"},Jet={class:"left"},ett=["id"],ttt={class:"right"},ntt={class:"content"},itt={class:"dialog-footer"},rtt=vn({__name:"index",props:{size:{type:String,default:"small"},selectWidth:{type:String,default:"200px"}},emits:["insert"],setup(n,{emit:e}){const{request:t}=c.inject("stConfig"),i=c.ref(null),r=c.ref(null),o=e,s=c.ref(null),a=c.ref(""),l=c.ref([]),u=c.ref(!1),d=c.reactive({id:null,funcName:"",funcExpression:""}),h=c.ref(!1),f=c.ref(!1),p=c.ref(!1),g=c.reactive({result:null,detail:"",code:""}),m=async()=>{const{body:E}=await t.post("/common/qt/querySearchFunctions");if(l.value=E??[],s.value===null)a.value="";else{const k=l.value.find(({id:A})=>A===s.value);a.value=k?k.funcName:""}},_=E=>{var k;E?s.value=(k=l.value.find(A=>A.funcName===E))==null?void 0:k.id:s.value=null},b=async E=>{await t.post("/common/qt/deleteSearchFunctionById",{id:E.id}),m()},C=(E,k)=>{switch(!!E){case!1:{Object.assign(d,{id:null,funcName:"",funcExpression:""});break}case!0:{Object.assign(d,{id:E.id,funcName:E.funcName,funcExpression:E.funcExpression});break}}k&&(d.id=null,d.funcName=`${d.funcName}-复制`),u.value=!0},y=async()=>{try{if(h.value=!0,d.funcExpression=i.value.getValue(),!d.funcName)return An.error("函数名称不可为空");if(!d.funcExpression)return An.error("函数内容不可为空");await t.post("/common/qt/saveOrUpdateSearchFunction",d),An.success("操作成功"),u.value=!1,await m()}finally{h.value=!1}},v=()=>{if(!a.value)return An.error("请先选择自定义函数后, 再执行插入");const{funcName:E,funcExpression:k}=l.value.find(A=>A.funcName===a.value);o("insert",E,k)},w=E=>{const k=/\$\{([^}]*)\}/g,A=[];let R;for(;(R=k.exec(E))!==null;)A.push(R[1]);return[...new Set(A)]},x=(E,k)=>E.replace(/\$\{([^}]*)\}/g,(A,R)=>k[R]!==void 0?k[R]:A),S=E=>new Promise(k=>{const A=c.ref(E.reduce((M,O)=>(M[O]="",M),{})),R=c.ref({}),B=()=>{let M=!0;const O={};return E.forEach(F=>{var $;($=A.value[F])!=null&&$.trim()||(O[F]=`请输入${F}的值`,M=!1)}),R.value=O,M},I={setup(){return()=>c.h("div",[c.h(Hh,{model:A.value},()=>E.map(M=>c.h(jh,{label:`${M}: `,prop:M,error:R.value[M],"label-width":"90px"},()=>c.h(xs,{modelValue:A.value[M],"onUpdate:modelValue":O=>{A.value[M]=O,R.value[M]&&delete R.value[M]},placeholder:`请输入 ${M} 的值`,status:R.value[M]?"error":""}))))])}};lD({title:"填写变量值用于接口测试",message:c.h(I),showCancelButton:!0,confirmButtonText:"确定",cancelButtonText:"取消",customClass:"variable-input-dialog",beforeClose:async(M,O,F)=>{M!=="confirm"&&(k(!1),F()),await c.nextTick(),B()&&(k({...A.value}),F())}}).catch(()=>k(!1))}),N=async()=>{try{p.value=!0;let E=i.value.getValue();if(!E)return An.error("函数内容不可为空");if(/\$\{[^}]*\}/.test(E)){const B=w(E),I=await S(B);if(!I)return;E=x(E,I)}const{body:k}=await t.post("/common/qt/testFactorSelect",{factorSelectExpr:E}),{result:A,detail:R}=k;Object.assign(g,{result:A,detail:R,code:E}),A===1?An.success("测试通过"):(An.error("测试未能通过"),f.value=!0)}finally{p.value=!1}},D=()=>{if(g.result===null)return An.warning("请先进行测试, 等待测试完成后可查看日志");f.value=!0},L=()=>{r.value.open(i.value)};return c.onMounted(()=>{m()}),c.watch(()=>u.value,E=>{switch(E){case!0:{c.nextTick(()=>{var k,A;(k=i.value)==null||k.setValue(d.funcExpression),(A=i.value)==null||A.resize()}),Object.assign(g,{result:null,detail:""});break}case!1:{r.value.close();break}}}),(E,k)=>{const A=fn,R=CS,B=Gl,I=Kl,M=so,O=xs,F=c.resolveComponent("st-monacoEditor"),$=ql,Y=s1,U=nS,z=c.resolveComponent("st-varSelectDialog");return c.openBlock(),c.createElementBlock("div",Vet,[c.createVNode(I,{modelValue:a.value,"onUpdate:modelValue":k[0]||(k[0]=ne=>a.value=ne),size:n.size,placeholder:"自定义函数","no-match-text":"无匹配选项","no-data-text":"无选项数据",clearable:"",filterable:"",onChange:_,style:c.normalizeStyle({width:n.selectWidth})},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(l.value,ne=>(c.openBlock(),c.createBlock(B,{key:ne.id,label:ne.funcName,value:ne.funcName,onClick:v},{default:c.withCtx(()=>[c.createElementVNode("div",zet,[c.createElementVNode("span",null,c.toDisplayString(ne.funcName),1),c.createElementVNode("div",Het,[c.createVNode(A,{onClick:c.withModifiers(le=>C(ne,!0),["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(Mge))]),_:2},1032,["onClick"]),c.createVNode(A,{onClick:c.withModifiers(le=>C(ne),["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(Rge))]),_:2},1032,["onClick"]),c.createVNode(R,{title:"确认是否删除?","confirm-button-text":"确认","cancel-button-text":"取消",onConfirm:le=>b(ne)},{reference:c.withCtx(()=>[c.createVNode(A,{onClick:c.withModifiers(()=>{},["stop"])},{default:c.withCtx(()=>[c.createVNode(c.unref(kge))]),_:1})]),_:2},1032,["onConfirm"])])])]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","size","style"]),c.createVNode(M,{type:"primary",size:n.size,onClick:v},{default:c.withCtx(()=>[c.createTextVNode(" 插入 ")]),_:1},8,["size"]),c.createVNode(M,{type:"primary",size:n.size,onClick:k[1]||(k[1]=ne=>C())},{default:c.withCtx(()=>[c.createTextVNode(" 新建 ")]),_:1},8,["size"]),c.createVNode($,{"modal-class":"add-or-edit-dialog",modelValue:u.value,"onUpdate:modelValue":k[4]||(k[4]=ne=>u.value=ne),width:"1000","align-center":"","append-to-body":"",draggable:"",overflow:"",modal:!1,"modal-penetrable":!0,"show-close":!1},{header:c.withCtx(({titleId:ne,titleClass:le})=>[c.createElementVNode("div",jet,[c.createElementVNode("div",Wet,[c.createElementVNode("span",{id:ne,class:c.normalizeClass(le)},c.toDisplayString(d.id?"编辑自定义函数":"新建自定义函数"),11,$et)]),c.createElementVNode("div",Uet,[c.createVNode(M,{size:"small",type:"primary",onClick:L},{default:c.withCtx(()=>[c.createTextVNode(" 变量选择器 ")]),_:1}),c.createVNode(A,{onClick:k[2]||(k[2]=ue=>u.value=!1)},{default:c.withCtx(()=>[c.createVNode(c.unref(r1))]),_:1})])])]),footer:c.withCtx(()=>[c.createElementVNode("div",Zet,[c.createVNode(M,{type:"primary",loading:h.value,onClick:y},{default:c.withCtx(()=>[c.createTextVNode(" 确定 ")]),_:1},8,["loading"])])]),default:c.withCtx(()=>[c.createElementVNode("div",qet,[c.createElementVNode("div",Ket,[Get,c.createVNode(O,{modelValue:d.funcName,"onUpdate:modelValue":k[3]||(k[3]=ne=>d.funcName=ne)},null,8,["modelValue"])]),c.createElementVNode("div",Yet,[c.createVNode(M,{type:"primary",loading:p.value,onClick:N},{default:c.withCtx(()=>[c.createTextVNode(" 测试 ")]),_:1},8,["loading"]),c.createVNode(M,{icon:c.unref(Age),onClick:D},{default:c.withCtx(()=>[c.createTextVNode(" 日志明细 ")]),_:1},8,["icon"])])]),Qet,c.createVNode(F,{ref_key:"stMonacoEditorRef",ref:i,language:"lua",style:{width:"968px",height:"400px"}},null,512)]),_:1},8,["modelValue"]),c.createVNode($,{"modal-class":"log-dialog",modelValue:f.value,"onUpdate:modelValue":k[7]||(k[7]=ne=>f.value=ne),width:"830","align-center":"","append-to-body":"",draggable:"",overflow:"",modal:!1,"modal-penetrable":!0,"show-close":!1},{header:c.withCtx(({titleId:ne,titleClass:le})=>[c.createElementVNode("div",Xet,[c.createElementVNode("div",Jet,[c.createElementVNode("span",{id:ne,class:c.normalizeClass(le)}," 日志明细 ",10,ett)]),c.createElementVNode("div",ttt,[c.createVNode(A,{onClick:k[5]||(k[5]=ue=>f.value=!1)},{default:c.withCtx(()=>[c.createVNode(c.unref(r1))]),_:1})])])]),footer:c.withCtx(()=>[c.createElementVNode("div",itt,[c.createVNode(M,{onClick:k[6]||(k[6]=ne=>f.value=!1)},{default:c.withCtx(()=>[c.createTextVNode(" 关闭 ")]),_:1})])]),default:c.withCtx(()=>[c.createElementVNode("div",ntt,[c.createVNode(Y,{class:"code",height:"600px"},{default:c.withCtx(()=>[c.createElementVNode("pre",null,c.toDisplayString(g.code),1)]),_:1}),c.createVNode(U,{direction:"vertical"}),c.createVNode(Y,{height:"600px"},{default:c.withCtx(()=>[c.createElementVNode("pre",{class:c.normalizeClass(g.result===1?"success-log":"error-log")},c.toDisplayString(g.result===1?"测试通过 √":g.detail),3)]),_:1})])]),_:1},8,["modelValue"]),c.createVNode(z,{ref_key:"stVarSelectDialogRef",ref:r},null,512)])}}},[["__scopeId","data-v-ff7c4544"]]),ott={install(n){n.component("st-customFunction",rtt)}},sMt="",aMt="",lMt="",uMt="",cMt="",dMt="",hMt="",fMt="",pMt="";var QE={name:"zh-cn",el:{breadcrumb:{label:"面包屑"},colorpicker:{confirm:"确定",clear:"清空",defaultLabel:"颜色选择器",description:"当前颜色 {color},按 Enter 键选择新颜色",alphaLabel:"选择透明度的值"},datepicker:{now:"此刻",today:"今天",cancel:"取消",clear:"清空",confirm:"确定",dateTablePrompt:"使用方向键与 Enter 键可选择日期",monthTablePrompt:"使用方向键与 Enter 键可选择月份",yearTablePrompt:"使用方向键与 Enter 键可选择年份",selectedDate:"已选日期",selectDate:"选择日期",selectTime:"选择时间",startDate:"开始日期",startTime:"开始时间",endDate:"结束日期",endTime:"结束时间",prevYear:"前一年",nextYear:"后一年",prevMonth:"上个月",nextMonth:"下个月",year:"年",month1:"1 月",month2:"2 月",month3:"3 月",month4:"4 月",month5:"5 月",month6:"6 月",month7:"7 月",month8:"8 月",month9:"9 月",month10:"10 月",month11:"11 月",month12:"12 月",weeks:{sun:"日",mon:"一",tue:"二",wed:"三",thu:"四",fri:"五",sat:"六"},weeksFull:{sun:"星期日",mon:"星期一",tue:"星期二",wed:"星期三",thu:"星期四",fri:"星期五",sat:"星期六"},months:{jan:"一月",feb:"二月",mar:"三月",apr:"四月",may:"五月",jun:"六月",jul:"七月",aug:"八月",sep:"九月",oct:"十月",nov:"十一月",dec:"十二月"}},inputNumber:{decrease:"减少数值",increase:"增加数值"},select:{loading:"加载中",noMatch:"无匹配数据",noData:"无数据",placeholder:"请选择"},dropdown:{toggleDropdown:"切换下拉选项"},mention:{loading:"加载中"},cascader:{noMatch:"无匹配数据",loading:"加载中",placeholder:"请选择",noData:"暂无数据"},pagination:{goto:"前往",pagesize:"条/页",total:"共 {total} 条",pageClassifier:"页",page:"页",prev:"上一页",next:"下一页",currentPage:"第 {pager} 页",prevPages:"向前 {pager} 页",nextPages:"向后 {pager} 页",deprecationWarning:"你使用了一些已被废弃的用法,请参考 el-pagination 的官方文档"},dialog:{close:"关闭此对话框"},drawer:{close:"关闭此对话框"},messagebox:{title:"提示",confirm:"确定",cancel:"取消",error:"输入的数据不合法!",close:"关闭此对话框"},upload:{deleteTip:"按 Delete 键可删除",delete:"删除",preview:"查看图片",continue:"继续上传"},slider:{defaultLabel:"滑块介于 {min} 至 {max}",defaultRangeStartLabel:"选择起始值",defaultRangeEndLabel:"选择结束值"},table:{emptyText:"暂无数据",confirmFilter:"筛选",resetFilter:"重置",clearFilter:"全部",sumText:"合计"},tour:{next:"下一步",previous:"上一步",finish:"结束导览",close:"关闭此对话框"},tree:{emptyText:"暂无数据"},transfer:{noMatch:"无匹配数据",noData:"无数据",titles:["列表 1","列表 2"],filterPlaceholder:"请输入搜索内容",noCheckedFormat:"共 {total} 项",hasCheckedFormat:"已选 {checked}/{total} 项"},image:{error:"加载失败"},pageHeader:{title:"返回"},popconfirm:{confirmButtonText:"确定",cancelButtonText:"取消"},carousel:{leftArrow:"上一张幻灯片",rightArrow:"下一张幻灯片",indicator:"幻灯片切换至索引 {index}"}}};const stt={ruleFormPrice:!0,ruleFormMark:!0,tableStatus:!0,tableCreateTime:!0,tableMark:!0,tableEnable:!0},gMt="",f_=n=>(c.pushScopeId("data-v-b2d15520"),n=n(),c.popScopeId(),n),att={class:"st-factorWarning"},ltt={class:"custom-header"},utt=f_(()=>c.createElementVNode("span",{style:{"margin-right":"4px"}},"因子预警",-1)),ctt={class:"factor-name"},dtt=["onClick"],htt={class:"factor-name"},ftt=["onClick"],ptt={style:{display:"flex","align-items":"start"}},gtt={key:0,style:{flex:"1"}},mtt=f_(()=>c.createElementVNode("span",{style:{margin:"0 5px"}},"~",-1)),btt={key:0,style:{color:"#f56c6c"}},_tt={key:1,style:{color:"#67c23a"}},ytt={key:0},vtt={key:1},Ctt={key:2},wtt={class:"shortcut-title"},xtt=f_(()=>c.createElementVNode("span",null,"我的配置",-1)),Stt={class:"shortcut-config"},Dtt={key:1,class:"empty"},Ntt={class:"shortcut-title"},Ett=f_(()=>c.createElementVNode("span",null,"新增配置",-1)),ktt={class:"custom-footer"},Ltt=vn({__name:"index",props:c.mergeModels({title:{type:[String,null],default:null},moreFactorOptions:{type:Array,default:()=>[]},emptyFactorOptions:{type:Array,default:()=>[]},tableData:{type:Array,default:()=>[]},shortcutData:{type:Array,default:()=>[]},showConfig:{type:Object,default:()=>({})},allowOperation:{type:Boolean,default:!0}},{visible:{default:!1},visibleModifiers:{}}),emits:c.mergeModels(["add","delete","enabled","closed","shortcutAdd","shortcutDelete"],["update:visible"]),setup(n,{emit:e}){const t=c.ref("ruleForm"),i=c.useModel(n,"visible"),r=e,o=n,s=Object.assign(stt,o.showConfig),a=c.ref(null),l=c.ref({factorType:1,factorSelectedList:[],totalCount:1,minPrice:null,maxPrice:null,mark:null}),u=c.ref({factorType:[{required:!0,message:"请选择交易类型",trigger:"blur"}],factorSelectedList:[{required:!0,message:"请选择预警因子",trigger:"blur"}],totalCount:[{required:!0,message:"请填写预警次数",trigger:"blur"}]}),d=c.ref(null),h=c.ref({shortcutName:null,factorType:1,factorSelectedList:[],totalCount:1}),f=c.ref({factorType:[{required:!0,message:"请选择交易类型",trigger:"blur"}],factorSelectedList:[{required:!0,message:"请选择预警因子",trigger:"blur"}],totalCount:[{required:!0,message:"请填写预警次数",trigger:"blur"}],shortcutName:[{required:!0,message:"请填写配置名称",trigger:"blur"}]}),p=()=>{l.value={factorType:1,factorSelectedList:[],totalCount:1,minPrice:null,maxPrice:null,mark:null},h.value={shortcutName:null,factorType:1,factorSelectedList:[],totalCount:1}},g=async v=>{Object.assign(l.value,{factorSelectedList:[v],totalCount:3});const w={factorSelectedList:l.value.factorSelectedList.map(S=>{let N=3;const D=o.tableData.find(({factorExtendName:L})=>L===S);if(D){const L=D.totalCount-D.currentCount;L===0?N=3:N=Math.min(3,12-L>=0?12-L:0)}return{factorName:S,...l.value,totalCount:N}})},x=()=>{const S=l.value.factorType;p(),l.value.factorType=S};_(a.value,w,x)},m=async v=>{const w=JSON.parse(v.data);Object.assign(l.value,{factorType:w.factorType,factorSelectedList:w.factorSelectedList,totalCount:w.totalCount});const x={factorSelectedList:l.value.factorSelectedList.map(N=>{let D=w.totalCount;const L=o.tableData.find(({factorExtendName:E})=>E===N);if(L){const E=L.totalCount-L.currentCount;E===0?D=w.totalCount:D=Math.min(w.totalCount,10-E>=0?10-E:0)}return{factorName:N,...l.value,totalCount:D}})},S=()=>p();_(a.value,x,S)},_=F2(async(v,w,x)=>{v&&await v.validate(S=>{if(!S)return!1;const N=w??{factorSelectedList:l.value.factorSelectedList.map(D=>({factorName:D,...l.value}))};r("add",N),x?x():i.value=!1})},200),b=async v=>{v&&await v.validate(w=>{if(!w)return!1;const x={shortcutName:h.value.shortcutName,data:JSON.stringify(h.value)};r("shortcutAdd",x),p()})},C=v=>{h.value=JSON.parse(v.data)},y=v=>{lD.confirm(`是否确认删除配置: ${v.shortcutName} ?`,"删除提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>r("shortcutDelete",v))};return c.watch(()=>i.value,v=>{v&&(t.value=o.allowOperation?"ruleForm":"table",p())},{immediate:!0}),(v,w)=>{const x=LH,S=so,N=jh,D=u1,L=mV,E=R6,k=G6,A=xs,R=Hh,B=QS,I=CS,M=YS,O=fn,F=xa,$=k6,Y=ql,U=Xx;return c.openBlock(),c.createElementBlock("div",att,[c.createVNode(U,{locale:c.unref(QE)},{default:c.withCtx(()=>[c.createVNode(Y,{modelValue:i.value,"onUpdate:modelValue":w[17]||(w[17]=z=>i.value=z),width:"1020","align-center":"","destroy-on-close":"",onClosed:w[18]||(w[18]=z=>r("closed"))},{header:c.withCtx(({close:z,titleId:ne,titleClass:le})=>[c.createElementVNode("div",ltt,[c.createElementVNode("div",{class:c.normalizeClass(le)},[utt,c.createElementVNode("span",null,c.toDisplayString(n.title),1)],2),c.createVNode(x,{modelValue:t.value,"onUpdate:modelValue":w[0]||(w[0]=ue=>t.value=ue),size:"default",options:[{label:"添加",value:"ruleForm",disabled:!n.allowOperation},{label:"管理",value:"table",disabled:!1},{label:"快捷配置",value:"shortcut",disabled:!n.allowOperation}]},null,8,["modelValue","options"])])]),footer:c.withCtx(()=>[c.createElementVNode("div",ktt,[c.createVNode(S,{size:"default",onClick:w[14]||(w[14]=z=>i.value=!1)},{default:c.withCtx(()=>[c.createTextVNode("关闭")]),_:1}),t.value==="ruleForm"?(c.openBlock(),c.createBlock(S,{key:0,size:"default",type:"primary",onClick:w[15]||(w[15]=z=>c.unref(_)(a.value))},{default:c.withCtx(()=>[c.createTextVNode(" 确认 ")]),_:1})):c.createCommentVNode("",!0),t.value==="shortcut"?(c.openBlock(),c.createBlock(S,{key:1,size:"default",type:"primary",onClick:w[16]||(w[16]=z=>b(d.value))},{default:c.withCtx(()=>[c.createTextVNode(" 保存配置 ")]),_:1})):c.createCommentVNode("",!0)])]),default:c.withCtx(()=>[t.value==="ruleForm"?(c.openBlock(),c.createBlock(R,{key:0,ref_key:"ruleFormRef",ref:a,model:l.value,rules:u.value,size:"default","label-width":"90px"},{default:c.withCtx(()=>[c.createVNode(N,{label:"交易类型:",prop:"factorType"},{default:c.withCtx(()=>[c.createVNode(S,{type:"danger",plain:l.value.factorType!==1,onClick:w[1]||(w[1]=()=>{l.value.factorType===-1&&(l.value.factorSelectedList=[]),l.value.factorType=1})},{default:c.withCtx(()=>[c.createTextVNode(" 多 ")]),_:1},8,["plain"]),c.createVNode(S,{type:"success",plain:l.value.factorType!==-1,onClick:w[2]||(w[2]=()=>{l.value.factorType===1&&(l.value.factorSelectedList=[]),l.value.factorType=-1})},{default:c.withCtx(()=>[c.createTextVNode(" 空 ")]),_:1},8,["plain"])]),_:1}),c.createVNode(N,{label:"预警因子:",prop:"factorSelectedList"},{default:c.withCtx(()=>[c.createVNode(L,{modelValue:l.value.factorSelectedList,"onUpdate:modelValue":w[3]||(w[3]=z=>l.value.factorSelectedList=z)},{default:c.withCtx(()=>[l.value.factorType===1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.moreFactorOptions,(z,ne)=>(c.openBlock(),c.createElementBlock("div",{class:"factor-checkbox",key:ne},[c.createVNode(D,{label:z.factorTypeName,value:z.factorTypeName},{default:c.withCtx(()=>[c.createElementVNode("span",ctt,c.toDisplayString(z.factorTypeName),1)]),_:2},1032,["label","value"]),c.createElementVNode("span",{class:"tag-button",onClick:le=>g(z.factorTypeName)},"+3",8,dtt)]))),128)):c.createCommentVNode("",!0),l.value.factorType===-1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:1},c.renderList(n.emptyFactorOptions,(z,ne)=>(c.openBlock(),c.createElementBlock("div",{class:"factor-checkbox",key:ne},[c.createVNode(D,{label:z.factorTypeName,value:z.factorTypeName},{default:c.withCtx(()=>[c.createElementVNode("span",htt,c.toDisplayString(z.factorTypeName),1)]),_:2},1032,["label","value"]),c.createElementVNode("span",{class:"tag-button",onClick:le=>g(z.factorTypeName)},"+3",8,ftt)]))),128)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1}),c.createVNode(N,{label:"预警次数:",prop:"totalCount"},{default:c.withCtx(()=>[c.createElementVNode("div",ptt,[c.createVNode(E,{modelValue:l.value.totalCount,"onUpdate:modelValue":w[4]||(w[4]=z=>l.value.totalCount=z),min:1,"controls-position":"right",style:{"margin-right":"20px"}},null,8,["modelValue"]),n.shortcutData.length?(c.openBlock(),c.createElementBlock("div",gtt,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.shortcutData,z=>(c.openBlock(),c.createBlock(S,{key:z.id,onClick:ne=>m(z),style:{margin:"0 12px 4px 0"}},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(z.shortcutName),1)]),_:2},1032,["onClick"]))),128))])):(c.openBlock(),c.createBlock(k,{key:1,type:"primary",style:{cursor:"pointer"},onClick:w[5]||(w[5]=()=>t.value="shortcut")},{default:c.withCtx(()=>[c.createTextVNode(" 暂无快捷配置, 是否点击前往自定义配置? ")]),_:1}))])]),_:1}),c.unref(s).ruleFormPrice?(c.openBlock(),c.createBlock(N,{key:0,label:"价格范围:"},{default:c.withCtx(()=>[c.createVNode(E,{modelValue:l.value.minPrice,"onUpdate:modelValue":w[6]||(w[6]=z=>l.value.minPrice=z),min:-999,placeholder:"请输入",max:999,"controls-position":"right"},null,8,["modelValue"]),mtt,c.createVNode(E,{modelValue:l.value.maxPrice,"onUpdate:modelValue":w[7]||(w[7]=z=>l.value.maxPrice=z),placeholder:"请输入",min:-999,max:999,"controls-position":"right"},null,8,["modelValue"])]),_:1})):c.createCommentVNode("",!0),c.unref(s).ruleFormMark?(c.openBlock(),c.createBlock(N,{key:1,label:"备注:"},{default:c.withCtx(()=>[c.createVNode(A,{modelValue:l.value.mark,"onUpdate:modelValue":w[8]||(w[8]=z=>l.value.mark=z),type:"textarea",placeholder:"请输入关键字",rows:2,style:{width:"380px"}},null,8,["modelValue"])]),_:1})):c.createCommentVNode("",!0)]),_:1},8,["model","rules"])):c.createCommentVNode("",!0),t.value==="table"?(c.openBlock(),c.createBlock(M,{key:1,data:n.tableData,size:"small"},{default:c.withCtx(()=>[c.createVNode(B,{label:"预警周期",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.freqName||"-"),1)]),_:1}),c.createVNode(B,{label:"交易类型",width:"70"},{default:c.withCtx(z=>[z.row.factorExtendValue==1?(c.openBlock(),c.createElementBlock("span",btt,"多")):(c.openBlock(),c.createElementBlock("span",_tt,"空"))]),_:1}),c.createVNode(B,{label:"预警因子"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.factorExtendName||"-"),1)]),_:1}),c.createVNode(B,{label:"预警次数",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(`${z.row.currentCount} / ${z.row.totalCount}`),1)]),_:1}),c.unref(s).tableStatus?(c.openBlock(),c.createBlock(B,{key:0,label:"状态",width:"70"},{default:c.withCtx(z=>[c.createElementVNode("div",null,[z.row.enable===1?(c.openBlock(),c.createElementBlock("span",ytt,"未触发")):z.row.enable===2?(c.openBlock(),c.createElementBlock("span",vtt,"已触发")):(c.openBlock(),c.createElementBlock("span",Ctt,"-"))])]),_:1})):c.createCommentVNode("",!0),c.unref(s).tableCreateTime?(c.openBlock(),c.createBlock(B,{key:1,label:"设置时间",width:"136"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.createdTime||"-"),1)]),_:1})):c.createCommentVNode("",!0),c.unref(s).tableMark?(c.openBlock(),c.createBlock(B,{key:2,label:"备注",width:"70"},{default:c.withCtx(z=>[c.createTextVNode(c.toDisplayString(z.row.mark||"-"),1)]),_:1})):c.createCommentVNode("",!0),n.allowOperation?(c.openBlock(),c.createBlock(B,{key:3,label:"操作",width:"140"},{default:c.withCtx(z=>[c.unref(s).tableEnable?(c.openBlock(),c.createBlock(S,{key:0,disabled:z.row.currentCount!==z.row.totalCount,size:"small",onClick:ne=>r("enabled",z.row)},{default:c.withCtx(()=>[c.createTextVNode(" 启用 ")]),_:2},1032,["disabled","onClick"])):c.createCommentVNode("",!0),c.createVNode(I,{title:"确定删除?",onConfirm:ne=>r("delete",z.row)},{reference:c.withCtx(()=>[c.createVNode(S,{size:"small"},{default:c.withCtx(()=>[c.createTextVNode("删除")]),_:1})]),_:2},1032,["onConfirm"])]),_:1})):c.createCommentVNode("",!0)]),_:1},8,["data"])):c.createCommentVNode("",!0),t.value==="shortcut"?(c.openBlock(),c.createElementBlock(c.Fragment,{key:2},[c.createElementVNode("div",wtt,[xtt,c.createVNode(F,{effect:"dark",content:"如有配置数据, 可点击查看该配置的具体信息",placement:"right-start"},{default:c.withCtx(()=>[c.createVNode(O,null,{default:c.withCtx(()=>[c.createVNode(c.unref(Ed))]),_:1})]),_:1})]),c.createElementVNode("div",Stt,[n.shortcutData.length?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.shortcutData,z=>(c.openBlock(),c.createBlock($,{key:z.id,type:"primary",size:"default",closable:"",onClick:ne=>C(z),onClose:ne=>y(z)},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(z.shortcutName),1)]),_:2},1032,["onClick","onClose"]))),128)):(c.openBlock(),c.createElementBlock("span",Dtt,"暂无数据"))]),c.createElementVNode("div",Ntt,[Ett,c.createVNode(F,{effect:"dark",content:"同名配置将会进行覆盖",placement:"right-start"},{default:c.withCtx(()=>[c.createVNode(O,null,{default:c.withCtx(()=>[c.createVNode(c.unref(Ed))]),_:1})]),_:1})]),c.createVNode(R,{ref_key:"shortcut_ruleFormRef",ref:d,model:h.value,rules:f.value,"label-width":"90px",size:"default"},{default:c.withCtx(()=>[c.createVNode(N,{label:"配置名称:",prop:"shortcutName"},{default:c.withCtx(()=>[c.createVNode(A,{modelValue:h.value.shortcutName,"onUpdate:modelValue":w[9]||(w[9]=z=>h.value.shortcutName=z),maxlength:"6","show-word-limit":"",style:{width:"160px"}},null,8,["modelValue"])]),_:1}),c.createVNode(N,{label:"交易类型:",prop:"factorType"},{default:c.withCtx(()=>[c.createVNode(S,{type:"danger",plain:h.value.factorType!==1,onClick:w[10]||(w[10]=()=>{h.value.factorType===-1&&(h.value.factorSelectedList=[]),h.value.factorType=1})},{default:c.withCtx(()=>[c.createTextVNode(" 多 ")]),_:1},8,["plain"]),c.createVNode(S,{type:"success",plain:h.value.factorType!==-1,onClick:w[11]||(w[11]=()=>{h.value.factorType===1&&(h.value.factorSelectedList=[]),h.value.factorType=-1})},{default:c.withCtx(()=>[c.createTextVNode(" 空 ")]),_:1},8,["plain"])]),_:1}),c.createVNode(N,{label:"预警因子:",prop:"factorSelectedList"},{default:c.withCtx(()=>[c.createVNode(L,{modelValue:h.value.factorSelectedList,"onUpdate:modelValue":w[12]||(w[12]=z=>h.value.factorSelectedList=z)},{default:c.withCtx(()=>[h.value.factorType===1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(n.moreFactorOptions,(z,ne)=>(c.openBlock(),c.createBlock(D,{key:ne,label:z.factorTypeName,value:z.factorTypeName,style:{width:"200px"}},null,8,["label","value"]))),128)):c.createCommentVNode("",!0),h.value.factorType===-1?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:1},c.renderList(n.emptyFactorOptions,(z,ne)=>(c.openBlock(),c.createBlock(D,{key:ne,label:z.factorTypeName,value:z.factorTypeName,style:{width:"200px"}},null,8,["label","value"]))),128)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1}),c.createVNode(N,{label:"预警次数:",prop:"totalCount"},{default:c.withCtx(()=>[c.createVNode(E,{modelValue:h.value.totalCount,"onUpdate:modelValue":w[13]||(w[13]=z=>h.value.totalCount=z),min:1,max:10,"controls-position":"right",style:{"margin-right":"20px"}},null,8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])],64)):c.createCommentVNode("",!0)]),_:1},8,["modelValue"])]),_:1},8,["locale"])])}}},[["__scopeId","data-v-b2d15520"]]),Mtt={install(n){n.component("st-factorWarning",Ltt)}},Ttt=c.defineComponent({__name:"index",props:{data:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})}},setup(n,{expose:e}){const t={tooltipFormatter:null,dataZoom:null,grid:{left:"60px",bottom:"20px",right:"0",top:0}};let i,r;const o=n,s=c.ref(),a=c.computed(()=>({...t,...o.config}));c.watch(()=>[o.data],()=>{l()},{deep:!0}),c.onMounted(()=>{i=qr.init(s.value),l();let u=!0;r=new ResizeObserver(()=>{if(u){u=null;return}i.resize()}),r.observe(s.value)}),c.onUnmounted(()=>{i.dispose(),r.disconnect(),r=null});const l=()=>{i.setOption({tooltip:{confine:!0,formatter:a.value.tooltipFormatter?u=>a.value.tooltipFormatter(u,o.data):null},grid:a.value.grid,xAxis:{type:"category",data:o.data.date},yAxis:{type:"category",inverse:!0,data:o.data.data.map(u=>u.name)},visualMap:{type:"piecewise",show:!1,inRange:[]},dataZoom:a.value.dataZoom,series:[{name:"热力图",type:"heatmap",info:o.data,data:o.data.data.reduce((u,d,h)=>[...u,...d.data.reduce((f,p,g)=>p===null?f:[...f,{value:[g,h,p.value],itemStyle:{color:p.color}}],[])],[]),label:{show:!1}}]})};return e({reset:()=>{l()}}),(u,d)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"chartRef",ref:s,class:"chart"},null,512))}}),bMt="",Att=vn(Ttt,[["__scopeId","data-v-4c74604d"]]),Itt={install(n){n.component("st-heatMap",Att)}},_Mt="",yMt="",Rtt={class:"st-kline-tips"},Ott={class:"st-kline-tips-row"},Ftt=c.defineComponent({__name:"index",props:{data:{type:Array,default:()=>[]}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",Rtt,[c.createElementVNode("div",Ott,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,i=>(c.openBlock(),c.createElementBlock("div",{class:"st-kline-tips-row-item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),256))])]))}}),vMt="",ZE=vn(Ftt,[["__scopeId","data-v-78aed210"]]),Ptt=c.defineComponent({__name:"index",emits:["closeContextMenuCallBack"],setup(n,{emit:e}){const t=e,i=c.ref(),r=c.ref(),o=c.ref({display:"none",top:"0px",left:"0px"}),s=()=>{o.value.display="none",t("closeContextMenuCallBack"),document.removeEventListener("click",s)},a=l=>{if(l.preventDefault(),l.stopPropagation(),o.value.display==="block"){const{offsetX:u,offsetY:d}=l,{offsetWidth:h,offsetHeight:f}=r.value;if(u<=h&&d<=f)return}i.value.click(),o.value={display:"block",top:`${l.offsetY}px`,left:`${l.offsetX}px`},c.nextTick(()=>{const{bottom:u,height:d,right:h,width:f}=r.value.getBoundingClientRect();u>window.innerHeight?o.value={display:"block",top:`${l.offsetY-d}px`,left:`${l.offsetX}px`}:h>window.innerWidth&&(o.value={display:"block",top:`${l.offsetY}px`,left:`${l.offsetX-f}px`})}),document.addEventListener("click",s)};return(l,u)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"contextmenuRef",ref:i,class:"contextmenu",onContextmenu:a,onMouseleave:s},[c.renderSlot(l.$slots,"default",{},void 0,!0),o.value.display!=="none"?(c.openBlock(),c.createElementBlock("div",{key:0,ref_key:"contextmenuContentRef",ref:r,class:"contextmenu-popover",style:c.normalizeStyle(o.value)},[c.renderSlot(l.$slots,"popover",{},void 0,!0)],4)):c.createCommentVNode("",!0)],544))}}),CMt="",Btt=vn(Ptt,[["__scopeId","data-v-249fd104"]]);var XE=function(){var n=typeof document<"u"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename<"u"&&(n=n||__filename),function(e){e=e||{};var t=typeof e<"u"?e:{},i,r;t.ready=new Promise(function(Ee,Te){i=Ee,r=Te});var o={},s;for(s in t)t.hasOwnProperty(s)&&(o[s]=t[s]);var a=function(Ee,Te){throw Te},l=!1,u=!1,d=!1,h=!1;l=typeof window=="object",u=typeof importScripts=="function",d=typeof process=="object"&&typeof process.versions=="object"&&typeof process.versions.node=="string",h=!l&&!d&&!u;var f="";function p(Ee){return t.locateFile?t.locateFile(Ee,f):f+Ee}var g,m,_,b;d?(u?f=require("path").dirname(f)+"/":f=__dirname+"/",g=function(Te,Ue){return _||(_=require("fs")),b||(b=require("path")),Te=b.normalize(Te),_.readFileSync(Te,Ue?null:"utf8")},m=function(Te){var Ue=g(Te,!0);return Ue.buffer||(Ue=new Uint8Array(Ue)),R(Ue.buffer),Ue},process.argv.length>1&&process.argv[1].replace(/\\/g,"/"),process.argv.slice(2),process.on("uncaughtException",function(Ee){if(!(Ee instanceof Ne))throw Ee}),process.on("unhandledRejection",fe),a=function(Ee){process.exit(Ee)},t.inspect=function(){return"[Emscripten Module object]"}):h?(typeof read<"u"&&(g=function(Te){return read(Te)}),m=function(Te){var Ue;return typeof readbuffer=="function"?new Uint8Array(readbuffer(Te)):(Ue=read(Te,"binary"),R(typeof Ue=="object"),Ue)},typeof scriptArgs<"u"&&scriptArgs,typeof quit=="function"&&(a=function(Ee){quit(Ee)}),typeof print<"u"&&(typeof console>"u"&&(console={}),console.log=print,console.warn=console.error=typeof printErr<"u"?printErr:print)):(l||u)&&(u?f=self.location.href:document.currentScript&&(f=document.currentScript.src),n&&(f=n),f.indexOf("blob:")!==0?f=f.substr(0,f.lastIndexOf("/")+1):f="",g=function(Te){var Ue=new XMLHttpRequest;return Ue.open("GET",Te,!1),Ue.send(null),Ue.responseText},u&&(m=function(Te){var Ue=new XMLHttpRequest;return Ue.open("GET",Te,!1),Ue.responseType="arraybuffer",Ue.send(null),new Uint8Array(Ue.response)})),t.print||console.log.bind(console);var C=t.printErr||console.warn.bind(console);for(s in o)o.hasOwnProperty(s)&&(t[s]=o[s]);o=null,t.arguments&&t.arguments,t.thisProgram&&t.thisProgram,t.quit&&(a=t.quit);var y=16;function v(Ee,Te){return Te||(Te=y),Math.ceil(Ee/Te)*Te}function w(Ee,Te){if(typeof WebAssembly.Function=="function"){for(var Ue={i:"i32",j:"i64",f:"f32",d:"f64"},tt={parameters:[],results:Te[0]=="v"?[]:[Ue[Te[0]]]},Ut=1;Ut<Te.length;++Ut)tt.parameters.push(Ue[Te[Ut]]);return new WebAssembly.Function(tt,Ee)}var Zt=[1,0,1,96],Lt=Te.slice(0,1),zt=Te.slice(1),nr={i:127,j:126,f:125,d:124};Zt.push(zt.length);for(var Ut=0;Ut<zt.length;++Ut)Zt.push(nr[zt[Ut]]);Lt=="v"?Zt.push(0):Zt=Zt.concat([1,nr[Lt]]),Zt[1]=Zt.length-2;var mi=new Uint8Array([0,97,115,109,1,0,0,0].concat(Zt,[2,7,1,1,101,1,102,0,0,7,5,1,1,102,0,0])),lr=new WebAssembly.Module(mi),e1=new WebAssembly.Instance(lr,{e:{f:Ee}}),t3=e1.exports.f;return t3}var x=[],S;function N(Ee,Te){var Ue=ve;if(!S){S=new WeakMap;for(var tt=0;tt<Ue.length;tt++){var Ut=Ue.get(tt);Ut&&S.set(Ut,tt)}}if(S.has(Ee))return S.get(Ee);var Zt;if(x.length)Zt=x.pop();else{Zt=Ue.length;try{Ue.grow(1)}catch(zt){throw zt instanceof RangeError?"Unable to grow wasm table. Set ALLOW_TABLE_GROWTH.":zt}}try{Ue.set(Zt,Ee)}catch(zt){if(!(zt instanceof TypeError))throw zt;var Lt=w(Ee,Te);Ue.set(Zt,Lt)}return S.set(Ee,Zt),Zt}function D(Ee,Te){return N(Ee,Te)}var L;t.wasmBinary&&(L=t.wasmBinary);var E;t.noExitRuntime&&(E=t.noExitRuntime),typeof WebAssembly!="object"&&fe("no native wasm support detected");var k,ve,A=!1;function R(Ee,Te){Ee||fe("Assertion failed: "+Te)}function B(Ee){var Te=t["_"+Ee];return R(Te,"Cannot call unknown function "+Ee+", make sure it is exported"),Te}function I(Ee,Te,Ue,tt,Ut){var Zt={string:function(ya){var Sd=0;if(ya!=null&&ya!==0){var va=(ya.length<<2)+1;Sd=Fe(va),z(ya,Sd,va)}return Sd},array:function(ya){var Sd=Fe(ya.length);return ne(ya,Sd),Sd}};function Lt(ya){return Te==="string"?Y(ya):Te==="boolean"?!!ya:ya}var zt=B(Ee),nr=[],mi=0;if(tt)for(var lr=0;lr<tt.length;lr++){var e1=Zt[Ue[lr]];e1?(mi===0&&(mi=Jc()),nr[lr]=e1(tt[lr])):nr[lr]=tt[lr]}var t3=zt.apply(null,nr);return t3=Lt(t3),mi!==0&&Qa(mi),t3}var M=1;function O(Ee,Te){var Ue;return Te==M?Ue=Fe(Ee.length):Ue=qo(Ee.length),Ee.subarray||Ee.slice?oe.set(Ee,Ue):oe.set(new Uint8Array(Ee),Ue),Ue}var F=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0;function $(Ee,Te,Ue){for(var tt=Te+Ue,Ut=Te;Ee[Ut]&&!(Ut>=tt);)++Ut;if(Ut-Te>16&&Ee.subarray&&F)return F.decode(Ee.subarray(Te,Ut));for(var Zt="";Te<Ut;){var Lt=Ee[Te++];if(!(Lt&128)){Zt+=String.fromCharCode(Lt);continue}var zt=Ee[Te++]&63;if((Lt&224)==192){Zt+=String.fromCharCode((Lt&31)<<6|zt);continue}var nr=Ee[Te++]&63;if((Lt&240)==224?Lt=(Lt&15)<<12|zt<<6|nr:Lt=(Lt&7)<<18|zt<<12|nr<<6|Ee[Te++]&63,Lt<65536)Zt+=String.fromCharCode(Lt);else{var mi=Lt-65536;Zt+=String.fromCharCode(55296|mi>>10,56320|mi&1023)}}return Zt}function Y(Ee,Te){return Ee?$(oe,Ee,Te):""}function U(Ee,Te,Ue,tt){if(!(tt>0))return 0;for(var Ut=Ue,Zt=Ue+tt-1,Lt=0;Lt<Ee.length;++Lt){var zt=Ee.charCodeAt(Lt);if(zt>=55296&&zt<=57343){var nr=Ee.charCodeAt(++Lt);zt=65536+((zt&1023)<<10)|nr&1023}if(zt<=127){if(Ue>=Zt)break;Te[Ue++]=zt}else if(zt<=2047){if(Ue+1>=Zt)break;Te[Ue++]=192|zt>>6,Te[Ue++]=128|zt&63}else if(zt<=65535){if(Ue+2>=Zt)break;Te[Ue++]=224|zt>>12,Te[Ue++]=128|zt>>6&63,Te[Ue++]=128|zt&63}else{if(Ue+3>=Zt)break;Te[Ue++]=240|zt>>18,Te[Ue++]=128|zt>>12&63,Te[Ue++]=128|zt>>6&63,Te[Ue++]=128|zt&63}}return Te[Ue]=0,Ue-Ut}function z(Ee,Te,Ue){return U(Ee,oe,Te,Ue)}function ne(Ee,Te){X.set(Ee,Te)}var le=65536,ue,X,oe;function de(Ee){ue=Ee,t.HEAP8=X=new Int8Array(Ee),t.HEAP16=new Int16Array(Ee),t.HEAP32=new Int32Array(Ee),t.HEAPU8=oe=new Uint8Array(Ee),t.HEAPU16=new Uint16Array(Ee),t.HEAPU32=new Uint32Array(Ee),t.HEAPF32=new Float32Array(Ee),t.HEAPF64=new Float64Array(Ee)}var pe=5247776;t.___heap_base=5247776;var he=t.INITIAL_MEMORY||16777216;t.wasmMemory?k=t.wasmMemory:k=new WebAssembly.Memory({initial:he/le,maximum:he/le}),k&&(ue=k.buffer),he=ue.byteLength,de(ue);var ve=new WebAssembly.Table({initial:1,element:"anyfunc"}),Le=[],re=[],W=[],ee=[],te=!1;function J(){if(t.preRun)for(typeof t.preRun=="function"&&(t.preRun=[t.preRun]);t.preRun.length;)Z(t.preRun.shift());be(Le)}function ie(){te=!0,be(re)}function G(){be(W)}function Q(){if(t.postRun)for(typeof t.postRun=="function"&&(t.postRun=[t.postRun]);t.postRun.length;)P(t.postRun.shift());be(ee)}function Z(Ee){Le.unshift(Ee)}function P(Ee){ee.unshift(Ee)}var V=0,q=null;function K(Ee){V++,t.monitorRunDependencies&&t.monitorRunDependencies(V)}function ae(Ee){if(V--,t.monitorRunDependencies&&t.monitorRunDependencies(V),V==0&&q){var Te=q;q=null,Te()}}t.preloadedImages={},t.preloadedAudios={},t.preloadedWasm={},Z(Fl);function fe(Ee){t.onAbort&&t.onAbort(Ee),Ee+="",C(Ee),A=!0,Ee="abort("+Ee+"). Build with -s ASSERTIONS=1 for more info.";var Te=new WebAssembly.RuntimeError(Ee);throw r(Te),Te}function we(Ee,Te){return String.prototype.startsWith?Ee.startsWith(Te):Ee.indexOf(Te)===0}var _e="data:application/octet-stream;base64,";function xe(Ee){return we(Ee,_e)}var Se="file://";function $e(Ee){return we(Ee,Se)}var Ve="talib.wasm";xe(Ve)||(Ve=p(Ve));function Ie(){try{if(L)return new Uint8Array(L);if(m)return m(Ve);throw"both async and sync fetching of the wasm failed"}catch(Ee){fe(Ee)}}function rt(){return!L&&(l||u)&&typeof fetch=="function"&&!$e(Ve)?fetch(Ve,{credentials:"same-origin"}).then(function(Ee){if(!Ee.ok)throw"failed to load wasm binary file at '"+Ve+"'";return Ee.arrayBuffer()}).catch(function(){return Ie()}):Promise.resolve().then(Ie)}function H(){var Ee={env:xd,wasi_snapshot_preview1:xd};function Te(Lt,zt){var nr=Lt.exports;nr=Uo(nr,1024),t.asm=nr,ae()}K();function Ue(Lt){Te(Lt.instance)}function tt(Lt){return rt().then(function(zt){return WebAssembly.instantiate(zt,Ee)}).then(Lt,function(zt){C("failed to asynchronously prepare wasm: "+zt),fe(zt)})}function Ut(){if(!L&&typeof WebAssembly.instantiateStreaming=="function"&&!xe(Ve)&&!$e(Ve)&&typeof fetch=="function")fetch(Ve,{credentials:"same-origin"}).then(function(Lt){var zt=WebAssembly.instantiateStreaming(Lt,Ee);return zt.then(Ue,function(nr){return C("wasm streaming compile failed: "+nr),C("falling back to ArrayBuffer instantiation"),tt(Ue)})});else return tt(Ue)}if(t.instantiateWasm)try{var Zt=t.instantiateWasm(Ee,Te);return Zt}catch(Lt){return C("Module.instantiateWasm callback failed with error: "+Lt),!1}return Ut(),{}}function be(Ee){for(;Ee.length>0;){var Te=Ee.shift();if(typeof Te=="function"){Te(t);continue}var Ue=Te.func;typeof Ue=="number"?Te.arg===void 0?ve.get(Ue)():ve.get(Ue)(Te.arg):Ue(Te.arg===void 0?null:Te.arg)}}function De(Ee,Te,Ue){return Ue&&Ue.length?t["dynCall_"+Ee].apply(null,[Te].concat(Ue)):t["dynCall_"+Ee].call(null,Te)}function je(Ee,Te,Ue){return Ee.indexOf("j")!=-1?De(Ee,Te,Ue):ve.get(Te).apply(null,Ue)}var lt={nextHandle:1,loadedLibs:{},loadedLibNames:{}};function Dt(Ee){return function(){var Te=Jc();try{return je(Ee,arguments[0],Array.prototype.slice.call(arguments,1))}catch(Ue){if(Qa(Te),Ue!==Ue+0&&Ue!=="longjmp")throw Ue;_setThrew(1,0)}}}function Ni(Ee){if(te)return qo(Ee);var Te=t.___heap_base,Ue=Te+Ee+15&-16;return t.___heap_base=Ue,Te}function Uo(Ee,Te,Ue){var tt={};for(var Ut in Ee){var Zt=Ee[Ut];typeof Zt=="object"&&(Zt=Zt.value),typeof Zt=="number"&&(Zt+=Te),tt[Ut]=Zt,Ue&&(Ue["_"+Ut]=Zt)}return tt}function _a(Ee){var Te=["setTempRet0","getTempRet0","stackAlloc","stackSave","stackRestore"];return Ee.indexOf("dynCall_")==0||Te.indexOf(Ee)!=-1?Ee:"_"+Ee}function Ga(Ee,Te){var Ue=new Uint32Array(new Uint8Array(Ee.subarray(0,24)).buffer);R(Ue[0]==1836278016,"need to see wasm magic number"),R(Ee[8]===0,"need the dylink section to be first");var tt=9;function Ut(){for(var va=0,yg=1;;){var Sh=Ee[tt++];if(va+=(Sh&127)*yg,yg*=128,!(Sh&128))break}return va}Ut(),R(Ee[tt]===6),tt++,R(Ee[tt]==="d".charCodeAt(0)),tt++,R(Ee[tt]==="y".charCodeAt(0)),tt++,R(Ee[tt]==="l".charCodeAt(0)),tt++,R(Ee[tt]==="i".charCodeAt(0)),tt++,R(Ee[tt]==="n".charCodeAt(0)),tt++,R(Ee[tt]==="k".charCodeAt(0)),tt++;var Zt=Ut(),Lt=Ut(),zt=Ut();Ut();for(var nr=Ut(),mi=[],lr=0;lr<nr;++lr){var e1=Ut(),t3=Ee.subarray(tt,tt+e1);tt+=e1;var ya=$(t3,0);mi.push(ya)}function Sd(){Lt=Math.pow(2,Lt),Lt=Math.max(Lt,y);var va=v(Ni(Zt+Lt),Lt),yg=xd,Sh=ve,KO=Sh.length,nLt=Sh;Sh.grow(zt),R(Sh===nLt);for(var n3=va;n3<va+Zt;n3++)X[n3]=0;for(var n3=KO;n3<KO+zt;n3++)Sh.set(n3,null);var GO={},YO=function(_s,Ca,Dh){Dh&&(_s="orig$"+_s);var Gs=t.asm[_s];if(!Gs){var K8=_a(_s);Gs=t[K8],Gs||(Gs=GO[K8]),!Gs&&_s.startsWith("invoke_")&&(Gs=Dt(_s.split("_")[1]))}return Gs};for(var QO in t)QO in yg||(yg[QO]=t[QO]);var iLt={get:function(_s,Ca){switch(Ca){case"__memory_base":return va;case"__table_base":return KO}if(Ca in _s)return _s[Ca];if(Ca.startsWith("g$")){var Dh=Ca.substr(2);return _s[Ca]=function(){return YO(Dh)}}if(Ca.startsWith("fp$")){var Gs=Ca.split("$");R(Gs.length==3);var Dh=Gs[1],K8=Gs[2],oLt=K8.indexOf("j")>=0,ZO=0;return _s[Ca]=function(){if(!ZO){var sLt=YO(Dh,"function",oLt);ZO=D(sLt,K8)}return ZO}}return _s[Ca]=function(){return YO(Ca).apply(null,arguments)}}},h0e=new Proxy(yg,iLt),f0e={global:{NaN:NaN,Infinity:1/0},"global.Math":Math,env:h0e,wasi_snapshot_preview1:h0e};function p0e(_s,Ca){var Dh=Uo(_s.exports,va,Ca),Gs=Dh.__post_instantiate;return Gs&&(te?Gs():re.push(Gs)),Dh}if(Te.loadAsync)return WebAssembly.instantiate(Ee,f0e).then(function(_s){return p0e(_s.instance,GO)});var rLt=new WebAssembly.Instance(new WebAssembly.Module(Ee),f0e);return p0e(rLt,GO)}return Te.loadAsync?Promise.all(mi.map(function(va){return ms(va,Te)})).then(function(){return Sd()}):(mi.forEach(function(va){ms(va,Te)}),Sd())}function Ya(Ee){return fetch(Ee,{credentials:"same-origin"}).then(function(Te){if(!Te.ok)throw"failed to load binary file at '"+Ee+"'";return Te.arrayBuffer()}).then(function(Te){return new Uint8Array(Te)})}function ms(Ee,Te){Ee=="__self__"&&!lt.loadedLibNames[Ee]&&(lt.loadedLibs[-1]={refcount:1/0,name:"__self__",module:t.asm,global:!0},lt.loadedLibNames.__self__=-1),Te=Te||{global:!0,nodelete:!0};var Ue=lt.loadedLibNames[Ee],tt;if(Ue)return tt=lt.loadedLibs[Ue],Te.global&&!tt.global&&(tt.global=!0,tt.module!=="loading"&&zt(tt.module)),Te.nodelete&&tt.refcount!==1/0&&(tt.refcount=1/0),tt.refcount++,Te.loadAsync?Promise.resolve(Ue):Ue;Ue=lt.nextHandle++,tt={refcount:Te.nodelete?1/0:1,name:Ee,module:"loading",global:Te.global},lt.loadedLibNames[Ee]=Ue,lt.loadedLibs[Ue]=tt;function Ut(mi){if(Te.fs){var lr=Te.fs.readFile(mi,{encoding:"binary"});return lr instanceof Uint8Array||(lr=new Uint8Array(lib_data)),Te.loadAsync?Promise.resolve(lr):lr}return Te.loadAsync?Ya(mi):m(mi)}function Zt(mi){return Ga(mi,Te)}function Lt(){if(t.preloadedWasm!==void 0&&t.preloadedWasm[Ee]!==void 0){var mi=t.preloadedWasm[Ee];return Te.loadAsync?Promise.resolve(mi):mi}return Te.loadAsync?Ut(Ee).then(function(lr){return Zt(lr)}):Zt(Ut(Ee))}function zt(mi){for(var lr in mi)if(mi.hasOwnProperty(lr)){var e1=_a(lr);t.hasOwnProperty(e1)||(t[e1]=mi[lr])}}function nr(mi){tt.global&&zt(mi),tt.module=mi}return Te.loadAsync?Lt().then(function(mi){return nr(mi),Ue}):(nr(Lt()),Ue)}function Fl(){var Ee=[];if(t.dynamicLibraries&&(Ee=Ee.concat(t.dynamicLibraries)),!!Ee.length){if(!m){K(),Promise.all(Ee.map(function(Te){return ms(Te,{loadAsync:!0,global:!0,nodelete:!0})})).then(function(){ae()});return}Ee.forEach(function(Te){ms(Te,{global:!0,nodelete:!0})})}}function bs(Ee,Te,Ue){oe.copyWithin(Ee,Te,Te+Ue)}function $u(Ee){fe("OOM")}function Uu(Ee){$u()}function qu(){return t.___heap_base}re.push({func:function(){ot()}},{func:function(){Ku()}});var xd={__indirect_function_table:ve,__memory_base:1024,__stack_pointer:pe,__table_base:1,emscripten_memcpy_big:bs,emscripten_resize_heap:Uu,g$__heap_base:qu,memory:k};H();var Ku=t.___wasm_call_ctors=function(){return(Ku=t.___wasm_call_ctors=t.asm.__wasm_call_ctors).apply(null,arguments)};t._TA_ACCBANDS=function(){return(t._TA_ACCBANDS=t.asm.TA_ACCBANDS).apply(null,arguments)};var qo=t._malloc=function(){return(qo=t._malloc=t.asm.malloc).apply(null,arguments)};t._free=function(){return(t._free=t.asm.free).apply(null,arguments)},t._TA_SMA=function(){return(t._TA_SMA=t.asm.TA_SMA).apply(null,arguments)},t._TA_ACOS=function(){return(t._TA_ACOS=t.asm.TA_ACOS).apply(null,arguments)},t._TA_AD=function(){return(t._TA_AD=t.asm.TA_AD).apply(null,arguments)},t._TA_ADD=function(){return(t._TA_ADD=t.asm.TA_ADD).apply(null,arguments)},t._TA_ADOSC=function(){return(t._TA_ADOSC=t.asm.TA_ADOSC).apply(null,arguments)},t._TA_ADX=function(){return(t._TA_ADX=t.asm.TA_ADX).apply(null,arguments)},t._TA_ADXR=function(){return(t._TA_ADXR=t.asm.TA_ADXR).apply(null,arguments)},t._TA_APO=function(){return(t._TA_APO=t.asm.TA_APO).apply(null,arguments)},t._TA_MA=function(){return(t._TA_MA=t.asm.TA_MA).apply(null,arguments)},t._TA_AROON=function(){return(t._TA_AROON=t.asm.TA_AROON).apply(null,arguments)},t._TA_AROONOSC=function(){return(t._TA_AROONOSC=t.asm.TA_AROONOSC).apply(null,arguments)},t._TA_ASIN=function(){return(t._TA_ASIN=t.asm.TA_ASIN).apply(null,arguments)},t._TA_ATAN=function(){return(t._TA_ATAN=t.asm.TA_ATAN).apply(null,arguments)},t._TA_ATR=function(){return(t._TA_ATR=t.asm.TA_ATR).apply(null,arguments)},t._TA_TRANGE=function(){return(t._TA_TRANGE=t.asm.TA_TRANGE).apply(null,arguments)},t._TA_AVGDEV=function(){return(t._TA_AVGDEV=t.asm.TA_AVGDEV).apply(null,arguments)},t._TA_AVGPRICE=function(){return(t._TA_AVGPRICE=t.asm.TA_AVGPRICE).apply(null,arguments)},t._TA_BBANDS=function(){return(t._TA_BBANDS=t.asm.TA_BBANDS).apply(null,arguments)},t._TA_STDDEV=function(){return(t._TA_STDDEV=t.asm.TA_STDDEV).apply(null,arguments)},t._TA_BETA=function(){return(t._TA_BETA=t.asm.TA_BETA).apply(null,arguments)},t._TA_BOP=function(){return(t._TA_BOP=t.asm.TA_BOP).apply(null,arguments)},t._TA_CCI=function(){return(t._TA_CCI=t.asm.TA_CCI).apply(null,arguments)},t._TA_CDL2CROWS=function(){return(t._TA_CDL2CROWS=t.asm.TA_CDL2CROWS).apply(null,arguments)},t._TA_CDL3BLACKCROWS=function(){return(t._TA_CDL3BLACKCROWS=t.asm.TA_CDL3BLACKCROWS).apply(null,arguments)},t._TA_CDL3INSIDE=function(){return(t._TA_CDL3INSIDE=t.asm.TA_CDL3INSIDE).apply(null,arguments)},t._TA_CDL3LINESTRIKE=function(){return(t._TA_CDL3LINESTRIKE=t.asm.TA_CDL3LINESTRIKE).apply(null,arguments)},t._TA_CDL3OUTSIDE=function(){return(t._TA_CDL3OUTSIDE=t.asm.TA_CDL3OUTSIDE).apply(null,arguments)},t._TA_CDL3STARSINSOUTH=function(){return(t._TA_CDL3STARSINSOUTH=t.asm.TA_CDL3STARSINSOUTH).apply(null,arguments)},t._TA_CDL3WHITESOLDIERS=function(){return(t._TA_CDL3WHITESOLDIERS=t.asm.TA_CDL3WHITESOLDIERS).apply(null,arguments)},t._TA_CDLABANDONEDBABY=function(){return(t._TA_CDLABANDONEDBABY=t.asm.TA_CDLABANDONEDBABY).apply(null,arguments)},t._TA_CDLADVANCEBLOCK=function(){return(t._TA_CDLADVANCEBLOCK=t.asm.TA_CDLADVANCEBLOCK).apply(null,arguments)},t._TA_CDLBELTHOLD=function(){return(t._TA_CDLBELTHOLD=t.asm.TA_CDLBELTHOLD).apply(null,arguments)},t._TA_CDLBREAKAWAY=function(){return(t._TA_CDLBREAKAWAY=t.asm.TA_CDLBREAKAWAY).apply(null,arguments)},t._TA_CDLCLOSINGMARUBOZU=function(){return(t._TA_CDLCLOSINGMARUBOZU=t.asm.TA_CDLCLOSINGMARUBOZU).apply(null,arguments)},t._TA_CDLCONCEALBABYSWALL=function(){return(t._TA_CDLCONCEALBABYSWALL=t.asm.TA_CDLCONCEALBABYSWALL).apply(null,arguments)},t._TA_CDLCOUNTERATTACK=function(){return(t._TA_CDLCOUNTERATTACK=t.asm.TA_CDLCOUNTERATTACK).apply(null,arguments)},t._TA_CDLDARKCLOUDCOVER=function(){return(t._TA_CDLDARKCLOUDCOVER=t.asm.TA_CDLDARKCLOUDCOVER).apply(null,arguments)},t._TA_CDLDOJI=function(){return(t._TA_CDLDOJI=t.asm.TA_CDLDOJI).apply(null,arguments)},t._TA_CDLDOJISTAR=function(){return(t._TA_CDLDOJISTAR=t.asm.TA_CDLDOJISTAR).apply(null,arguments)},t._TA_CDLDRAGONFLYDOJI=function(){return(t._TA_CDLDRAGONFLYDOJI=t.asm.TA_CDLDRAGONFLYDOJI).apply(null,arguments)},t._TA_CDLENGULFING=function(){return(t._TA_CDLENGULFING=t.asm.TA_CDLENGULFING).apply(null,arguments)},t._TA_CDLEVENINGDOJISTAR=function(){return(t._TA_CDLEVENINGDOJISTAR=t.asm.TA_CDLEVENINGDOJISTAR).apply(null,arguments)},t._TA_CDLEVENINGSTAR=function(){return(t._TA_CDLEVENINGSTAR=t.asm.TA_CDLEVENINGSTAR).apply(null,arguments)},t._TA_CDLGAPSIDESIDEWHITE=function(){return(t._TA_CDLGAPSIDESIDEWHITE=t.asm.TA_CDLGAPSIDESIDEWHITE).apply(null,arguments)},t._TA_CDLGRAVESTONEDOJI=function(){return(t._TA_CDLGRAVESTONEDOJI=t.asm.TA_CDLGRAVESTONEDOJI).apply(null,arguments)},t._TA_CDLHAMMER=function(){return(t._TA_CDLHAMMER=t.asm.TA_CDLHAMMER).apply(null,arguments)},t._TA_CDLHANGINGMAN=function(){return(t._TA_CDLHANGINGMAN=t.asm.TA_CDLHANGINGMAN).apply(null,arguments)},t._TA_CDLHARAMI=function(){return(t._TA_CDLHARAMI=t.asm.TA_CDLHARAMI).apply(null,arguments)},t._TA_CDLHARAMICROSS=function(){return(t._TA_CDLHARAMICROSS=t.asm.TA_CDLHARAMICROSS).apply(null,arguments)},t._TA_CDLHIGHWAVE=function(){return(t._TA_CDLHIGHWAVE=t.asm.TA_CDLHIGHWAVE).apply(null,arguments)},t._TA_CDLHIKKAKE=function(){return(t._TA_CDLHIKKAKE=t.asm.TA_CDLHIKKAKE).apply(null,arguments)},t._TA_CDLHIKKAKEMOD=function(){return(t._TA_CDLHIKKAKEMOD=t.asm.TA_CDLHIKKAKEMOD).apply(null,arguments)},t._TA_CDLHOMINGPIGEON=function(){return(t._TA_CDLHOMINGPIGEON=t.asm.TA_CDLHOMINGPIGEON).apply(null,arguments)},t._TA_CDLIDENTICAL3CROWS=function(){return(t._TA_CDLIDENTICAL3CROWS=t.asm.TA_CDLIDENTICAL3CROWS).apply(null,arguments)},t._TA_CDLINNECK=function(){return(t._TA_CDLINNECK=t.asm.TA_CDLINNECK).apply(null,arguments)},t._TA_CDLINVERTEDHAMMER=function(){return(t._TA_CDLINVERTEDHAMMER=t.asm.TA_CDLINVERTEDHAMMER).apply(null,arguments)},t._TA_CDLKICKING=function(){return(t._TA_CDLKICKING=t.asm.TA_CDLKICKING).apply(null,arguments)},t._TA_CDLKICKINGBYLENGTH=function(){return(t._TA_CDLKICKINGBYLENGTH=t.asm.TA_CDLKICKINGBYLENGTH).apply(null,arguments)},t._TA_CDLLADDERBOTTOM=function(){return(t._TA_CDLLADDERBOTTOM=t.asm.TA_CDLLADDERBOTTOM).apply(null,arguments)},t._TA_CDLLONGLEGGEDDOJI=function(){return(t._TA_CDLLONGLEGGEDDOJI=t.asm.TA_CDLLONGLEGGEDDOJI).apply(null,arguments)},t._TA_CDLLONGLINE=function(){return(t._TA_CDLLONGLINE=t.asm.TA_CDLLONGLINE).apply(null,arguments)},t._TA_CDLMARUBOZU=function(){return(t._TA_CDLMARUBOZU=t.asm.TA_CDLMARUBOZU).apply(null,arguments)},t._TA_CDLMATCHINGLOW=function(){return(t._TA_CDLMATCHINGLOW=t.asm.TA_CDLMATCHINGLOW).apply(null,arguments)},t._TA_CDLMATHOLD=function(){return(t._TA_CDLMATHOLD=t.asm.TA_CDLMATHOLD).apply(null,arguments)},t._TA_CDLMORNINGDOJISTAR=function(){return(t._TA_CDLMORNINGDOJISTAR=t.asm.TA_CDLMORNINGDOJISTAR).apply(null,arguments)},t._TA_CDLMORNINGSTAR=function(){return(t._TA_CDLMORNINGSTAR=t.asm.TA_CDLMORNINGSTAR).apply(null,arguments)},t._TA_CDLONNECK=function(){return(t._TA_CDLONNECK=t.asm.TA_CDLONNECK).apply(null,arguments)},t._TA_CDLPIERCING=function(){return(t._TA_CDLPIERCING=t.asm.TA_CDLPIERCING).apply(null,arguments)},t._TA_CDLRICKSHAWMAN=function(){return(t._TA_CDLRICKSHAWMAN=t.asm.TA_CDLRICKSHAWMAN).apply(null,arguments)},t._TA_CDLRISEFALL3METHODS=function(){return(t._TA_CDLRISEFALL3METHODS=t.asm.TA_CDLRISEFALL3METHODS).apply(null,arguments)},t._TA_CDLSEPARATINGLINES=function(){return(t._TA_CDLSEPARATINGLINES=t.asm.TA_CDLSEPARATINGLINES).apply(null,arguments)},t._TA_CDLSHOOTINGSTAR=function(){return(t._TA_CDLSHOOTINGSTAR=t.asm.TA_CDLSHOOTINGSTAR).apply(null,arguments)},t._TA_CDLSHORTLINE=function(){return(t._TA_CDLSHORTLINE=t.asm.TA_CDLSHORTLINE).apply(null,arguments)},t._TA_CDLSPINNINGTOP=function(){return(t._TA_CDLSPINNINGTOP=t.asm.TA_CDLSPINNINGTOP).apply(null,arguments)},t._TA_CDLSTALLEDPATTERN=function(){return(t._TA_CDLSTALLEDPATTERN=t.asm.TA_CDLSTALLEDPATTERN).apply(null,arguments)},t._TA_CDLSTICKSANDWICH=function(){return(t._TA_CDLSTICKSANDWICH=t.asm.TA_CDLSTICKSANDWICH).apply(null,arguments)},t._TA_CDLTAKURI=function(){return(t._TA_CDLTAKURI=t.asm.TA_CDLTAKURI).apply(null,arguments)},t._TA_CDLTASUKIGAP=function(){return(t._TA_CDLTASUKIGAP=t.asm.TA_CDLTASUKIGAP).apply(null,arguments)},t._TA_CDLTHRUSTING=function(){return(t._TA_CDLTHRUSTING=t.asm.TA_CDLTHRUSTING).apply(null,arguments)},t._TA_CDLTRISTAR=function(){return(t._TA_CDLTRISTAR=t.asm.TA_CDLTRISTAR).apply(null,arguments)},t._TA_CDLUNIQUE3RIVER=function(){return(t._TA_CDLUNIQUE3RIVER=t.asm.TA_CDLUNIQUE3RIVER).apply(null,arguments)},t._TA_CDLUPSIDEGAP2CROWS=function(){return(t._TA_CDLUPSIDEGAP2CROWS=t.asm.TA_CDLUPSIDEGAP2CROWS).apply(null,arguments)},t._TA_CDLXSIDEGAP3METHODS=function(){return(t._TA_CDLXSIDEGAP3METHODS=t.asm.TA_CDLXSIDEGAP3METHODS).apply(null,arguments)},t._TA_CEIL=function(){return(t._TA_CEIL=t.asm.TA_CEIL).apply(null,arguments)},t._TA_CMO=function(){return(t._TA_CMO=t.asm.TA_CMO).apply(null,arguments)},t._TA_CORREL=function(){return(t._TA_CORREL=t.asm.TA_CORREL).apply(null,arguments)},t._TA_COS=function(){return(t._TA_COS=t.asm.TA_COS).apply(null,arguments)},t._TA_COSH=function(){return(t._TA_COSH=t.asm.TA_COSH).apply(null,arguments)},t._TA_DEMA=function(){return(t._TA_DEMA=t.asm.TA_DEMA).apply(null,arguments)},t._TA_DIV=function(){return(t._TA_DIV=t.asm.TA_DIV).apply(null,arguments)},t._TA_DX=function(){return(t._TA_DX=t.asm.TA_DX).apply(null,arguments)},t._TA_EMA=function(){return(t._TA_EMA=t.asm.TA_EMA).apply(null,arguments)},t._TA_EXP=function(){return(t._TA_EXP=t.asm.TA_EXP).apply(null,arguments)},t._TA_FLOOR=function(){return(t._TA_FLOOR=t.asm.TA_FLOOR).apply(null,arguments)},t._TA_HT_DCPERIOD=function(){return(t._TA_HT_DCPERIOD=t.asm.TA_HT_DCPERIOD).apply(null,arguments)},t._TA_HT_DCPHASE=function(){return(t._TA_HT_DCPHASE=t.asm.TA_HT_DCPHASE).apply(null,arguments)},t._TA_HT_PHASOR=function(){return(t._TA_HT_PHASOR=t.asm.TA_HT_PHASOR).apply(null,arguments)},t._TA_HT_SINE=function(){return(t._TA_HT_SINE=t.asm.TA_HT_SINE).apply(null,arguments)},t._TA_HT_TRENDLINE=function(){return(t._TA_HT_TRENDLINE=t.asm.TA_HT_TRENDLINE).apply(null,arguments)},t._TA_HT_TRENDMODE=function(){return(t._TA_HT_TRENDMODE=t.asm.TA_HT_TRENDMODE).apply(null,arguments)},t._TA_IMI=function(){return(t._TA_IMI=t.asm.TA_IMI).apply(null,arguments)},t._TA_KAMA=function(){return(t._TA_KAMA=t.asm.TA_KAMA).apply(null,arguments)},t._TA_LINEARREG=function(){return(t._TA_LINEARREG=t.asm.TA_LINEARREG).apply(null,arguments)},t._TA_LINEARREG_ANGLE=function(){return(t._TA_LINEARREG_ANGLE=t.asm.TA_LINEARREG_ANGLE).apply(null,arguments)},t._TA_LINEARREG_INTERCEPT=function(){return(t._TA_LINEARREG_INTERCEPT=t.asm.TA_LINEARREG_INTERCEPT).apply(null,arguments)},t._TA_LINEARREG_SLOPE=function(){return(t._TA_LINEARREG_SLOPE=t.asm.TA_LINEARREG_SLOPE).apply(null,arguments)},t._TA_LN=function(){return(t._TA_LN=t.asm.TA_LN).apply(null,arguments)},t._TA_LOG10=function(){return(t._TA_LOG10=t.asm.TA_LOG10).apply(null,arguments)},t._TA_WMA=function(){return(t._TA_WMA=t.asm.TA_WMA).apply(null,arguments)},t._TA_TEMA=function(){return(t._TA_TEMA=t.asm.TA_TEMA).apply(null,arguments)},t._TA_TRIMA=function(){return(t._TA_TRIMA=t.asm.TA_TRIMA).apply(null,arguments)},t._TA_MAMA=function(){return(t._TA_MAMA=t.asm.TA_MAMA).apply(null,arguments)},t._TA_T3=function(){return(t._TA_T3=t.asm.TA_T3).apply(null,arguments)},t._TA_MACD=function(){return(t._TA_MACD=t.asm.TA_MACD).apply(null,arguments)},t._TA_MACDEXT=function(){return(t._TA_MACDEXT=t.asm.TA_MACDEXT).apply(null,arguments)},t._TA_MACDFIX=function(){return(t._TA_MACDFIX=t.asm.TA_MACDFIX).apply(null,arguments)},t._TA_MAVP=function(){return(t._TA_MAVP=t.asm.TA_MAVP).apply(null,arguments)},t._TA_MAX=function(){return(t._TA_MAX=t.asm.TA_MAX).apply(null,arguments)},t._TA_MAXINDEX=function(){return(t._TA_MAXINDEX=t.asm.TA_MAXINDEX).apply(null,arguments)},t._TA_MEDPRICE=function(){return(t._TA_MEDPRICE=t.asm.TA_MEDPRICE).apply(null,arguments)},t._TA_MFI=function(){return(t._TA_MFI=t.asm.TA_MFI).apply(null,arguments)},t._TA_MIDPOINT=function(){return(t._TA_MIDPOINT=t.asm.TA_MIDPOINT).apply(null,arguments)},t._TA_MIDPRICE=function(){return(t._TA_MIDPRICE=t.asm.TA_MIDPRICE).apply(null,arguments)},t._TA_MIN=function(){return(t._TA_MIN=t.asm.TA_MIN).apply(null,arguments)},t._TA_MININDEX=function(){return(t._TA_MININDEX=t.asm.TA_MININDEX).apply(null,arguments)},t._TA_MINMAX=function(){return(t._TA_MINMAX=t.asm.TA_MINMAX).apply(null,arguments)},t._TA_MINMAXINDEX=function(){return(t._TA_MINMAXINDEX=t.asm.TA_MINMAXINDEX).apply(null,arguments)},t._TA_MINUS_DI=function(){return(t._TA_MINUS_DI=t.asm.TA_MINUS_DI).apply(null,arguments)},t._TA_MINUS_DM=function(){return(t._TA_MINUS_DM=t.asm.TA_MINUS_DM).apply(null,arguments)},t._TA_MOM=function(){return(t._TA_MOM=t.asm.TA_MOM).apply(null,arguments)},t._TA_MULT=function(){return(t._TA_MULT=t.asm.TA_MULT).apply(null,arguments)},t._TA_NATR=function(){return(t._TA_NATR=t.asm.TA_NATR).apply(null,arguments)},t._TA_OBV=function(){return(t._TA_OBV=t.asm.TA_OBV).apply(null,arguments)},t._TA_PLUS_DI=function(){return(t._TA_PLUS_DI=t.asm.TA_PLUS_DI).apply(null,arguments)},t._TA_PLUS_DM=function(){return(t._TA_PLUS_DM=t.asm.TA_PLUS_DM).apply(null,arguments)},t._TA_PPO=function(){return(t._TA_PPO=t.asm.TA_PPO).apply(null,arguments)},t._TA_ROC=function(){return(t._TA_ROC=t.asm.TA_ROC).apply(null,arguments)},t._TA_ROCP=function(){return(t._TA_ROCP=t.asm.TA_ROCP).apply(null,arguments)},t._TA_ROCR=function(){return(t._TA_ROCR=t.asm.TA_ROCR).apply(null,arguments)},t._TA_ROCR100=function(){return(t._TA_ROCR100=t.asm.TA_ROCR100).apply(null,arguments)},t._TA_RSI=function(){return(t._TA_RSI=t.asm.TA_RSI).apply(null,arguments)},t._TA_SAR=function(){return(t._TA_SAR=t.asm.TA_SAR).apply(null,arguments)},t._TA_SAREXT=function(){return(t._TA_SAREXT=t.asm.TA_SAREXT).apply(null,arguments)},t._TA_SIN=function(){return(t._TA_SIN=t.asm.TA_SIN).apply(null,arguments)},t._TA_SINH=function(){return(t._TA_SINH=t.asm.TA_SINH).apply(null,arguments)},t._TA_SQRT=function(){return(t._TA_SQRT=t.asm.TA_SQRT).apply(null,arguments)},t._TA_STOCH=function(){return(t._TA_STOCH=t.asm.TA_STOCH).apply(null,arguments)},t._TA_STOCHF=function(){return(t._TA_STOCHF=t.asm.TA_STOCHF).apply(null,arguments)},t._TA_STOCHRSI=function(){return(t._TA_STOCHRSI=t.asm.TA_STOCHRSI).apply(null,arguments)},t._TA_SUB=function(){return(t._TA_SUB=t.asm.TA_SUB).apply(null,arguments)},t._TA_SUM=function(){return(t._TA_SUM=t.asm.TA_SUM).apply(null,arguments)},t._TA_TAN=function(){return(t._TA_TAN=t.asm.TA_TAN).apply(null,arguments)},t._TA_TANH=function(){return(t._TA_TANH=t.asm.TA_TANH).apply(null,arguments)},t._TA_TRIX=function(){return(t._TA_TRIX=t.asm.TA_TRIX).apply(null,arguments)},t._TA_TSF=function(){return(t._TA_TSF=t.asm.TA_TSF).apply(null,arguments)},t._TA_TYPPRICE=function(){return(t._TA_TYPPRICE=t.asm.TA_TYPPRICE).apply(null,arguments)},t._TA_ULTOSC=function(){return(t._TA_ULTOSC=t.asm.TA_ULTOSC).apply(null,arguments)},t._TA_VAR=function(){return(t._TA_VAR=t.asm.TA_VAR).apply(null,arguments)},t._TA_WCLPRICE=function(){return(t._TA_WCLPRICE=t.asm.TA_WCLPRICE).apply(null,arguments)},t._TA_WILLR=function(){return(t._TA_WILLR=t.asm.TA_WILLR).apply(null,arguments)};var Jc=t.stackSave=function(){return(Jc=t.stackSave=t.asm.stackSave).apply(null,arguments)},Qa=t.stackRestore=function(){return(Qa=t.stackRestore=t.asm.stackRestore).apply(null,arguments)},Fe=t.stackAlloc=function(){return(Fe=t.stackAlloc=t.asm.stackAlloc).apply(null,arguments)},ot=t.___assign_got_enties=function(){return(ot=t.___assign_got_enties=t.asm.__assign_got_enties).apply(null,arguments)};t._TA_Globals=1448,t.___data_end=4888;for(var ln in["TA_Globals","__data_end"])(function(Ee){t["g$"+Ee]=function(){return t[Ee]}})(ln);t.ccall=I,t.allocate=O;var ut;function Ne(Ee){this.name="ExitStatus",this.message="Program terminated with exit("+Ee+")",this.status=Ee}q=function Ee(){ut||at(),ut||(q=Ee)};function Qe(Ee){var Te=t._main;if(Te){var Ue=0,tt=0;try{var Ut=Te(Ue,tt);Bn(Ut,!0)}catch(Lt){if(Lt instanceof Ne)return;if(Lt=="unwind"){E=!0;return}else{var Zt=Lt;Lt&&typeof Lt=="object"&&Lt.stack&&(Zt=[Lt,Lt.stack]),C("exception thrown: "+Zt),a(1,Lt)}}finally{}}}function at(Ee){if(V>0||(J(),V>0))return;function Te(){ut||(ut=!0,t.calledRun=!0,!A&&(ie(),G(),i(t),t.onRuntimeInitialized&&t.onRuntimeInitialized(),gi&&Qe(),Q()))}t.setStatus?(t.setStatus("Running..."),setTimeout(function(){setTimeout(function(){t.setStatus("")},1),Te()},1)):Te()}t.run=at;function Bn(Ee,Te){Te&&E&&Ee===0||(E||(t.onExit&&t.onExit(Ee),A=!0),a(Ee,new Ne(Ee)))}if(t.preInit)for(typeof t.preInit=="function"&&(t.preInit=[t.preInit]);t.preInit.length>0;)t.preInit.pop()();var gi=!0;return t.noInitialRun&&(gi=!1),E=!0,at(),e.ready}}();const Re={ACCBANDS:{name:"ACCBANDS",camelCaseName:"accBands",group:"Overlap Studies",description:"Acceleration Bands",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:20,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"upperBand",type:"Double[]",plotHint:"limit_upper"},{name:"middleBand",type:"Double[]",plotHint:"line"},{name:"lowerBand",type:"Double[]",plotHint:"limit_lower"}]},ACOS:{name:"ACOS",camelCaseName:"acos",group:"Math Transform",description:"Vector Trigonometric ACos",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AD:{name:"AD",camelCaseName:"ad",group:"Volume Indicators",description:"Chaikin A/D Line",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADD:{name:"ADD",camelCaseName:"add",group:"Math Operators",description:"Vector Arithmetic Add",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADOSC:{name:"ADOSC",camelCaseName:"adOsc",group:"Volume Indicators",description:"Chaikin A/D Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:3,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:10,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADX:{name:"ADX",camelCaseName:"adx",group:"Momentum Indicators",description:"Average Directional Movement Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ADXR:{name:"ADXR",camelCaseName:"adxr",group:"Momentum Indicators",description:"Average Directional Movement Index Rating",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},APO:{name:"APO",camelCaseName:"apo",group:"Momentum Indicators",description:"Absolute Price Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AROON:{name:"AROON",camelCaseName:"aroon",group:"Momentum Indicators",description:"Aroon",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"aroonDown",type:"Double[]",plotHint:"line_dash"},{name:"aroonUp",type:"Double[]",plotHint:"line"}]},AROONOSC:{name:"AROONOSC",camelCaseName:"aroonOsc",group:"Momentum Indicators",description:"Aroon Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ASIN:{name:"ASIN",camelCaseName:"asin",group:"Math Transform",description:"Vector Trigonometric ASin",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ATAN:{name:"ATAN",camelCaseName:"atan",group:"Math Transform",description:"Vector Trigonometric ATan",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ATR:{name:"ATR",camelCaseName:"atr",group:"Volatility Indicators",description:"Average True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AVGDEV:{name:"AVGDEV",camelCaseName:"avgDev",group:"Price Transform",description:"Average Deviation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},AVGPRICE:{name:"AVGPRICE",camelCaseName:"avgPrice",group:"Price Transform",description:"Average Price",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},BBANDS:{name:"BBANDS",camelCaseName:"bbands",group:"Overlap Studies",description:"Bollinger Bands",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"nbDevUp",displayName:"Deviations up",defaultValue:2,hint:"Deviation multiplier for upper band",type:"Double",range:{min:-3e37,max:3e37}},{name:"nbDevDn",displayName:"Deviations down",defaultValue:2,hint:"Deviation multiplier for lower band",type:"Double",range:{min:-3e37,max:3e37}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"upperBand",type:"Double[]",plotHint:"limit_upper"},{name:"middleBand",type:"Double[]",plotHint:"line"},{name:"lowerBand",type:"Double[]",plotHint:"limit_lower"}]},BETA:{name:"BETA",camelCaseName:"beta",group:"Statistic Functions",description:"Beta",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},BOP:{name:"BOP",camelCaseName:"bop",group:"Momentum Indicators",description:"Balance Of Power",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CCI:{name:"CCI",camelCaseName:"cci",group:"Momentum Indicators",description:"Commodity Channel Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CDL2CROWS:{name:"CDL2CROWS",camelCaseName:"cdl2Crows",group:"Pattern Recognition",description:"Two Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3BLACKCROWS:{name:"CDL3BLACKCROWS",camelCaseName:"cdl3BlackCrows",group:"Pattern Recognition",description:"Three Black Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3INSIDE:{name:"CDL3INSIDE",camelCaseName:"cdl3Inside",group:"Pattern Recognition",description:"Three Inside Up/Down",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3LINESTRIKE:{name:"CDL3LINESTRIKE",camelCaseName:"cdl3LineStrike",group:"Pattern Recognition",description:"Three-Line Strike ",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3OUTSIDE:{name:"CDL3OUTSIDE",camelCaseName:"cdl3Outside",group:"Pattern Recognition",description:"Three Outside Up/Down",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3STARSINSOUTH:{name:"CDL3STARSINSOUTH",camelCaseName:"cdl3StarsInSouth",group:"Pattern Recognition",description:"Three Stars In The South",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDL3WHITESOLDIERS:{name:"CDL3WHITESOLDIERS",camelCaseName:"cdl3WhiteSoldiers",group:"Pattern Recognition",description:"Three Advancing White Soldiers",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLABANDONEDBABY:{name:"CDLABANDONEDBABY",camelCaseName:"cdlAbandonedBaby",group:"Pattern Recognition",description:"Abandoned Baby",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLADVANCEBLOCK:{name:"CDLADVANCEBLOCK",camelCaseName:"cdlAdvanceBlock",group:"Pattern Recognition",description:"Advance Block",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLBELTHOLD:{name:"CDLBELTHOLD",camelCaseName:"cdlBeltHold",group:"Pattern Recognition",description:"Belt-hold",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLBREAKAWAY:{name:"CDLBREAKAWAY",camelCaseName:"cdlBreakaway",group:"Pattern Recognition",description:"Breakaway",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCLOSINGMARUBOZU:{name:"CDLCLOSINGMARUBOZU",camelCaseName:"cdlClosingMarubozu",group:"Pattern Recognition",description:"Closing Marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCONCEALBABYSWALL:{name:"CDLCONCEALBABYSWALL",camelCaseName:"cdlConcealBabysWall",group:"Pattern Recognition",description:"Concealing Baby Swallow",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLCOUNTERATTACK:{name:"CDLCOUNTERATTACK",camelCaseName:"cdlCounterAttack",group:"Pattern Recognition",description:"Counterattack",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDARKCLOUDCOVER:{name:"CDLDARKCLOUDCOVER",camelCaseName:"cdlDarkCloudCover",group:"Pattern Recognition",description:"Dark Cloud Cover",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.5,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDOJI:{name:"CDLDOJI",camelCaseName:"cdlDoji",group:"Pattern Recognition",description:"Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDOJISTAR:{name:"CDLDOJISTAR",camelCaseName:"cdlDojiStar",group:"Pattern Recognition",description:"Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLDRAGONFLYDOJI:{name:"CDLDRAGONFLYDOJI",camelCaseName:"cdlDragonflyDoji",group:"Pattern Recognition",description:"Dragonfly Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLENGULFING:{name:"CDLENGULFING",camelCaseName:"cdlEngulfing",group:"Pattern Recognition",description:"Engulfing Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLEVENINGDOJISTAR:{name:"CDLEVENINGDOJISTAR",camelCaseName:"cdlEveningDojiStar",group:"Pattern Recognition",description:"Evening Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLEVENINGSTAR:{name:"CDLEVENINGSTAR",camelCaseName:"cdlEveningStar",group:"Pattern Recognition",description:"Evening Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLGAPSIDESIDEWHITE:{name:"CDLGAPSIDESIDEWHITE",camelCaseName:"cdlGapSideSideWhite",group:"Pattern Recognition",description:"Up/Down-gap side-by-side white lines",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLGRAVESTONEDOJI:{name:"CDLGRAVESTONEDOJI",camelCaseName:"cdlGravestoneDoji",group:"Pattern Recognition",description:"Gravestone Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHAMMER:{name:"CDLHAMMER",camelCaseName:"cdlHammer",group:"Pattern Recognition",description:"Hammer",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHANGINGMAN:{name:"CDLHANGINGMAN",camelCaseName:"cdlHangingMan",group:"Pattern Recognition",description:"Hanging Man",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHARAMI:{name:"CDLHARAMI",camelCaseName:"cdlHarami",group:"Pattern Recognition",description:"Harami Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHARAMICROSS:{name:"CDLHARAMICROSS",camelCaseName:"cdlHaramiCross",group:"Pattern Recognition",description:"Harami Cross Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIGHWAVE:{name:"CDLHIGHWAVE",camelCaseName:"cdlHignWave",group:"Pattern Recognition",description:"High-Wave Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIKKAKE:{name:"CDLHIKKAKE",camelCaseName:"cdlHikkake",group:"Pattern Recognition",description:"Hikkake Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHIKKAKEMOD:{name:"CDLHIKKAKEMOD",camelCaseName:"cdlHikkakeMod",group:"Pattern Recognition",description:"Modified Hikkake Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLHOMINGPIGEON:{name:"CDLHOMINGPIGEON",camelCaseName:"cdlHomingPigeon",group:"Pattern Recognition",description:"Homing Pigeon",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLIDENTICAL3CROWS:{name:"CDLIDENTICAL3CROWS",camelCaseName:"cdlIdentical3Crows",group:"Pattern Recognition",description:"Identical Three Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLINNECK:{name:"CDLINNECK",camelCaseName:"cdlInNeck",group:"Pattern Recognition",description:"In-Neck Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLINVERTEDHAMMER:{name:"CDLINVERTEDHAMMER",camelCaseName:"cdlInvertedHammer",group:"Pattern Recognition",description:"Inverted Hammer",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLKICKING:{name:"CDLKICKING",camelCaseName:"cdlKicking",group:"Pattern Recognition",description:"Kicking",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLKICKINGBYLENGTH:{name:"CDLKICKINGBYLENGTH",camelCaseName:"cdlKickingByLength",group:"Pattern Recognition",description:"Kicking - bull/bear determined by the longer marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLADDERBOTTOM:{name:"CDLLADDERBOTTOM",camelCaseName:"cdlLadderBottom",group:"Pattern Recognition",description:"Ladder Bottom",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLONGLEGGEDDOJI:{name:"CDLLONGLEGGEDDOJI",camelCaseName:"cdlLongLeggedDoji",group:"Pattern Recognition",description:"Long Legged Doji",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLLONGLINE:{name:"CDLLONGLINE",camelCaseName:"cdlLongLine",group:"Pattern Recognition",description:"Long Line Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMARUBOZU:{name:"CDLMARUBOZU",camelCaseName:"cdlMarubozu",group:"Pattern Recognition",description:"Marubozu",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMATCHINGLOW:{name:"CDLMATCHINGLOW",camelCaseName:"cdlMatchingLow",group:"Pattern Recognition",description:"Matching Low",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMATHOLD:{name:"CDLMATHOLD",camelCaseName:"cdlMatHold",group:"Pattern Recognition",description:"Mat Hold",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.5,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMORNINGDOJISTAR:{name:"CDLMORNINGDOJISTAR",camelCaseName:"cdlMorningDojiStar",group:"Pattern Recognition",description:"Morning Doji Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLMORNINGSTAR:{name:"CDLMORNINGSTAR",camelCaseName:"cdlMorningStar",group:"Pattern Recognition",description:"Morning Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"penetration",displayName:"Penetration",defaultValue:.3,hint:"Percentage of penetration of a candle within another candle",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLONNECK:{name:"CDLONNECK",camelCaseName:"cdlOnNeck",group:"Pattern Recognition",description:"On-Neck Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLPIERCING:{name:"CDLPIERCING",camelCaseName:"cdlPiercing",group:"Pattern Recognition",description:"Piercing Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLRICKSHAWMAN:{name:"CDLRICKSHAWMAN",camelCaseName:"cdlRickshawMan",group:"Pattern Recognition",description:"Rickshaw Man",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLRISEFALL3METHODS:{name:"CDLRISEFALL3METHODS",camelCaseName:"cdlRiseFall3Methods",group:"Pattern Recognition",description:"Rising/Falling Three Methods",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSEPARATINGLINES:{name:"CDLSEPARATINGLINES",camelCaseName:"cdlSeperatingLines",group:"Pattern Recognition",description:"Separating Lines",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSHOOTINGSTAR:{name:"CDLSHOOTINGSTAR",camelCaseName:"cdlShootingStar",group:"Pattern Recognition",description:"Shooting Star",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSHORTLINE:{name:"CDLSHORTLINE",camelCaseName:"cdlShortLine",group:"Pattern Recognition",description:"Short Line Candle",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSPINNINGTOP:{name:"CDLSPINNINGTOP",camelCaseName:"cdlSpinningTop",group:"Pattern Recognition",description:"Spinning Top",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSTALLEDPATTERN:{name:"CDLSTALLEDPATTERN",camelCaseName:"cdlStalledPattern",group:"Pattern Recognition",description:"Stalled Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLSTICKSANDWICH:{name:"CDLSTICKSANDWICH",camelCaseName:"cdlStickSandwhich",group:"Pattern Recognition",description:"Stick Sandwich",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTAKURI:{name:"CDLTAKURI",camelCaseName:"cdlTakuri",group:"Pattern Recognition",description:"Takuri (Dragonfly Doji with very long lower shadow)",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTASUKIGAP:{name:"CDLTASUKIGAP",camelCaseName:"cdlTasukiGap",group:"Pattern Recognition",description:"Tasuki Gap",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTHRUSTING:{name:"CDLTHRUSTING",camelCaseName:"cdlThrusting",group:"Pattern Recognition",description:"Thrusting Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLTRISTAR:{name:"CDLTRISTAR",camelCaseName:"cdlTristar",group:"Pattern Recognition",description:"Tristar Pattern",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLUNIQUE3RIVER:{name:"CDLUNIQUE3RIVER",camelCaseName:"cdlUnique3River",group:"Pattern Recognition",description:"Unique 3 River",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLUPSIDEGAP2CROWS:{name:"CDLUPSIDEGAP2CROWS",camelCaseName:"cdlUpsideGap2Crows",group:"Pattern Recognition",description:"Upside Gap Two Crows",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CDLXSIDEGAP3METHODS:{name:"CDLXSIDEGAP3METHODS",camelCaseName:"cdlXSideGap3Methods",group:"Pattern Recognition",description:"Upside/Downside Gap Three Methods",inputs:[{name:"open",type:"Double[]"},{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},CEIL:{name:"CEIL",camelCaseName:"ceil",group:"Math Transform",description:"Vector Ceil",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CMO:{name:"CMO",camelCaseName:"cmo",group:"Momentum Indicators",description:"Chande Momentum Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},CORREL:{name:"CORREL",camelCaseName:"correl",group:"Statistic Functions",description:"Pearson's Correlation Coefficient (r)",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},COS:{name:"COS",camelCaseName:"cos",group:"Math Transform",description:"Vector Trigonometric Cos",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},COSH:{name:"COSH",camelCaseName:"cosh",group:"Math Transform",description:"Vector Trigonometric Cosh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DEMA:{name:"DEMA",camelCaseName:"dema",group:"Overlap Studies",description:"Double Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DIV:{name:"DIV",camelCaseName:"div",group:"Math Operators",description:"Vector Arithmetic Div",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},DX:{name:"DX",camelCaseName:"dx",group:"Momentum Indicators",description:"Directional Movement Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},EMA:{name:"EMA",camelCaseName:"ema",group:"Overlap Studies",description:"Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},EXP:{name:"EXP",camelCaseName:"exp",group:"Math Transform",description:"Vector Arithmetic Exp",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},FLOOR:{name:"FLOOR",camelCaseName:"floor",group:"Math Transform",description:"Vector Floor",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_DCPERIOD:{name:"HT_DCPERIOD",camelCaseName:"htDcPeriod",group:"Cycle Indicators",description:"Hilbert Transform - Dominant Cycle Period",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_DCPHASE:{name:"HT_DCPHASE",camelCaseName:"htDcPhase",group:"Cycle Indicators",description:"Hilbert Transform - Dominant Cycle Phase",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_PHASOR:{name:"HT_PHASOR",camelCaseName:"htPhasor",group:"Cycle Indicators",description:"Hilbert Transform - Phasor Components",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"inPhase",type:"Double[]",plotHint:"line"},{name:"quadrature",type:"Double[]",plotHint:"line_dash"}]},HT_SINE:{name:"HT_SINE",camelCaseName:"htSine",group:"Cycle Indicators",description:"Hilbert Transform - SineWave",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"sine",type:"Double[]",plotHint:"line"},{name:"leadSine",type:"Double[]",plotHint:"line_dash"}]},HT_TRENDLINE:{name:"HT_TRENDLINE",camelCaseName:"htTrendline",group:"Overlap Studies",description:"Hilbert Transform - Instantaneous Trendline",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},HT_TRENDMODE:{name:"HT_TRENDMODE",camelCaseName:"htTrendMode",group:"Cycle Indicators",description:"Hilbert Transform - Trend vs Cycle Mode",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},IMI:{name:"IMI",camelCaseName:"imi",group:"Momentum Indicators",description:"Intraday Momentum Index",inputs:[{name:"open",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},KAMA:{name:"KAMA",camelCaseName:"kama",group:"Overlap Studies",description:"Kaufman Adaptive Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG:{name:"LINEARREG",camelCaseName:"linearReg",group:"Statistic Functions",description:"Linear Regression",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_ANGLE:{name:"LINEARREG_ANGLE",camelCaseName:"linearRegAngle",group:"Statistic Functions",description:"Linear Regression Angle",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_INTERCEPT:{name:"LINEARREG_INTERCEPT",camelCaseName:"linearRegIntercept",group:"Statistic Functions",description:"Linear Regression Intercept",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LINEARREG_SLOPE:{name:"LINEARREG_SLOPE",camelCaseName:"linearRegSlope",group:"Statistic Functions",description:"Linear Regression Slope",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LN:{name:"LN",camelCaseName:"ln",group:"Math Transform",description:"Vector Log Natural",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},LOG10:{name:"LOG10",camelCaseName:"log10",group:"Math Transform",description:"Vector Log10",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MA:{name:"MA",camelCaseName:"movingAverage",group:"Overlap Studies",description:"Moving average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MACD:{name:"MACD",camelCaseName:"macd",group:"Momentum Indicators",description:"Moving Average Convergence/Divergence",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MACDEXT:{name:"MACDEXT",camelCaseName:"macdExt",group:"Momentum Indicators",description:"MACD with controllable MA type",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"fastMAType",displayName:"Fast MA",defaultValue:0,hint:"Type of Moving Average for fast MA",type:"MAType"},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowMAType",displayName:"Slow MA",defaultValue:0,hint:"Type of Moving Average for slow MA",type:"MAType"},{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}},{name:"signalMAType",displayName:"Signal MA",defaultValue:0,hint:"Type of Moving Average for signal line",type:"MAType"}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MACDFIX:{name:"MACDFIX",camelCaseName:"macdFix",group:"Momentum Indicators",description:"Moving Average Convergence/Divergence Fix 12/26",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"signalPeriod",displayName:"Signal Period",defaultValue:9,hint:"Smoothing for the signal line (nb of period)",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"MACD",type:"Double[]",plotHint:"line"},{name:"MACDSignal",type:"Double[]",plotHint:"line_dash"},{name:"MACDHist",type:"Double[]",plotHint:"histogram"}]},MAMA:{name:"MAMA",camelCaseName:"mama",group:"Overlap Studies",description:"MESA Adaptive Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastLimit",displayName:"Fast Limit",defaultValue:.5,hint:"Upper limit use in the adaptive algorithm",type:"Double",range:{min:.01,max:.99}},{name:"slowLimit",displayName:"Slow Limit",defaultValue:.05,hint:"Lower limit use in the adaptive algorithm",type:"Double",range:{min:.01,max:.99}}],outputs:[{name:"MAMA",type:"Double[]",plotHint:"line"},{name:"FAMA",type:"Double[]",plotHint:"line_dash"}]},MAVP:{name:"MAVP",camelCaseName:"movingAverageVariablePeriod",group:"Overlap Studies",description:"Moving average with variable period",inputs:[{name:"inReal",type:"Double[]"},{name:"inPeriods",type:"Double[]"}],options:[{name:"minPeriod",displayName:"Minimum Period",defaultValue:2,hint:"Value less than minimum will be changed to Minimum period",type:"Integer",range:{min:2,max:1e5}},{name:"maxPeriod",displayName:"Maximum Period",defaultValue:30,hint:"Value higher than maximum will be changed to Maximum period",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MAX:{name:"MAX",camelCaseName:"max",group:"Math Operators",description:"Highest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MAXINDEX:{name:"MAXINDEX",camelCaseName:"maxIndex",group:"Math Operators",description:"Index of highest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},MEDPRICE:{name:"MEDPRICE",camelCaseName:"medPrice",group:"Price Transform",description:"Median Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MFI:{name:"MFI",camelCaseName:"mfi",group:"Momentum Indicators",description:"Money Flow Index",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIDPOINT:{name:"MIDPOINT",camelCaseName:"midPoint",group:"Overlap Studies",description:"MidPoint over period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIDPRICE:{name:"MIDPRICE",camelCaseName:"midPrice",group:"Overlap Studies",description:"Midpoint Price over period",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MIN:{name:"MIN",camelCaseName:"min",group:"Math Operators",description:"Lowest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MININDEX:{name:"MININDEX",camelCaseName:"minIndex",group:"Math Operators",description:"Index of lowest value over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Integer[]",plotHint:"line"}]},MINMAX:{name:"MINMAX",camelCaseName:"minMax",group:"Math Operators",description:"Lowest and highest values over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"min",type:"Double[]",plotHint:"line"},{name:"max",type:"Double[]",plotHint:"line"}]},MINMAXINDEX:{name:"MINMAXINDEX",camelCaseName:"minMaxIndex",group:"Math Operators",description:"Indexes of lowest and highest values over a specified period",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"minIdx",type:"Integer[]",plotHint:"line"},{name:"maxIdx",type:"Integer[]",plotHint:"line"}]},MINUS_DI:{name:"MINUS_DI",camelCaseName:"minusDI",group:"Momentum Indicators",description:"Minus Directional Indicator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MINUS_DM:{name:"MINUS_DM",camelCaseName:"minusDM",group:"Momentum Indicators",description:"Minus Directional Movement",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MOM:{name:"MOM",camelCaseName:"mom",group:"Momentum Indicators",description:"Momentum",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},MULT:{name:"MULT",camelCaseName:"mult",group:"Math Operators",description:"Vector Arithmetic Mult",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},NATR:{name:"NATR",camelCaseName:"natr",group:"Volatility Indicators",description:"Normalized Average True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},OBV:{name:"OBV",camelCaseName:"obv",group:"Volume Indicators",description:"On Balance Volume",inputs:[{name:"inReal",type:"Double[]"},{name:"volume",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PLUS_DI:{name:"PLUS_DI",camelCaseName:"plusDI",group:"Momentum Indicators",description:"Plus Directional Indicator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PLUS_DM:{name:"PLUS_DM",camelCaseName:"plusDM",group:"Momentum Indicators",description:"Plus Directional Movement",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},PPO:{name:"PPO",camelCaseName:"ppo",group:"Momentum Indicators",description:"Percentage Price Oscillator",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"fastPeriod",displayName:"Fast Period",defaultValue:12,hint:"Number of period for the fast MA",type:"Integer",range:{min:2,max:1e5}},{name:"slowPeriod",displayName:"Slow Period",defaultValue:26,hint:"Number of period for the slow MA",type:"Integer",range:{min:2,max:1e5}},{name:"MAType",displayName:"MA Type",defaultValue:0,hint:"Type of Moving Average",type:"MAType"}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROC:{name:"ROC",camelCaseName:"roc",group:"Momentum Indicators",description:"Rate of change : ((price/prevPrice)-1)*100",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCP:{name:"ROCP",camelCaseName:"rocP",group:"Momentum Indicators",description:"Rate of change Percentage: (price-prevPrice)/prevPrice",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCR:{name:"ROCR",camelCaseName:"rocR",group:"Momentum Indicators",description:"Rate of change ratio: (price/prevPrice)",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ROCR100:{name:"ROCR100",camelCaseName:"rocR100",group:"Momentum Indicators",description:"Rate of change ratio 100 scale: (price/prevPrice)*100",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:10,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},RSI:{name:"RSI",camelCaseName:"rsi",group:"Momentum Indicators",description:"Relative Strength Index",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SAR:{name:"SAR",camelCaseName:"sar",group:"Overlap Studies",description:"Parabolic SAR",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"acceleration",displayName:"Acceleration Factor",defaultValue:.02,hint:"Acceleration Factor used up to the Maximum value",type:"Double",range:{min:0,max:3e37}},{name:"maximum",displayName:"AF Maximum",defaultValue:.2,hint:"Acceleration Factor Maximum value",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SAREXT:{name:"SAREXT",camelCaseName:"sarExt",group:"Overlap Studies",description:"Parabolic SAR - Extended",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"}],options:[{name:"startValue",displayName:"Start Value",defaultValue:0,hint:"Start value and direction. 0 for Auto, >0 for Long, <0 for Short",type:"Double",range:{min:-3e37,max:3e37}},{name:"offsetOnReverse",displayName:"Offset on Reverse",defaultValue:0,hint:"Percent offset added/removed to initial stop on short/long reversal",type:"Double",range:{min:0,max:3e37}},{name:"accelerationInitLong",displayName:"AF Init Long",defaultValue:.02,hint:"Acceleration Factor initial value for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationLong",displayName:"AF Long",defaultValue:.02,hint:"Acceleration Factor for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationMaxLong",displayName:"AF Max Long",defaultValue:.2,hint:"Acceleration Factor maximum value for the Long direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationInitShort",displayName:"AF Init Short",defaultValue:.02,hint:"Acceleration Factor initial value for the Short direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationShort",displayName:"AF Short",defaultValue:.02,hint:"Acceleration Factor for the Short direction",type:"Double",range:{min:0,max:3e37}},{name:"accelerationMaxShort",displayName:"AF Max Short",defaultValue:.2,hint:"Acceleration Factor maximum value for the Short direction",type:"Double",range:{min:0,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SIN:{name:"SIN",camelCaseName:"sin",group:"Math Transform",description:"Vector Trigonometric Sin",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SINH:{name:"SINH",camelCaseName:"sinh",group:"Math Transform",description:"Vector Trigonometric Sinh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SMA:{name:"SMA",camelCaseName:"sma",group:"Overlap Studies",description:"Simple Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SQRT:{name:"SQRT",camelCaseName:"sqrt",group:"Math Transform",description:"Vector Square Root",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},STDDEV:{name:"STDDEV",camelCaseName:"stdDev",group:"Statistic Functions",description:"Standard Deviation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"nbDev",displayName:"Deviations",defaultValue:1,hint:"Nb of deviations",type:"Double",range:{min:-3e37,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},STOCH:{name:"STOCH",camelCaseName:"stoch",group:"Momentum Indicators",description:"Stochastic",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"slowK_Period",displayName:"Slow-K Period",defaultValue:3,hint:"Smoothing for making the Slow-K line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"slowK_MAType",displayName:"Slow-K MA",defaultValue:0,hint:"Type of Moving Average for Slow-K",type:"MAType"},{name:"slowD_Period",displayName:"Slow-D Period",defaultValue:3,hint:"Smoothing for making the Slow-D line",type:"Integer",range:{min:1,max:1e5}},{name:"slowD_MAType",displayName:"Slow-D MA",defaultValue:0,hint:"Type of Moving Average for Slow-D",type:"MAType"}],outputs:[{name:"slowK",type:"Double[]",plotHint:"line_dash"},{name:"slowD",type:"Double[]",plotHint:"line_dash"}]},STOCHF:{name:"STOCHF",camelCaseName:"stochF",group:"Momentum Indicators",description:"Stochastic Fast",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_Period",displayName:"Fast-D Period",defaultValue:3,hint:"Smoothing for making the Fast-D line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_MAType",displayName:"Fast-D MA",defaultValue:0,hint:"Type of Moving Average for Fast-D",type:"MAType"}],outputs:[{name:"fastK",type:"Double[]",plotHint:"line"},{name:"fastD",type:"Double[]",plotHint:"line"}]},STOCHRSI:{name:"STOCHRSI",camelCaseName:"stochRsi",group:"Momentum Indicators",description:"Stochastic Relative Strength Index",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"fastK_Period",displayName:"Fast-K Period",defaultValue:5,hint:"Time period for building the Fast-K line",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_Period",displayName:"Fast-D Period",defaultValue:3,hint:"Smoothing for making the Fast-D line. Usually set to 3",type:"Integer",range:{min:1,max:1e5}},{name:"fastD_MAType",displayName:"Fast-D MA",defaultValue:0,hint:"Type of Moving Average for Fast-D",type:"MAType"}],outputs:[{name:"fastK",type:"Double[]",plotHint:"line"},{name:"fastD",type:"Double[]",plotHint:"line"}]},SUB:{name:"SUB",camelCaseName:"sub",group:"Math Operators",description:"Vector Arithmetic Substraction",inputs:[{name:"inReal0",type:"Double[]"},{name:"inReal1",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},SUM:{name:"SUM",camelCaseName:"sum",group:"Math Operators",description:"Summation",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},T3:{name:"T3",camelCaseName:"t3",group:"Overlap Studies",description:"Triple Exponential Moving Average (T3)",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}},{name:"VFactor",displayName:"Volume Factor",defaultValue:.7,hint:"Volume Factor",type:"Double",range:{min:0,max:1}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TAN:{name:"TAN",camelCaseName:"tan",group:"Math Transform",description:"Vector Trigonometric Tan",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TANH:{name:"TANH",camelCaseName:"tanh",group:"Math Transform",description:"Vector Trigonometric Tanh",inputs:[{name:"inReal",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TEMA:{name:"TEMA",camelCaseName:"tema",group:"Overlap Studies",description:"Triple Exponential Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRANGE:{name:"TRANGE",camelCaseName:"trueRange",group:"Volatility Indicators",description:"True Range",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRIMA:{name:"TRIMA",camelCaseName:"trima",group:"Overlap Studies",description:"Triangular Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TRIX:{name:"TRIX",camelCaseName:"trix",group:"Momentum Indicators",description:"1-day Rate-Of-Change (ROC) of a Triple Smooth EMA",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TSF:{name:"TSF",camelCaseName:"tsf",group:"Statistic Functions",description:"Time Series Forecast",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},TYPPRICE:{name:"TYPPRICE",camelCaseName:"typPrice",group:"Price Transform",description:"Typical Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},ULTOSC:{name:"ULTOSC",camelCaseName:"ultOsc",group:"Momentum Indicators",description:"Ultimate Oscillator",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod1",displayName:"First Period",defaultValue:7,hint:"Number of bars for 1st period.",type:"Integer",range:{min:1,max:1e5}},{name:"timePeriod2",displayName:"Second Period",defaultValue:14,hint:"Number of bars fro 2nd period",type:"Integer",range:{min:1,max:1e5}},{name:"timePeriod3",displayName:"Third Period",defaultValue:28,hint:"Number of bars for 3rd period",type:"Integer",range:{min:1,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},VAR:{name:"VAR",camelCaseName:"variance",group:"Statistic Functions",description:"Variance",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:5,hint:"Number of period",type:"Integer",range:{min:1,max:1e5}},{name:"nbDev",displayName:"Deviations",defaultValue:1,hint:"Nb of deviations",type:"Double",range:{min:-3e37,max:3e37}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WCLPRICE:{name:"WCLPRICE",camelCaseName:"wclPrice",group:"Price Transform",description:"Weighted Close Price",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WILLR:{name:"WILLR",camelCaseName:"willR",group:"Momentum Indicators",description:"Williams' %R",inputs:[{name:"high",type:"Double[]"},{name:"low",type:"Double[]"},{name:"close",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:14,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]},WMA:{name:"WMA",camelCaseName:"wma",group:"Overlap Studies",description:"Weighted Moving Average",inputs:[{name:"inReal",type:"Double[]"}],options:[{name:"timePeriod",displayName:"Time Period",defaultValue:30,hint:"Number of period",type:"Integer",range:{min:2,max:1e5}}],outputs:[{name:"output",type:"Double[]",plotHint:"line"}]}};var XE=XE;let h0;function mJ(n,e){const t=n._malloc(e*8);return n.HEAPF64.set(new Float64Array(e),t/8),{data:n.HEAPF64.subarray(t/8,t/8+e),offset:t}}const Vtt={0:"TA_SUCCESS",1:"TA_LIB_NOT_INITIALIZE",2:"TA_BAD_PARAM",3:"TA_ALLOC_ERR",4:"TA_GROUP_NOT_FOUND",5:"TA_FUNC_NOT_FOUND",6:"TA_INVALID_HANDLE",7:"TA_INVALID_PARAM_HOLDER",8:"TA_INVALID_PARAM_HOLDER_TYPE",9:"TA_INVALID_PARAM_FUNCTION",10:"TA_INPUT_NOT_ALL_INITIALIZE",11:"TA_OUTPUT_NOT_ALL_INITIALIZE",12:"TA_OUT_OF_RANGE_START_INDEX",13:"TA_OUT_OF_RANGE_END_INDEX",14:"TA_INVALID_LIST_TYPE",15:"TA_BAD_OBJECT",16:"TA_NOT_SUPPORTED",5e3:"TA_INTERNAL_ERROR",65535:"TA_UNKNOWN_ERR"};function Oe(n,e){const t=`TA_${n.name}`;if(!h0)throw Error(`${n.name}() called before initialization.`);const i=2+n.inputs.length+n.options.length+2+n.outputs.length,r=new Array(i).fill("number");for(const{name:p}of n.inputs)if(!Array.isArray(e[p]))throw e[p]===void 0?Error(`Bad Param: "${p}" is required`):Error(`Bad Param: "${p}" should be array of number`);for(const{name:p,defaultValue:g,range:m}of n.options)if(e[p]===void 0)e[p]=g;else if(m&&(e[p]<m.min||e[p]>m.max))throw Error(`Bad Param: "${p}" out of range (min: ${m.min}, max: ${m.max})`);let{startIdx:o,endIdx:s}=e;o===void 0&&(o=0);const a=n.inputs.map(({name:p})=>e[p].length);s===void 0&&(s=Math.min(...a));const l=[o,s],u=[];n.inputs.forEach(({name:p})=>{const g=mJ(h0,s-o),m=e[p];for(const _ in m)g.data[_]=m[_];u.push(g),l.push(g.offset)}),n.options.forEach(({name:p})=>l.push(e[p])),l.push(0),l.push(0);const d=n.outputs.map(({name:p})=>{const g=mJ(h0,s-o);return u.push(g),l.push(g.offset),{name:p,array:g}}),h=h0.ccall(t,"number",r,l);u.forEach(p=>h0._free(p.offset));const f=d.reduce((p,g)=>(p[g.name]=Array.from(g.array.data),p),{});if(h===0)return f;throw Error("[C_ERROR] "+Vtt[h])}var JE;(function(n){n[n.SMA=0]="SMA",n[n.EMA=1]="EMA",n[n.WMA=2]="WMA",n[n.DEMA=3]="DEMA",n[n.TEMA=4]="TEMA",n[n.TRIMA=5]="TRIMA",n[n.KAMA=6]="KAMA",n[n.MAMA=7]="MAMA",n[n.T3=8]="T3"})(JE||(JE={}));function ek(n){return h0?Promise.resolve(h0):n&&typeof n!="string"?Promise.reject(new Error('Invalid argument, "init(wasmBinaryFilePath)" expects a string that specifies the location of wasm binary file')):XE({locateFile:n?()=>n:void 0}).then(t=>h0=t).catch(t=>{let i="TA-Lib WASM runtime init fail.";throw t&&t.message?i+=`
141
141
  Error:
142
142
  `+t.message:i+="Unknown reason. Perhaps you specify the wrong file path to wasm binary?",new Error(i)})}let ztt=Re.ACCBANDS;function bJ(n){return Oe(ztt,n)}const Htt=bJ;let jtt=Re.ACOS;function _J(n){return Oe(jtt,n)}const Wtt=_J;let $tt=Re.AD;function yJ(n){return Oe($tt,n)}const Utt=yJ;let qtt=Re.ADD;function vJ(n){return Oe(qtt,n)}const Ktt=vJ;let Gtt=Re.ADOSC;function CJ(n){return Oe(Gtt,n)}const Ytt=CJ;let Qtt=Re.ADX;function wJ(n){return Oe(Qtt,n)}const Ztt=wJ;let Xtt=Re.ADXR;function xJ(n){return Oe(Xtt,n)}const Jtt=xJ;let ent=Re.APO;function SJ(n){return Oe(ent,n)}const tnt=SJ;let nnt=Re.AROON;function DJ(n){return Oe(nnt,n)}const int=DJ;let rnt=Re.AROONOSC;function NJ(n){return Oe(rnt,n)}const ont=NJ;let snt=Re.ASIN;function EJ(n){return Oe(snt,n)}const ant=EJ;let lnt=Re.ATAN;function kJ(n){return Oe(lnt,n)}const unt=kJ;let cnt=Re.ATR;function LJ(n){return Oe(cnt,n)}const dnt=LJ;let hnt=Re.AVGDEV;function MJ(n){return Oe(hnt,n)}const fnt=MJ;let pnt=Re.AVGPRICE;function TJ(n){return Oe(pnt,n)}const gnt=TJ;let mnt=Re.BBANDS;function AJ(n){return Oe(mnt,n)}const bnt=AJ;let _nt=Re.BETA;function IJ(n){return Oe(_nt,n)}const ynt=IJ;let vnt=Re.BOP;function RJ(n){return Oe(vnt,n)}const Cnt=RJ;let wnt=Re.CCI;function OJ(n){return Oe(wnt,n)}const xnt=OJ;let Snt=Re.CDL2CROWS;function FJ(n){return Oe(Snt,n)}const Dnt=FJ;let Nnt=Re.CDL3BLACKCROWS;function PJ(n){return Oe(Nnt,n)}const Ent=PJ;let knt=Re.CDL3INSIDE;function BJ(n){return Oe(knt,n)}const Lnt=BJ;let Mnt=Re.CDL3LINESTRIKE;function VJ(n){return Oe(Mnt,n)}const Tnt=VJ;let Ant=Re.CDL3OUTSIDE;function zJ(n){return Oe(Ant,n)}const Int=zJ;let Rnt=Re.CDL3STARSINSOUTH;function HJ(n){return Oe(Rnt,n)}const Ont=HJ;let Fnt=Re.CDL3WHITESOLDIERS;function jJ(n){return Oe(Fnt,n)}const Pnt=jJ;let Bnt=Re.CDLABANDONEDBABY;function WJ(n){return Oe(Bnt,n)}const Vnt=WJ;let znt=Re.CDLADVANCEBLOCK;function $J(n){return Oe(znt,n)}const Hnt=$J;let jnt=Re.CDLBELTHOLD;function UJ(n){return Oe(jnt,n)}const Wnt=UJ;let $nt=Re.CDLBREAKAWAY;function qJ(n){return Oe($nt,n)}const Unt=qJ;let qnt=Re.CDLCLOSINGMARUBOZU;function KJ(n){return Oe(qnt,n)}const Knt=KJ;let Gnt=Re.CDLCONCEALBABYSWALL;function GJ(n){return Oe(Gnt,n)}const Ynt=GJ;let Qnt=Re.CDLCOUNTERATTACK;function YJ(n){return Oe(Qnt,n)}const Znt=YJ;let Xnt=Re.CDLDARKCLOUDCOVER;function QJ(n){return Oe(Xnt,n)}const Jnt=QJ;let eit=Re.CDLDOJI;function ZJ(n){return Oe(eit,n)}const tit=ZJ;let nit=Re.CDLDOJISTAR;function XJ(n){return Oe(nit,n)}const iit=XJ;let rit=Re.CDLDRAGONFLYDOJI;function JJ(n){return Oe(rit,n)}const oit=JJ;let sit=Re.CDLENGULFING;function eee(n){return Oe(sit,n)}const ait=eee;let lit=Re.CDLEVENINGDOJISTAR;function tee(n){return Oe(lit,n)}const uit=tee;let cit=Re.CDLEVENINGSTAR;function nee(n){return Oe(cit,n)}const dit=nee;let hit=Re.CDLGAPSIDESIDEWHITE;function iee(n){return Oe(hit,n)}const fit=iee;let pit=Re.CDLGRAVESTONEDOJI;function ree(n){return Oe(pit,n)}const git=ree;let mit=Re.CDLHAMMER;function oee(n){return Oe(mit,n)}const bit=oee;let _it=Re.CDLHANGINGMAN;function see(n){return Oe(_it,n)}const yit=see;let vit=Re.CDLHARAMI;function aee(n){return Oe(vit,n)}const Cit=aee;let wit=Re.CDLHARAMICROSS;function lee(n){return Oe(wit,n)}const xit=lee;let Sit=Re.CDLHIGHWAVE;function uee(n){return Oe(Sit,n)}const Dit=uee;let Nit=Re.CDLHIKKAKE;function cee(n){return Oe(Nit,n)}const Eit=cee;let kit=Re.CDLHIKKAKEMOD;function dee(n){return Oe(kit,n)}const Lit=dee;let Mit=Re.CDLHOMINGPIGEON;function hee(n){return Oe(Mit,n)}const Tit=hee;let Ait=Re.CDLIDENTICAL3CROWS;function fee(n){return Oe(Ait,n)}const Iit=fee;let Rit=Re.CDLINNECK;function pee(n){return Oe(Rit,n)}const Oit=pee;let Fit=Re.CDLINVERTEDHAMMER;function gee(n){return Oe(Fit,n)}const Pit=gee;let Bit=Re.CDLKICKING;function mee(n){return Oe(Bit,n)}const Vit=mee;let zit=Re.CDLKICKINGBYLENGTH;function bee(n){return Oe(zit,n)}const Hit=bee;let jit=Re.CDLLADDERBOTTOM;function _ee(n){return Oe(jit,n)}const Wit=_ee;let $it=Re.CDLLONGLEGGEDDOJI;function yee(n){return Oe($it,n)}const Uit=yee;let qit=Re.CDLLONGLINE;function vee(n){return Oe(qit,n)}const Kit=vee;let Git=Re.CDLMARUBOZU;function Cee(n){return Oe(Git,n)}const Yit=Cee;let Qit=Re.CDLMATCHINGLOW;function wee(n){return Oe(Qit,n)}const Zit=wee;let Xit=Re.CDLMATHOLD;function xee(n){return Oe(Xit,n)}const Jit=xee;let ert=Re.CDLMORNINGDOJISTAR;function See(n){return Oe(ert,n)}const trt=See;let nrt=Re.CDLMORNINGSTAR;function Dee(n){return Oe(nrt,n)}const irt=Dee;let rrt=Re.CDLONNECK;function Nee(n){return Oe(rrt,n)}const ort=Nee;let srt=Re.CDLPIERCING;function Eee(n){return Oe(srt,n)}const art=Eee;let lrt=Re.CDLRICKSHAWMAN;function kee(n){return Oe(lrt,n)}const urt=kee;let crt=Re.CDLRISEFALL3METHODS;function Lee(n){return Oe(crt,n)}const drt=Lee;let hrt=Re.CDLSEPARATINGLINES;function Mee(n){return Oe(hrt,n)}const frt=Mee;let prt=Re.CDLSHOOTINGSTAR;function Tee(n){return Oe(prt,n)}const grt=Tee;let mrt=Re.CDLSHORTLINE;function Aee(n){return Oe(mrt,n)}const brt=Aee;let _rt=Re.CDLSPINNINGTOP;function Iee(n){return Oe(_rt,n)}const yrt=Iee;let vrt=Re.CDLSTALLEDPATTERN;function Ree(n){return Oe(vrt,n)}const Crt=Ree;let wrt=Re.CDLSTICKSANDWICH;function Oee(n){return Oe(wrt,n)}const xrt=Oee;let Srt=Re.CDLTAKURI;function Fee(n){return Oe(Srt,n)}const Drt=Fee;let Nrt=Re.CDLTASUKIGAP;function Pee(n){return Oe(Nrt,n)}const Ert=Pee;let krt=Re.CDLTHRUSTING;function Bee(n){return Oe(krt,n)}const Lrt=Bee;let Mrt=Re.CDLTRISTAR;function Vee(n){return Oe(Mrt,n)}const Trt=Vee;let Art=Re.CDLUNIQUE3RIVER;function zee(n){return Oe(Art,n)}const Irt=zee;let Rrt=Re.CDLUPSIDEGAP2CROWS;function Hee(n){return Oe(Rrt,n)}const Ort=Hee;let Frt=Re.CDLXSIDEGAP3METHODS;function jee(n){return Oe(Frt,n)}const Prt=jee;let Brt=Re.CEIL;function Wee(n){return Oe(Brt,n)}const Vrt=Wee;let zrt=Re.CMO;function $ee(n){return Oe(zrt,n)}const Hrt=$ee;let jrt=Re.CORREL;function Uee(n){return Oe(jrt,n)}const Wrt=Uee;let $rt=Re.COS;function qee(n){return Oe($rt,n)}const Urt=qee;let qrt=Re.COSH;function Kee(n){return Oe(qrt,n)}const Krt=Kee;let Grt=Re.DEMA;function Gee(n){return Oe(Grt,n)}const Yrt=Gee;let Qrt=Re.DIV;function Yee(n){return Oe(Qrt,n)}const Zrt=Yee;let Xrt=Re.DX;function Qee(n){return Oe(Xrt,n)}const Jrt=Qee;let eot=Re.EMA;function Zee(n){return Oe(eot,n)}const tot=Zee;let not=Re.EXP;function Xee(n){return Oe(not,n)}const iot=Xee;let rot=Re.FLOOR;function Jee(n){return Oe(rot,n)}const oot=Jee;let sot=Re.HT_DCPERIOD;function ete(n){return Oe(sot,n)}const aot=ete;let lot=Re.HT_DCPHASE;function tte(n){return Oe(lot,n)}const uot=tte;let cot=Re.HT_PHASOR;function nte(n){return Oe(cot,n)}const dot=nte;let hot=Re.HT_SINE;function ite(n){return Oe(hot,n)}const fot=ite;let pot=Re.HT_TRENDLINE;function rte(n){return Oe(pot,n)}const got=rte;let mot=Re.HT_TRENDMODE;function ote(n){return Oe(mot,n)}const bot=ote;let _ot=Re.IMI;function ste(n){return Oe(_ot,n)}const yot=ste;let vot=Re.KAMA;function ate(n){return Oe(vot,n)}const Cot=ate;let wot=Re.LINEARREG;function lte(n){return Oe(wot,n)}const xot=lte;let Sot=Re.LINEARREG_ANGLE;function ute(n){return Oe(Sot,n)}const Dot=ute;let Not=Re.LINEARREG_INTERCEPT;function cte(n){return Oe(Not,n)}const Eot=cte;let kot=Re.LINEARREG_SLOPE;function dte(n){return Oe(kot,n)}const Lot=dte;let Mot=Re.LN;function hte(n){return Oe(Mot,n)}const Tot=hte;let Aot=Re.LOG10;function fte(n){return Oe(Aot,n)}const Iot=fte;let Rot=Re.MA;function pte(n){return Oe(Rot,n)}const Oot=pte;let Fot=Re.MACD;function gte(n){return Oe(Fot,n)}const Pot=gte;let Bot=Re.MACDEXT;function mte(n){return Oe(Bot,n)}const Vot=mte;let zot=Re.MACDFIX;function bte(n){return Oe(zot,n)}const Hot=bte;let jot=Re.MAMA;function _te(n){return Oe(jot,n)}const Wot=_te;let $ot=Re.MAVP;function yte(n){return Oe($ot,n)}const Uot=yte;let qot=Re.MAX;function vte(n){return Oe(qot,n)}const Kot=vte;let Got=Re.MAXINDEX;function Cte(n){return Oe(Got,n)}const Yot=Cte;let Qot=Re.MEDPRICE;function wte(n){return Oe(Qot,n)}const Zot=wte;let Xot=Re.MFI;function xte(n){return Oe(Xot,n)}const Jot=xte;let est=Re.MIDPOINT;function Ste(n){return Oe(est,n)}const tst=Ste;let nst=Re.MIDPRICE;function Dte(n){return Oe(nst,n)}const ist=Dte;let rst=Re.MIN;function Nte(n){return Oe(rst,n)}const ost=Nte;let sst=Re.MININDEX;function Ete(n){return Oe(sst,n)}const ast=Ete;let lst=Re.MINMAX;function kte(n){return Oe(lst,n)}const ust=kte;let cst=Re.MINMAXINDEX;function Lte(n){return Oe(cst,n)}const dst=Lte;let hst=Re.MINUS_DI;function Mte(n){return Oe(hst,n)}const fst=Mte;let pst=Re.MINUS_DM;function Tte(n){return Oe(pst,n)}const gst=Tte;let mst=Re.MOM;function Ate(n){return Oe(mst,n)}const bst=Ate;let _st=Re.MULT;function Ite(n){return Oe(_st,n)}const yst=Ite;let vst=Re.NATR;function Rte(n){return Oe(vst,n)}const Cst=Rte;let wst=Re.OBV;function Ote(n){return Oe(wst,n)}const xst=Ote;let Sst=Re.PLUS_DI;function Fte(n){return Oe(Sst,n)}const Dst=Fte;let Nst=Re.PLUS_DM;function Pte(n){return Oe(Nst,n)}const Est=Pte;let kst=Re.PPO;function Bte(n){return Oe(kst,n)}const Lst=Bte;let Mst=Re.ROC;function Vte(n){return Oe(Mst,n)}const Tst=Vte;let Ast=Re.ROCP;function zte(n){return Oe(Ast,n)}const Ist=zte;let Rst=Re.ROCR;function Hte(n){return Oe(Rst,n)}const Ost=Hte;let Fst=Re.ROCR100;function jte(n){return Oe(Fst,n)}const Pst=jte;let Bst=Re.RSI;function Wte(n){return Oe(Bst,n)}const Vst=Wte;let zst=Re.SAR;function $te(n){return Oe(zst,n)}const Hst=$te;let jst=Re.SAREXT;function Ute(n){return Oe(jst,n)}const Wst=Ute;let $st=Re.SIN;function qte(n){return Oe($st,n)}const Ust=qte;let qst=Re.SINH;function Kte(n){return Oe(qst,n)}const Kst=Kte;let Gst=Re.SMA;function Gte(n){return Oe(Gst,n)}const Yst=Gte;let Qst=Re.SQRT;function Yte(n){return Oe(Qst,n)}const Zst=Yte;let Xst=Re.STDDEV;function Qte(n){return Oe(Xst,n)}const Jst=Qte;let eat=Re.STOCH;function Zte(n){return Oe(eat,n)}const tat=Zte;let nat=Re.STOCHF;function Xte(n){return Oe(nat,n)}const iat=Xte;let rat=Re.STOCHRSI;function Jte(n){return Oe(rat,n)}const oat=Jte;let sat=Re.SUB;function ene(n){return Oe(sat,n)}const aat=ene;let lat=Re.SUM;function tne(n){return Oe(lat,n)}const uat=tne;let cat=Re.T3;function nne(n){return Oe(cat,n)}const dat=nne;let hat=Re.TAN;function ine(n){return Oe(hat,n)}const fat=ine;let pat=Re.TANH;function rne(n){return Oe(pat,n)}const gat=rne;let mat=Re.TEMA;function one(n){return Oe(mat,n)}const bat=one;let _at=Re.TRANGE;function sne(n){return Oe(_at,n)}const yat=sne;let vat=Re.TRIMA;function ane(n){return Oe(vat,n)}const Cat=ane;let wat=Re.TRIX;function lne(n){return Oe(wat,n)}const xat=lne;let Sat=Re.TSF;function une(n){return Oe(Sat,n)}const Dat=une;let Nat=Re.TYPPRICE;function cne(n){return Oe(Nat,n)}const Eat=cne;let kat=Re.ULTOSC;function dne(n){return Oe(kat,n)}const Lat=dne;let Mat=Re.VAR;function hne(n){return Oe(Mat,n)}const Tat=hne;let Aat=Re.WCLPRICE;function fne(n){return Oe(Aat,n)}const Iat=fne;let Rat=Re.WILLR;function pne(n){return Oe(Rat,n)}const Oat=pne;let Fat=Re.WMA;function gne(n){return Oe(Fat,n)}const i5=Object.freeze(Object.defineProperty({__proto__:null,ACCBANDS:bJ,ACOS:_J,AD:yJ,ADD:vJ,ADOSC:CJ,ADX:wJ,ADXR:xJ,APO:SJ,AROON:DJ,AROONOSC:NJ,ASIN:EJ,ATAN:kJ,ATR:LJ,AVGDEV:MJ,AVGPRICE:TJ,BBANDS:AJ,BETA:IJ,BOP:RJ,CCI:OJ,CDL2CROWS:FJ,CDL3BLACKCROWS:PJ,CDL3INSIDE:BJ,CDL3LINESTRIKE:VJ,CDL3OUTSIDE:zJ,CDL3STARSINSOUTH:HJ,CDL3WHITESOLDIERS:jJ,CDLABANDONEDBABY:WJ,CDLADVANCEBLOCK:$J,CDLBELTHOLD:UJ,CDLBREAKAWAY:qJ,CDLCLOSINGMARUBOZU:KJ,CDLCONCEALBABYSWALL:GJ,CDLCOUNTERATTACK:YJ,CDLDARKCLOUDCOVER:QJ,CDLDOJI:ZJ,CDLDOJISTAR:XJ,CDLDRAGONFLYDOJI:JJ,CDLENGULFING:eee,CDLEVENINGDOJISTAR:tee,CDLEVENINGSTAR:nee,CDLGAPSIDESIDEWHITE:iee,CDLGRAVESTONEDOJI:ree,CDLHAMMER:oee,CDLHANGINGMAN:see,CDLHARAMI:aee,CDLHARAMICROSS:lee,CDLHIGHWAVE:uee,CDLHIKKAKE:cee,CDLHIKKAKEMOD:dee,CDLHOMINGPIGEON:hee,CDLIDENTICAL3CROWS:fee,CDLINNECK:pee,CDLINVERTEDHAMMER:gee,CDLKICKING:mee,CDLKICKINGBYLENGTH:bee,CDLLADDERBOTTOM:_ee,CDLLONGLEGGEDDOJI:yee,CDLLONGLINE:vee,CDLMARUBOZU:Cee,CDLMATCHINGLOW:wee,CDLMATHOLD:xee,CDLMORNINGDOJISTAR:See,CDLMORNINGSTAR:Dee,CDLONNECK:Nee,CDLPIERCING:Eee,CDLRICKSHAWMAN:kee,CDLRISEFALL3METHODS:Lee,CDLSEPARATINGLINES:Mee,CDLSHOOTINGSTAR:Tee,CDLSHORTLINE:Aee,CDLSPINNINGTOP:Iee,CDLSTALLEDPATTERN:Ree,CDLSTICKSANDWICH:Oee,CDLTAKURI:Fee,CDLTASUKIGAP:Pee,CDLTHRUSTING:Bee,CDLTRISTAR:Vee,CDLUNIQUE3RIVER:zee,CDLUPSIDEGAP2CROWS:Hee,CDLXSIDEGAP3METHODS:jee,CEIL:Wee,CMO:$ee,CORREL:Uee,COS:qee,COSH:Kee,DEMA:Gee,DIV:Yee,DX:Qee,EMA:Zee,EXP:Xee,FLOOR:Jee,HT_DCPERIOD:ete,HT_DCPHASE:tte,HT_PHASOR:nte,HT_SINE:ite,HT_TRENDLINE:rte,HT_TRENDMODE:ote,IMI:ste,KAMA:ate,LINEARREG:lte,LINEARREG_ANGLE:ute,LINEARREG_INTERCEPT:cte,LINEARREG_SLOPE:dte,LN:hte,LOG10:fte,MA:pte,MACD:gte,MACDEXT:mte,MACDFIX:bte,MAMA:_te,get MAType(){return JE},MAVP:yte,MAX:vte,MAXINDEX:Cte,MEDPRICE:wte,MFI:xte,MIDPOINT:Ste,MIDPRICE:Dte,MIN:Nte,MININDEX:Ete,MINMAX:kte,MINMAXINDEX:Lte,MINUS_DI:Mte,MINUS_DM:Tte,MOM:Ate,MULT:Ite,NATR:Rte,OBV:Ote,PLUS_DI:Fte,PLUS_DM:Pte,PPO:Bte,ROC:Vte,ROCP:zte,ROCR:Hte,ROCR100:jte,RSI:Wte,SAR:$te,SAREXT:Ute,SIN:qte,SINH:Kte,SMA:Gte,SQRT:Yte,STDDEV:Qte,STOCH:Zte,STOCHF:Xte,STOCHRSI:Jte,SUB:ene,SUM:tne,T3:nne,TAN:ine,TANH:rne,TEMA:one,TRANGE:sne,TRIMA:ane,TRIX:lne,TSF:une,TYPPRICE:cne,ULTOSC:dne,VAR:hne,WCLPRICE:fne,WILLR:pne,WMA:gne,accBands:Htt,acos:Wtt,ad:Utt,adOsc:Ytt,add:Ktt,adx:Ztt,adxr:Jtt,apo:tnt,aroon:int,aroonOsc:ont,asin:ant,atan:unt,atr:dnt,avgDev:fnt,avgPrice:gnt,bbands:bnt,beta:ynt,bop:Cnt,cci:xnt,cdl2Crows:Dnt,cdl3BlackCrows:Ent,cdl3Inside:Lnt,cdl3LineStrike:Tnt,cdl3Outside:Int,cdl3StarsInSouth:Ont,cdl3WhiteSoldiers:Pnt,cdlAbandonedBaby:Vnt,cdlAdvanceBlock:Hnt,cdlBeltHold:Wnt,cdlBreakaway:Unt,cdlClosingMarubozu:Knt,cdlConcealBabysWall:Ynt,cdlCounterAttack:Znt,cdlDarkCloudCover:Jnt,cdlDoji:tit,cdlDojiStar:iit,cdlDragonflyDoji:oit,cdlEngulfing:ait,cdlEveningDojiStar:uit,cdlEveningStar:dit,cdlGapSideSideWhite:fit,cdlGravestoneDoji:git,cdlHammer:bit,cdlHangingMan:yit,cdlHarami:Cit,cdlHaramiCross:xit,cdlHignWave:Dit,cdlHikkake:Eit,cdlHikkakeMod:Lit,cdlHomingPigeon:Tit,cdlIdentical3Crows:Iit,cdlInNeck:Oit,cdlInvertedHammer:Pit,cdlKicking:Vit,cdlKickingByLength:Hit,cdlLadderBottom:Wit,cdlLongLeggedDoji:Uit,cdlLongLine:Kit,cdlMarubozu:Yit,cdlMatHold:Jit,cdlMatchingLow:Zit,cdlMorningDojiStar:trt,cdlMorningStar:irt,cdlOnNeck:ort,cdlPiercing:art,cdlRickshawMan:urt,cdlRiseFall3Methods:drt,cdlSeperatingLines:frt,cdlShootingStar:grt,cdlShortLine:brt,cdlSpinningTop:yrt,cdlStalledPattern:Crt,cdlStickSandwhich:xrt,cdlTakuri:Drt,cdlTasukiGap:Ert,cdlThrusting:Lrt,cdlTristar:Trt,cdlUnique3River:Irt,cdlUpsideGap2Crows:Ort,cdlXSideGap3Methods:Prt,ceil:Vrt,cmo:Hrt,correl:Wrt,cos:Urt,cosh:Krt,dema:Yrt,div:Zrt,dx:Jrt,ema:tot,exp:iot,floor:oot,htDcPeriod:aot,htDcPhase:uot,htPhasor:dot,htSine:fot,htTrendMode:bot,htTrendline:got,imi:yot,init:ek,kama:Cot,linearReg:xot,linearRegAngle:Dot,linearRegIntercept:Eot,linearRegSlope:Lot,ln:Tot,log10:Iot,macd:Pot,macdExt:Vot,macdFix:Hot,mama:Wot,max:Kot,maxIndex:Yot,medPrice:Zot,mfi:Jot,midPoint:tst,midPrice:ist,min:ost,minIndex:ast,minMax:ust,minMaxIndex:dst,minusDI:fst,minusDM:gst,mom:bst,movingAverage:Oot,movingAverageVariablePeriod:Uot,mult:yst,natr:Cst,obv:xst,plusDI:Dst,plusDM:Est,ppo:Lst,roc:Tst,rocP:Ist,rocR:Ost,rocR100:Pst,rsi:Vst,sar:Hst,sarExt:Wst,sin:Ust,sinh:Kst,sma:Yst,sqrt:Zst,stdDev:Jst,stoch:tat,stochF:iat,stochRsi:oat,sub:aat,sum:uat,t3:dat,tan:fat,tanh:gat,tema:bat,trima:Cat,trix:xat,trueRange:yat,tsf:Dat,typPrice:Eat,ultOsc:Lat,variance:Tat,wclPrice:Iat,willR:Oat,wma:gne},Symbol.toStringTag,{value:"Module"}));let mne=!1,bne=!0,_ne=[];const yne=n=>{const e=[],t=[],i=[],r=[],o=[],s=[];return n.forEach((a,l)=>{e.push(a[0]),t.push(a[1]),i.push(a[4]),r.push(a[2]),o.push(a[3]),s.push([a[1],a[4],a[3],a[2],Number(a[6]),l===0?a[4]:n[l-1][4]])}),{time:e,open:t,close:i,high:r,low:o,kLineData:s}},Pat=async()=>{if(!mne)mne=!0,await ek("./talib.wasm"),bne=!1,_ne.forEach(n=>{n()});else if(bne)return new Promise(n=>{_ne.push(n)})},p_=(n,e)=>n.length>e?n.slice(n.length-e):n,Bat=(n,e,t)=>n.calculationFn?n.calculationFn(i5,e,t):new Array(e.time.length).fill(null),Vat=async(n,e,t)=>{const i=yne(n);let r=[];return r=yne(r),await Pat(),{originData:p_(n,t),kLine:p_(i.kLineData,t),time:p_(i.time,t),indicator:e.config.reduce((o,s)=>(o.push({key:s.key,color:s.color,data:p_(Bat(s,i,r),t)}),o),[])}},tk="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjM4NzI1IiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjI2MjUiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNGRjAwMDAiIHAtaWQ9IjI2MjYiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjcwOTMzMyAxNjcuNzIyNjY3YzAuMTI4LTIxLjc2IDkuOTg0LTQyLjY2NjY2NyAyNy4zOTItNTcuOTQxMzM0YTkzLjMxMiA5My4zMTIgMCAwIDEgNjQuNDY5MzM0LTIzLjg5MzMzM0w3NjEuNiA4NS4zMzMzMzNjMjUuNiAwLjU1NDY2NyA0Ny4zNiA4Ljc4OTMzMyA2NC45Mzg2NjcgMjQuNDA1MzM0IDE3LjkyIDE2IDI2Ljg4IDM1LjIgMjYuODggNTcuNDcybC0wLjU1NDY2NyA0MTkuODRjMC4yOTg2NjcgMjIuNjk4NjY3LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuOTIyNjY2LTEyLjYyOTMzMyAyNy4zMDY2NjctMjcuOTQ2NjY3IDQ4Ljg5Ni00NS44MjQgNjQuODk2bC0yMTEuMjQyNjY3IDE4OC4yMDI2NjdjLTE3LjU3ODY2NyAxNS43MDEzMzMtMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45Mzg2NjcgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0Ljk4MTMzMy0yMy41OTQ2NjdsLTIxMS4xNTczMzMtMTg4LjE2Yy0xNy45Mi0xNi4wNDI2NjctMzMuMjgtMzcuNzE3MzMzLTQ1LjkwOTMzNC02NC45ODEzMzMtMTIuNjcyLTI3LjMwNjY2Ny0xOS4wMjkzMzMtNTIuMzk0NjY3LTE5LjAyOTMzMy03NS4zMDY2NjdMMTcwLjY2NjY2NyAxNjcuNzIyNjY3eiBtNDIuNjY2NjY3IDAuMjU2bDAuNTU0NjY3IDQxOC42ODhjMCAxNi4yMTMzMzMgNC44MjEzMzMgMzUuMzI4IDE1LjAxODY2NiA1Ny4zNDQgMTAuMzY4IDIyLjI3MiAyMi4zNTczMzMgMzkuMjEwNjY3IDM1LjYyNjY2NyA1MS4wNzJsMjExLjQxMzMzMyAxODguNDE2YzguOTYgOC4xMDY2NjcgMjEuODg4IDEyLjggMzYuMjI0IDEyLjU0NCAxNS41MzA2NjctMC4wNDI2NjcgMjcuMDkzMzMzLTQuMjY2NjY3IDM2LjY5MzMzNC0xMi44bDIxMS4xNTczMzMtMTg4LjExNzMzNGMxMy4zMTItMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNTg0LTUxLjA3MiAxMC4xMTItMjEuODQ1MzMzIDE0Ljc2MjY2Ny00MC41NzYgMTQuNTA2NjY3LTU3LjA0NTMzM2wwLjU1NDY2Ni00MTkuNzU0NjY3YzAtOS44OTg2NjctMy41ODQtMTcuNjIxMzMzLTEyLjQ1ODY2Ni0yNS42YTU0LjY5ODY2NyA1NC42OTg2NjcgMCAwIDAtMzYuNjA4LTEzLjYxMDY2NmwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NyAxMy4zMTIgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzMgMjEuNDYxMzMzbC0wLjQyNjY2NyA0LjY5MzMzNHoiIGZpbGw9IiNBRTAwMDAiIHAtaWQ9IjI2MjciPjwvcGF0aD48cGF0aCBkPSJNMzg0IDY1NC4xMjI2NjdoMTUzLjUxNDY2N2M5Ni43NjggMCAxNDIuNzYyNjY3LTQ4Ljk4MTMzMyAxNDIuNzYyNjY2LTExNy4wNzczMzQgMC01OS43MzMzMzMtMzMuNDUwNjY3LTg4LjQwNTMzMy04NC44MjEzMzMtOTcuOTYyNjY2di0xLjc5MmM0OC45ODEzMzMtMTUuNTMwNjY3IDY2LjkwMTMzMy00Ni41OTIgNjYuOTAxMzMzLTg5LjYgMC02NS4xMDkzMzMtNDAuNjE4NjY3LTEwMy4zMzg2NjctMTM0Ljk5NzMzMy0xMDMuMzM4NjY3SDM4NHY0MDkuNzcwNjY3eiBtNzIuODc0NjY3LTU0Ljk1NDY2N3YtMTMxLjQxMzMzM2g2Ni4zMDRjNTEuOTY4IDAgODAuMDQyNjY3IDE3LjkyIDgwLjA0MjY2NiA2NS4xMDkzMzMgMCA0NC44LTI2LjI4MjY2NyA2Ni4zMDQtNzUuODYxMzMzIDY2LjMwNGgtNzAuNDg1MzMzeiBtMC0xODAuMzk0NjY3VjI5OC43MDkzMzNoNjAuMzMwNjY2YzQ3LjE4OTMzMyAwIDcyLjI3NzMzMyAxNC45MzMzMzMgNzIuMjc3MzM0IDU5LjEzNiAwIDQ2LjU5Mi0zMi4yNTYgNjAuOTI4LTc1LjI2NCA2MC45MjhoLTU3LjM0NHoiIGZpbGw9IiNGRkZGRkYiIHAtaWQ9IjI2MjgiPjwvcGF0aD48L3N2Zz4=",nk="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjQxNjY0IiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjI3NzciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiM1NEFCMzAiIHAtaWQ9IjI3NzgiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiMzODhEMTQiIHAtaWQ9IjI3NzkiPjwvcGF0aD48cGF0aCBkPSJNNTA2LjQ1MzMzMyA2NzQuNzMwNjY3Yzk5LjE1NzMzMyAwIDE0Ni4zNDY2NjctNDguMzg0IDE0Ni4zNDY2NjctMTI2LjAzNzMzNCAwLTcyLjg3NDY2Ny0zOC44MjY2NjctOTkuNzU0NjY3LTEwMy4zMzg2NjctMTE4LjI3MmwtMzguMjI5MzMzLTExLjk0NjY2NmMtNDAuNjE4NjY3LTExLjM0OTMzMy01Mi41NjUzMzMtMjUuMDg4LTUyLjU2NTMzMy01Ny4zNDQgMC0zMi44NTMzMzMgMjMuODkzMzMzLTUwLjc3MzMzMyA2Ni45MDEzMzMtNTAuNzczMzM0IDQ1LjM5NzMzMyAwIDc4Ljg0OCA5LjU1NzMzMyAxMDQuNTMzMzMzIDIwLjMwOTMzNFYyNzMuMzIyNjY3Yy0yMi42OTg2NjctMTEuOTQ2NjY3LTUxLjk2OC0yMi4xMDEzMzMtMTA1LjcyOC0yMi4xMDEzMzQtOTIuNTg2NjY3IDAtMTM3LjM4NjY2NyA0Ny4xODkzMzMtMTM3LjM4NjY2NiAxMTYuNDggMCA2OS4yOTA2NjcgMzUuMjQyNjY3IDEwMC4zNTIgOTMuMTg0IDExNi40OGwzOC44MjY2NjYgMTAuNzUyYzQ0LjggMTMuNzM4NjY3IDU5LjczMzMzMyAyNi44OCA1OS43MzMzMzQgNjAuOTI4IDAgMzcuMDM0NjY3LTIzLjI5NiA1OS43MzMzMzMtNzguMjUwNjY3IDU5LjczMzMzNC00NC44IDAtODMuNjI2NjY3LTEwLjc1Mi0xMTYuNDgtMjUuMDg4djU3Ljk0MTMzM2MyOC4wNzQ2NjcgMTQuOTMzMzMzIDY4LjY5MzMzMyAyNi4yODI2NjcgMTIyLjQ1MzMzMyAyNi4yODI2Njd6IiBmaWxsPSIjRkZGRkZGIiBwLWlkPSIyNzgwIj48L3BhdGg+PC9zdmc+",ik="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjI4MjAyIiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjMwNzgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNDODgwRkYiIHAtaWQ9IjMwNzkiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiNBRTQ0RkYiIHAtaWQ9IjMwODAiPjwvcGF0aD48cGF0aCBkPSJNNDc1LjMwNjY2NyA2NTguMjE4NjY3aDczLjQ3MlYzMDYuMzg5MzMzaDExNi40OFYyNDguNDQ4aC0zMDcuNjI2NjY3djU3Ljk0MTMzM2gxMTcuNjc0NjY3eiIgZmlsbD0iI0ZGRkZGRiIgcC1pZD0iMzA4MSI+PC9wYXRoPjwvc3ZnPg==",r5=(n,e)=>{const{type:t="log",color:i="black"}=e??{};localStorage.getItem("st-kline-console-show")==="true"&&console[t](`%c${n}`,`color:${i}`)},Ao=n=>n||n===0?Math.round(n*1e3)/1e3:null,zat=n=>n>=1e12?`${(n/1e12).toFixed(2)}万亿`:n>=1e8?`${(n/1e8).toFixed(2)}亿`:n>=1e4?`${(n/1e4).toFixed(2)}万`:n.toFixed(2),Hat=n=>{const{y:e,text:t,info:i,gridLeft:r,gridRight:o,echartsWidth:s,echartsInstance:a}=n,{config:l,event:u}=i;let d=0;return{type:"group",draggable:l.draggable?"vertical":!1,children:[{type:"line",info:i,shape:{x1:r,y1:e,x2:s-o,y2:e},style:{stroke:l.lineColor,lineWidth:1,lineDash:[8,4]},z:10},{type:"group",x:s,y:e-5,children:[{type:"text",left:-1*o,info:i,style:{fill:l.textColor,text:t,stroke:"#000",lineWidth:1,opacity:1},z:10}]}],onmouseover:h=>{u.onmouseover instanceof Function&&u.onmouseover(h,i)},onmouseout:h=>{u.onmouseout instanceof Function&&u.onmouseout(h,i)},ondragstart:h=>{u.ondragstart instanceof Function&&l.draggable&&(d=h.offsetY,u.ondragstart(h,i))},ondragend:h=>{if(u.ondragend instanceof Function&&l.draggable){const p=h.offsetY-d;if(p===0)return;const g=a.convertFromPixel({yAxisIndex:0},e+p);u.ondragend(h,i,g)}}}},jat=n=>{const{y:e,text:t,info:i,gridLeft:r,gridRight:o,echartsWidth:s,echartsInstance:a}=n,{config:l,event:u}=i;let d=0;const h=p=>{let g=null;p.target.type==="line"?g=p.target.parent:p.target.type==="tspan"&&(g=p.target.parent.parent.parent),g.children()[1].children()[0].animate("style",!1).when(200,{opacity:1}).start()},f=p=>{let g=null;p.target.type==="line"?g=p.target.parent:p.target.type==="tspan"&&(g=p.target.parent.parent.parent),g.children()[1].children()[0].animate("style",!1).when(200,{opacity:0}).start()};return{type:"group",draggable:l.draggable?"vertical":!1,children:[{type:"line",info:i,shape:{x1:r,y1:e,x2:s-o,y2:e},style:{stroke:l.lineColor,lineWidth:1},z:10},{type:"group",x:s/2,y:e-5,children:[{type:"text",left:"center",info:i,style:{fill:l.textColor,text:t,stroke:"#000",lineWidth:1,opacity:0},z:10}]}],onmouseover:p=>{u.onmouseover instanceof Function?u.onmouseover(p,i):h(p)},onmouseout:p=>{u.onmouseout instanceof Function?u.onmouseout(p,i):f(p)},ondragstart:p=>{u.ondragstart instanceof Function&&l.draggable&&(d=p.offsetY,u.ondragstart(p,i))},ondragend:p=>{if(u.ondragend instanceof Function&&l.draggable){const m=p.offsetY-d;if(m===0)return;const _=a.convertFromPixel({yAxisIndex:0},e+m);u.ondragend(p,i,_)}}}},Wat=n=>{const{y:e,text:t,profitY:i,profitText:r,lossY:o,lossText:s,info:a,gridLeft:l,gridRight:u,echartsWidth:d,echartsInstance:h}=n,{config:f,event:p}=a;let g=0,m=null,_=null;const b=(v,w)=>{var x,S,N,D;(x=v.children()[2])==null||x.animate("style",!1).when(200,{opacity:~~w}).start(),(S=v.children()[3].children()[0])==null||S.animate("style",!1).when(200,{opacity:~~w}).start(),(N=v.children()[4])==null||N.animate("style",!1).when(200,{opacity:~~w}).start(),(D=v.children()[5].children()[0])==null||D.animate("style",!1).when(200,{opacity:~~w}).start()},C=v=>{let w=null;v.target.type==="line"?w=v.target.parent:v.target.type==="tspan"&&(w=v.target.parent.parent.parent),m=x=>{x.preventDefault(),(x.code==="AltLeft"||x.code==="AltRight")&&b(w,!0)},_=x=>{(x.code==="AltLeft"||x.code==="AltRight")&&b(w,!1)},window.addEventListener("keydown",m),window.addEventListener("keyup",_)},y=v=>{let w=null;v.target.type==="line"?w=v.target.parent:v.target.type==="tspan"&&(w=v.target.parent.parent.parent),b(w,!1),window.removeEventListener("keydown",m),window.removeEventListener("keyup",_)};return{type:"group",draggable:f.draggable?"vertical":!1,children:[{type:"line",info:a,shape:{x1:l,y1:e,x2:d-u,y2:e},style:{stroke:f.lineColor,lineWidth:1},z:10},{type:"group",x:d/2,y:e-5,children:[{type:"text",left:"center",info:a,style:{fill:f.textColor,text:t,stroke:"#000",lineWidth:1,opacity:1},z:10}]},{type:"line",info:a,shape:{x1:l,y1:i,x2:d-u,y2:i},style:{stroke:f.profitLineColor,lineWidth:1,lineDash:[8,4],opacity:0},z:10},{type:"group",x:d/2,y:i-5,children:[{type:"text",left:"center",info:a,style:{fill:f.profitTextColor,text:r,stroke:"#000",lineWidth:1,opacity:0},z:10}]},{type:"line",info:a,shape:{x1:l,y1:o,x2:d-u,y2:o},style:{stroke:f.lossLineColor,lineWidth:1,lineDash:[8,4],opacity:0},z:10},{type:"group",x:d/2,y:o-5,children:[{type:"text",left:"center",info:a,style:{fill:f.lossTextColor,text:s,stroke:"#000",lineWidth:1,opacity:0},z:10}]}],onmouseover:v=>{p.onmouseover instanceof Function?p.onmouseover(v,a):C(v)},onmouseout:v=>{p.onmouseout instanceof Function?p.onmouseout(v,a):y(v)},ondragstart:v=>{p.ondragstart instanceof Function&&f.draggable&&(g=v.offsetY,p.ondragstart(v,a))},ondragend:v=>{if(p.ondragend instanceof Function&&f.draggable){const x=v.offsetY-g;if(x===0)return;const S=h.convertFromPixel({yAxisIndex:0},e+x);p.ondragend(v,a,S)}}}},g_=(n,e)=>{const{direction:t="",tradeAction:i="",tradeType:r=""}=n;if(e==="sellBuy"){const o=r??t+i;return new Map([["开多","买"],["平多","卖"],["开空","卖"],["平空","买"]]).get(o)}else if(e==="openClose")return r??t+i},$at=(n,e)=>n.reduce((t,i)=>{var d;const r=g_(i,"sellBuy"),o=n.filter(h=>h.time===i.time);let s="image://"+new URL(Object.assign({"./images/buy.svg":tk,"./images/sell.svg":nk,"./images/t.svg":ik})[`./images/${r==="买"?"buy":"sell"}.svg`],self.location).href;o.length>1?[...new Set(o.map(f=>g_(f,"sellBuy")))].length>1?s="image://"+new URL("data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjI4MjAyIiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjMwNzgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNDODgwRkYiIHAtaWQ9IjMwNzkiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiNBRTQ0RkYiIHAtaWQ9IjMwODAiPjwvcGF0aD48cGF0aCBkPSJNNDc1LjMwNjY2NyA2NTguMjE4NjY3aDczLjQ3MlYzMDYuMzg5MzMzaDExNi40OFYyNDguNDQ4aC0zMDcuNjI2NjY3djU3Ljk0MTMzM2gxMTcuNjc0NjY3eiIgZmlsbD0iI0ZGRkZGRiIgcC1pZD0iMzA4MSI+PC9wYXRoPjwvc3ZnPg==",self.location).href:s="image://"+new URL(Object.assign({"./images/buy.svg":tk,"./images/sell.svg":nk,"./images/t.svg":ik})[`./images/${r==="买"?"buy":"sell"}.svg`],self.location).href:s="image://"+new URL(Object.assign({"./images/buy.svg":tk,"./images/sell.svg":nk,"./images/t.svg":ik})[`./images/${r==="买"?"buy":"sell"}.svg`],self.location).href;const l=(e.find(h=>h[0]===i.time)??[])[2],u=((d=i==null?void 0:i.markLineTarget)==null?void 0:d.map(h=>{const f=i.time,p=l+"",g=h.time,m=e.find(b=>b[0]===h.time),_=m?m[3]:null;return[{coord:[f,p],lineStyle:h.lineStyle},{coord:[g,_]}]}))??null;return t.push({symbol:s,symbolSize:25,animation:!1,coord:[i.time+"",l],symbolRotate:0,symbolOffset:[0,"-7"],markLineTarget:u}),t},[]),Uat=(n,e)=>n.reduce((t,i,r)=>{var h;const o=g_(i,"openClose"),s=o==="开多"||o==="开空"?"top":"bottom",a=e.find(f=>f[0]===i.time)??[],l=s==="top"?a[2]:a[3];let u=7;u+=n.slice(0,r).filter(f=>{const p=g_(f,"openClose");return(p==="开多"||p==="开空"?"top":"bottom")===s&&f.time===i.time}).length*7;const d=((h=i==null?void 0:i.markLineTarget)==null?void 0:h.map(f=>{const p=i.time,g=l+"",m=f.time,_=e.find(b=>b[0]===f.time)[3];return[{coord:[p,g],lineStyle:f.lineStyle},{coord:[m,_]}]}))??null;return t.push({symbol:"triangle",symbolSize:[10,12],animation:!1,coord:[i.time+"",l],symbolRotate:s==="top"?180:0,symbolOffset:[0,`${s==="top"?u*-1:u}`],itemStyle:{color:s==="top"?"#FF0000":"#389e0d"},label:{show:!0,position:s,color:"#fff",formatter:`${o} ${s==="top"?"+":"-"} ${i.amount}手 ${i.part?`(${i.part}份)`:""}`},markLineTarget:d}),t},[]),qat=(n,e)=>n.reduce((t,i)=>{const{key:r,data:o}=i;if(o===null||o.length===0)return t;const a=new Map([["sellBuy",()=>$at(o,e)],["openClose",()=>Uat(o,e)],["signal",()=>{}]]).get(r);return a instanceof Function&&t.push(...a()),t},[]),rk=async(n,e,t,i,r,o)=>{const{totalBarCount:s,defaultShowBarCount:a,maxValueSpan:l,gridLeft:u,gridTop:d,gridRight:h,gridBottom:f,zoomLock:p}=i,{time:g,kLine:m,originData:_,indicator:b}=await Vat(n,t,s),C=b.map(w=>{const{key:x,data:S,color:N}=w;return{name:x,type:"line",silent:!0,symbol:"none",data:S,lineStyle:{width:1},itemStyle:{color:N}}}),y=qat(e,_);let v=[];return y.forEach(w=>{w.markLineTarget&&(v=[...v,...w.markLineTarget])}),{animation:!1,dataset:{id:"data",source:{klineData:m,indicatorData:b}},grid:{left:`${u}px`,top:`${d}px`,right:`${h}px`,bottom:`${f}px`},tooltip:{trigger:"axis",axisPointer:{type:"cross",label:{formatter:w=>{const{axisDimension:x,value:S}=w;return x==="x"?S:String(Ao(S))}}},formatter:w=>{let x=null,S="";return w.forEach(N=>{N.seriesName==="资产持仓净值"&&N.data!==null&&(S+=`<div>资产持仓净值: ${N.data}</div>`),N.componentSubType==="candlestick"&&e.forEach(D=>{const{key:L,data:E}=D;if(L==="sellBuy"){const k=E.filter(B=>B.time===N.axisValue);let A=0,R=0;k.forEach(B=>{B.tradeType==="开多"||B.tradeType==="平空"?A+=B.amount:R+=B.amount}),A&&(S+=`<div>买: ${A}</div>`),R&&(S+=`<div>卖: ${R}</div>`)}L==="openClose"&&E.forEach(k=>{k.time===N.axisValue&&(S+=k.tooltip)})}),S&&(x=`<div><span style="font-weight: bold;">${N.axisValue}</span>${S}</div>`)}),x}},xAxis:{type:"category",data:g,axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}},axisLabel:{show:!0,formatter:w=>w}},yAxis:[{index:0,splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}},min:w=>{const{min:x,max:S}=w,N=Math.abs((S-x)/10);return x-N},max:w=>{const{min:x,max:S}=w,N=Math.abs((S-x)/10);return S+N},axisLine:{show:!0},axisLabel:{formatter:w=>Ao(w),showMaxLabel:!1}},{show:!1,min:"dataMin"}],dataZoom:[{type:"inside",xAxisIndex:[0,0],zoomLock:p,maxValueSpan:l,start:m.length>=a?(m.length-a)/m.length*100:0,end:99.99}],series:[{name:"k线",type:"candlestick",data:m,markPoint:{data:y},markLine:{position:"middle",textStyle:{color:"blue",fontSize:15},animation:!1,data:v,lineStyle:{width:3,type:"solid"},symbol:["none","none"]},itemStyle:{color:"transparent",color0:"#00FFFF",borderColor:"#FF0000",borderColor0:"#00FFFF",borderWidth:1},z:1},...C,{name:"资产持仓净值",type:"line",data:r??[],symbol:"none",yAxisIndex:1,connectNulls:!0,itemStyle:{color:"#666"}},{name:"二腿相关度",type:"line",data:o??[],symbol:"none",yAxisIndex:1,connectNulls:!0,itemStyle:{color:"#FFF"},lineStyle:{width:2},label:{show:!0,position:"top",formatter:w=>`相关度: ${w.data[1]}`,textStyle:{color:"#FFF",fontSize:14}}}],toolbox:{show:!1},brush:{xAxisIndex:"all",brushLink:"all",transformable:!1,outOfBrush:{colorAlpha:1},brushStyle:{color:"rgba(120,140,180,0)",borderColor:"rgba(255,255,255,0.4)"}}}},Kat=(n,e,t)=>{var h;const{gridLeft:i,gridRight:r,gridBottom:o,warningConfig:s,positionConfig:a,conditionConfig:l,isOpenDS:u}=e;let d=[];if((h=t==null?void 0:t.getModel())!=null&&h.getComponent){const[f,p]=t.getModel().getComponent("yAxis").axis.scale._extent;let g=[],m={},_=[],b={},C=[],y={};if(n.forEach(({key:v,data:w,...x})=>{v==="warning"?(g=w,m=x):v==="position"?(_=w,b=x):v==="condition"&&(C=w,y=x)}),g.length>0&&(d=g.reduce((v,w)=>{const{value:x,text:S,info:N,config:D}=w;if(x>p||x<f)return v;const L={y:t.convertToPixel({yAxisIndex:0},x),text:S,info:{info:N,config:{...s,...D},event:{...m}},gridLeft:i,gridRight:r,echartsWidth:t.getWidth(),echartsInstance:t};return[...v,Hat(L)]},d)),_.length>0&&(d=_.reduce((v,w)=>{const{value:x,text:S,info:N,config:D}=w;if(x>p||x<f)return v;const L={y:t.convertToPixel({yAxisIndex:0},x),text:S,info:{info:N,config:{...a,...D},event:{...b}},gridLeft:i,gridRight:r,echartsWidth:t.getWidth(),echartsInstance:t};return[...v,jat(L)]},d)),C.length>0&&(d=C.reduce((v,w)=>{const{value:x,text:S,profitValue:N,profitText:D,lossValue:L,lossText:E,info:k,config:A}=w;if(x>p||x<f)return v;const R={y:t.convertToPixel({yAxisIndex:0},x),text:S,profitY:t.convertToPixel({yAxisIndex:0},N),profitText:D,lossY:t.convertToPixel({yAxisIndex:0},L),lossText:E,info:{info:k,config:{...l,...A},event:{...y}},gridLeft:i,gridRight:r,echartsWidth:t.getWidth(),echartsInstance:t};return[...v,Wat(R)]},d)),u){const v=t.getOption(),w=v.dataset[0].source.klineData.slice(v.dataZoom[0].startValue,v.dataZoom[0].endValue+1),x={};w.forEach(R=>{x[R[1]]?x[R[1]]+=1:x[R[1]]=1});const S=w[w.length-1][1],N=w.reduce((R,B)=>R+B[1],0)/w.length,D=S-N,L=Yat(w,1,50),E=Qat(w),k=E?D/E:0,A=Gat(w,1,S);d=[...d,{type:"group",draggable:!1,children:Object.keys(x).map(R=>({type:"line",shape:{x1:t.getWidth()-r-100*x[R],y1:t.convertToPixel({yAxisIndex:0},R),x2:t.getWidth()-r,y2:t.convertToPixel({yAxisIndex:0},R)},style:{stroke:"rgb(124,124,124)",lineWidth:1},z:10}))},{type:"text",x:i+6,y:t.getHeight()-o-20,style:{fill:"#FFF",text:`均值: ${Ao(N)}    距均值: ${Ao(D)}    中值: ${Ao(L)}    标准差: ${Ao(E)}    距均值/标准差: ${Ao(k)}    百分位: ${Ao(A)}%`,lineWidth:1,opacity:1},z:10}]}}return{elements:d}},Gat=(n,e,t)=>{const{round:i,add:r,subtract:o,multiply:s,divide:a}=bl,l=n.map(d=>d[e]).sort((d,h)=>d-h);let u=0;for(let d=0;d<l.length;d++)if(l[d]===t){u=d;break}else if(l[d]>=t){u=r(d,a(o(l[d+1],l[d]),l[d]));break}return i(a(s(u,100),n.length+1))},Yat=(n,e,t)=>{const{round:i,add:r,subtract:o,multiply:s,divide:a}=bl,l=n.map(f=>f[e]).sort((f,p)=>f-p),u=s(n.length+1,a(t,100)),d=Math.floor(u),h=o(u,d);return i(h===0?l[u]:r(l[d],s(o(l[d>=n.length-1?d:d+1],l[d]),h)))};function Qat(n){const e=n.map(s=>s[1]),t=e.length;let i=0,r=0;for(const s of e)i+=s;const o=i/t;for(const s of e)r+=Math.pow(s-o,2);return Math.sqrt(r/t)}const Zat={class:"st-kline"},Xat={class:"st-kline-header"},Jat=300,elt=c.defineComponent({__name:"index",props:{indicator:{type:Object,default:()=>({})},klineData:{type:Array,default:()=>[]},markData:{type:Array,default:()=>[]},lineData:{type:Array,default:()=>[]},netPositionData:{type:Array,default:()=>[]},relevanceData:{type:Array,default:()=>[]},priceTrendData:{type:Array,default:()=>[]},priceTrendPercentData:{type:Array,default:()=>[]},brushRange:{type:Array,default:()=>[]},defaultMenuData:{type:Array,default:()=>[]},isSelect:{type:Boolean,default:()=>!1},config:{type:Object,default:()=>({})}},setup(n){const e=n,t={totalBarCount:2e3,defaultShowBarCount:200,preBarCount:800,maxValueSpan:1e4,gridLeft:60,gridTop:0,gridRight:60,gridBottom:30,warningConfig:{draggable:!1,lineColor:"#fff",textColor:"#fff"},positionConfig:{draggable:!1,lineColor:"#e45d07",textColor:"#fff"},conditionConfig:{draggable:!1,lineColor:"#fff",textColor:"#fff",profitLineColor:"#b71e44",profitTextColor:"#fff",lossLineColor:"#749b66",lossTextColor:"#fff"},tipsConfig:{open:!0,heigh:!0,low:!0,close:!0,business:!0,riseAndFall:!0},dynamicLoadConfig:{historyVisible:!1,historyLoadCallBack:()=>{},futureVisible:!1,futureLoadCallBack:()=>{}},zoomLock:!1,isOpenDS:!1},i=c.computed(()=>({...t,...e.config})),r=c.ref(null),o=c.ref(-1),s=c.computed(()=>{var R,B;if(r.value&&((B=(R=r.value.dataset[0])==null?void 0:R.source)!=null&&B.klineData[o.value])){const I=r.value.dataset[0].source.klineData[o.value],M=[],{open:O,heigh:F,low:$,close:Y,business:U,riseAndFall:z}=i.value.tipsConfig;if(O&&M.push({label:"开",value:Ao(I[0]),color:"rgb(153, 153, 153)"}),F&&M.push({label:"高",value:Ao(I[3]),color:"rgb(153, 153, 153)"}),$&&M.push({label:"低",value:Ao(I[2]),color:"rgb(153, 153, 153)"}),Y&&M.push({label:"收",value:Ao(I[1]),color:"rgb(153, 153, 153)"}),U&&M.push({label:"额",value:zat(I[4]),color:"rgb(153, 153, 153)"}),z){let ne=((I[1]-I[5])/I[1]*100).toFixed(2),le=+ne==0?"white":+ne>0?"red":"#00ff00";M.push({label:"涨跌",value:`${ne}%`,color:le})}return M}return[]}),a=c.computed(()=>{var R,B;return r.value&&((B=(R=r.value.dataset[0])==null?void 0:R.source)!=null&&B.indicatorData)?r.value.dataset[0].source.indicatorData.reduce((I,M)=>(M.data[o.value]&&I.push({label:M.key,value:Ao(M.data[o.value]),color:M.color}),I),[]):[]}),l=c.computed(()=>{const R=["#FFFFFF","#FFDD00","#FF00FF","#00FF00","#FF6000","#1677FF","#7C3CC9","#FF0000","#FB9A0E","#00B7FF"];if(e.priceTrendData.length>0){const B=[];return e.priceTrendData.forEach((I,M)=>{var F;(I.data[o.value]?Ao(I.data[o.value][1]):null)!==null&&B.push({label:I.name,value:Ao((F=I.data[o.value])==null?void 0:F[1]),color:R[M]})}),B}if(e.priceTrendPercentData.length>0){const B=[];return m.getOption().series.filter(M=>M.name.includes("二腿价格走势百分比图")).forEach((M,O)=>{var $;(M.data[o.value]?Ao(M.data[o.value][1]):null)!==null&&B.push({label:M.name.split("-")[1],value:`${Ao(($=M.data[o.value])==null?void 0:$[1])}%`,color:R[O]})}),B}return[]});c.watch(()=>[e.klineData,e.indicator,e.markData,e.netPositionData,e.relevanceData],()=>{u()},{deep:!0}),c.watch(()=>e.lineData,async()=>{r5("st-kline组件消息:props.lineData监控,额外画线数据发生改变,重绘->line",{color:"red"}),u("line")},{deep:!0}),c.watch(()=>e.brushRange,async()=>{r5("st-kline组件消息:props.brushRange监控,区域刷选数据发生改变,重绘->brush",{color:"red"}),u("brush")},{deep:!0}),c.watch(()=>e.priceTrendData,async()=>{u("priceTrend")},{deep:!0}),c.watch(()=>e.priceTrendPercentData,async()=>{u("priceTrendPercent")},{deep:!0});const u=async R=>{const I=new Map([["kline",async()=>{const M=await rk(e.klineData,e.markData,e.indicator,i.value,e.netPositionData,e.relevanceData),{graphic:O}=m.getOption()??{graphic:[]};r.value={...M,graphic:O},m.setOption(r.value,!0),r5("st-kline组件消息:K线绘制完毕-draw",{color:"green"})}],["line",()=>{const M=m.getOption(),O=Kat(e.lineData,i.value,m);r.value={...M,graphic:O},m.setOption(r.value,{replaceMerge:["graphic"]}),r5("st-kline组件消息:额外画线绘制完毕-draw",{color:"green"})}],["brush",()=>{const{brushRange:M}=e;M instanceof Array&&M.length>0&&(m.dispatchAction({type:"brush",areas:[{brushType:"lineX",coordRange:[M[0]+"",M[1]+""],xAxisIndex:0}]}),r5("st-kline组件消息:区域刷选绘制完毕-draw",{color:"green"}))}],[void 0,async()=>{await u("kline"),await u("line"),await u("priceTrend"),await u("priceTrendPercent"),await u("brush")}],["history",async()=>{const M=m.getOption(),O=await rk(e.klineData,e.markData,e.indicator,i.value,e.netPositionData,e.relevanceData),F=O.dataset.source.klineData.length-M.dataset[0].source.klineData.length;m.setOption({...O,dataZoom:[{type:"inside",xAxisIndex:[0,0],zoomLock:i.value.zoomLock,maxValueSpan:i.value.maxValueSpan,startValue:M.dataZoom[0].startValue+F,endValue:M.dataZoom[0].endValue+F}]},!0),await u("priceTrend")}],["future",async()=>{const M=m.getOption(),O=await rk(e.klineData,e.markData,e.indicator,i.value,e.netPositionData,e.relevanceData);O.dataZoom[0].start=(e.klineData.length-M.dataZoom[0].endValue+M.dataZoom[0].startValue)/e.klineData.length*100,m.setOption(O,!0),await u("priceTrend")}],["priceTrend",()=>{if(e.priceTrendData.length===0)return;const M=m.getOption(),O=["#FFFFFF","#FFDD00","#FF00FF","#00FF00","#FF6000","#1677FF","#7C3CC9","#FF0000","#FB9A0E","#00B7FF"],F=e.priceTrendData.reduce(($,Y,U)=>{const{name:z,data:ne}=Y,le={name:`二腿价格走势图-${z}`,type:"line",data:ne,symbol:"none",yAxisIndex:1,connectNulls:!0,itemStyle:{color:O[U]},lineStyle:{type:"dashed",width:1}};return $.push(le),$},[]);r.value={...M,series:[...M.series,...F]},m.setOption(r.value,{replaceMerge:["series"]})}],["priceTrendPercent",async()=>{if(e.priceTrendPercentData.length===0)return;const M=m.getOption(),O=["#FFFFFF","#FFDD00","#FF00FF","#00FF00","#FF6000","#1677FF","#7C3CC9","#FF0000","#FB9A0E","#00B7FF"],F=M.dataZoom[0].startValue,$=e.priceTrendPercentData.reduce((Y,U,z)=>{const{name:ne,data:le}=U,ue=le.length>i.value.totalBarCount?le.slice(le.length-i.value.totalBarCount):le,X=ue[F][1],oe=ue.map(pe=>[pe[0],(pe[1]-X)/X*100]),de={name:`二腿价格走势百分比图-${ne}`,type:"line",data:oe,symbol:"none",yAxisIndex:1,connectNulls:!0,itemStyle:{color:O[z]},lineStyle:{type:"dashed",width:1}};return Y.push(de),Y},[]);M.series=[...M.series.filter(Y=>!Y.name.includes("二腿价格走势百分比图")),...$],m.setOption(M,!0)}]]).get(R);I instanceof Function&&await I()},d=c.ref(!1),h=c.ref([]),f=R=>{const{callBack:B}=R;B instanceof Function&&B(m,d)},p=()=>{h.value=e.defaultMenuData},g=c.ref();let m,_;const b=(R,B)=>{var I,M;if(R)o.value=typeof((I=R==null?void 0:R.batch[0])==null?void 0:I.dataIndex)=="number"?(M=R==null?void 0:R.batch[0])==null?void 0:M.dataIndex:-1;else{const O=B.getOption();O.dataZoom instanceof Array&&(o.value=O.dataZoom[0].endValue)}};let C=null,y=!1,v=c.ref(!1),w=!1,x=c.ref(!1);const S=async R=>{const B=R.batch?R.batch[0].start*i.value.totalBarCount:R.startValue;i.value.dynamicLoadConfig.historyVisible&&B<=100&&!y&&!v.value&&(y=!0,await i.value.dynamicLoadConfig.historyLoadCallBack(v),await u("history"),y=!1);const I=R.batch?R.batch[0].end===100:R.endValue>=e.klineData.length-i.value.preBarCount-1,M=R.actionIsWheel;i.value.dynamicLoadConfig.futureVisible&&I&&!w&&!x.value&&!M&&(w=!0,await i.value.dynamicLoadConfig.futureLoadCallBack(x),await u("future"),w=!1),clearTimeout(C),C=setTimeout(()=>{u("line"),u("priceTrendPercent"),clearTimeout(C),C=null},Jat)};let N=null;const D=R=>{N=setTimeout(()=>{var B;if(R.componentType==="graphic"){const{oncontextmenu:I}=((B=R.info)==null?void 0:B.event)??{};I instanceof Function&&I(R,R.info,h)}clearTimeout(N),N=null})},L=()=>{m.on("highlight",R=>{b(R,m)}),m.on("globalout",()=>{b(null,m)}),m.on("contextmenu",R=>{D(R)}),m.on("datazoom",R=>{S(R)})},E=()=>{m.off("highlight"),m.off("globalout"),m.off("contextmenu"),m.off("datazoom")},k=R=>{if(!m||!(R.ctrlKey||e.isSelect))return;const B=m.getOption();let{startValue:I,endValue:M,start:O,end:F}=B.dataZoom[0];const $=()=>{I!==0&&(I=I-1,M=M-1,m.dispatchAction({type:"dataZoom",startValue:I,endValue:M,maxValueSpan:i.value.maxValueSpan}))},Y=()=>{if(i.value.dynamicLoadConfig.futureVisible&&!w&&!x.value)I=I+1,M=M+1,m.dispatchAction({type:"dataZoom",startValue:I,endValue:M,maxValueSpan:i.value.maxValueSpan});else{if(M===B.xAxis[0].data.length-1)return;I=I+1,M=M+1,m.dispatchAction({type:"dataZoom",startValue:I,endValue:M,maxValueSpan:i.value.maxValueSpan})}},U=()=>{if(M-I<5)return;const ue=Math.floor((o.value-I)/2)+1,X=Math.floor((M-o.value)/2)+1;I=I+ue,M=M-X,m.dispatchAction({type:"dataZoom",startValue:I,endValue:M,actionIsWheel:!0,maxValueSpan:i.value.maxValueSpan})},z=()=>{O=O-(F-O)/4,m.dispatchAction({type:"dataZoom",start:O,end:F,actionIsWheel:!0,maxValueSpan:i.value.maxValueSpan})},le=new Map([["ArrowLeft",$],["ArrowRight",Y],["ArrowUp",U],["ArrowDown",z]]).get(R.code);le instanceof Function&&le()},A=async()=>{let R=!0;m=qr.init(g.value),await u(),h.value=e.defaultMenuData,o.value=m.getOption().dataZoom[0].endValue??-1,L(),_=new ResizeObserver(()=>{if(R){R=null;return}m.resize(),u("line")}),_.observe(g.value),window.addEventListener("keydown",k)};return c.onMounted(()=>{A()}),c.onUnmounted(()=>{E(),window.removeEventListener("keydown",k),m.dispose(),_.disconnect(),_=null}),(R,B)=>{const I=lz,M=az;return c.openBlock(),c.createElementBlock("div",Zat,[c.createElementVNode("div",Xat,[c.createVNode(ZE,{data:s.value},null,8,["data"]),c.createVNode(ZE,{data:a.value},null,8,["data"]),c.createVNode(ZE,{data:l.value},null,8,["data"])]),c.createVNode(Btt,{class:"st-kline-body",onCloseContextMenuCallBack:p},{popover:c.withCtx(()=>[c.createVNode(M,{class:"menu"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(h.value,O=>(c.openBlock(),c.createBlock(I,{key:O.label,index:O.label,class:"menuItem",onClick:F=>f(O)},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(O.label),1)]),_:2},1032,["index","onClick"]))),128))]),_:1})]),default:c.withCtx(()=>[c.createElementVNode("div",{ref_key:"echartsRef",ref:g,class:c.normalizeClass(d.value?"st-kline-chart cursorPen":"st-kline-chart")},null,2)]),_:1})])}}}),xMt="",SMt="",tlt=vn(elt,[["__scopeId","data-v-7f014d0e"]]),nlt={class:"kline-tips"},ilt=c.defineComponent({__name:"index",props:{data:{type:Array,require:!0}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",nlt,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,(i,r)=>(c.openBlock(),c.createElementBlock("div",{key:r,class:"kline-tips-item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),128))]))}}),DMt="",ok=vn(ilt,[["__scopeId","data-v-dc7d381b"]]),NMt="",rlt={class:"klineSub"},olt={class:"klineSub-tips"},slt={key:0,class:"klineSub-tips-select"},alt=vn({__name:"index",props:{data:{type:Object,require:!0},activeIndex:{type:[Number,String],require:!0},modelValue:{type:String,required:!0},subIndicatorList:{type:Array,required:!0}},emits:["update:modelValue"],setup(n,{expose:e,emit:t}){const{round:i}=bl;let r,o;const s=t,a=n,l=c.ref(),u=c.computed({get(){return a.modelValue},set(f){s("update:modelValue",f)}}),d=c.computed(()=>{var g;const{data:f,activeIndex:p}=a;return((g=f==null?void 0:f.subIndicator)==null?void 0:g.map(m=>({label:m.key,color:m.color,value:m.data[p]||"-"})))||[]});c.onMounted(()=>{r=qr.init(l.value);let f=!0;o=new ResizeObserver(()=>{if(f){f=null;return}r.resize()}),o.observe(l.value)}),c.onUnmounted(()=>{r.dispose(),o.disconnect(),o=null});const h=(f,p)=>{const g=f[p],m=p===0?f[p]:f[p-1];return g[0]===g[1]?g[0]>=m[1]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}:g[1]>g[0]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}};return e({connect:f=>{qr.connect([f,r])},draw:(f,p)=>{c.nextTick(()=>{const{startValue:g,endValue:m,maxValueSpan:_}=f,{leftYAxisRange:b,rightYAxisRange:C}=a.data.subIndicator[0],y=a.data.subIndicator.map(v=>{if(v.series==="bar")return{name:"subMain",xAxisIndex:0,yAxisIndex:1,type:"bar",silent:!0,symbol:"none",data:v.data.map((w,x)=>v.seriesColor==="kline"?{value:w,itemStyle:h(a.data.data,x)}:v.seriesColor==="value"?{value:w,itemStyle:{color:w>=0?"#FF0000":"#00FFFF"}}:{value:w,itemStyle:{color:v.seriesColor}})};if(v.series==="line")return{xAxisIndex:0,yAxisIndex:v.yAxis==="right"?2:1,name:v.key,type:"line",silent:!0,symbol:"none",data:v.data,lineStyle:{width:1},itemStyle:{color:v.color}}});r.setOption({animation:!1,grid:{left:`${p.gridLeft}px`,top:"10px",right:`${p.gridRight}px`,bottom:"20px"},dataZoom:[{type:"inside",startValue:g,endValue:m,maxValueSpan:_}],tooltip:{trigger:"axis",appendToBody:!0,confine:!0,axisPointer:{type:"cross",label:{rich:{},formatter:v=>{const{axisDimension:w,value:x}=v;if(w==="x")return x;if(v.axisIndex===1)return String(i(x))}}},formatter:()=>""},xAxis:{type:"category",data:a.data.time,axisLine:{show:!0},splitLine:{show:!1},axisLabel:{show:!0,formatter:v=>v}},yAxis:[{position:"right"},{position:"left",min:b==="cover"?v=>v.min:null,max:b==="cover"?v=>v.max:null,splitNumber:1,axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}}},{position:"right",min:C==="cover"?v=>v.min:null,max:C==="cover"?v=>v.max:null,splitNumber:1,axisLine:{show:!1},splitLine:{show:!1},axisLabel:{show:!1}}],series:y},!0)})}}),(f,p)=>{const g=Gl,m=Kl;return c.openBlock(),c.createElementBlock("div",rlt,[c.createElementVNode("div",olt,[d.value.length?(c.openBlock(),c.createElementBlock("div",slt,[c.createVNode(m,{modelValue:u.value,"onUpdate:modelValue":p[0]||(p[0]=_=>u.value=_),size:"small","popper-class":"element-dark",class:"element-dark subIndicator"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.subIndicatorList,_=>(c.openBlock(),c.createBlock(g,{key:_.value,label:_.label,value:_.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])])):c.createCommentVNode("",!0),c.createVNode(ok,{data:d.value},null,8,["data"])]),c.createElementVNode("div",{class:"klineSub-chart",ref_key:"subChartRef",ref:l},null,512)])}}},[["__scopeId","data-v-aba58678"]]),kMt="",llt={class:"kline-tips"},ult=vn({__name:"index",props:{data:{type:Object,require:!0},activeIndex:{type:[Number,String],require:!0}},setup(n){const{round:e,formatValue:t}=bl,i=n,r=c.computed(()=>{const{data:s,activeIndex:a}=i;if(s.data&&s.data[a]){const l=s.data[a],u=[{label:"开",value:e(l[0])},{label:"高",value:e(l[3])},{label:"低",value:e(l[2])},{label:"收",value:e(l[1])}];l[4]!==null&&u.push({label:"额",value:t(l[4])});let d;return l[6]>0?d="red":l[6]<0&&(d="green"),u.push({label:"涨跌",value:`${e(l[6])}%`,color:d}),u}return[]}),o=c.computed(()=>{var l;const{data:s,activeIndex:a}=i;return((l=s==null?void 0:s.mainIndicator)==null?void 0:l.map(u=>({label:u.key,value:e(u.data[a]),color:u.color})))||[]});return(s,a)=>(c.openBlock(),c.createElementBlock("div",llt,[c.createVNode(ok,{data:r.value},null,8,["data"]),c.createVNode(ok,{data:o.value},null,8,["data"])]))}},[["__scopeId","data-v-a12855fe"]]),clt={__name:"index",setup(n,{expose:e}){return e({handleKeyDown:(t,i)=>{let{startValue:r,endValue:o,maxIndex:s}=i;if(t.code==="ArrowLeft"){if(r===0)return;r=r-1,o=o-1}else if(t.code==="ArrowRight"){if(o===s)return;r=r+1,o=o+1}else if(t.code==="ArrowUp"){if(o-r<5)return;const a=Math.floor((o-r)/2)+1;r=r+a,o-r<5&&(r=o-4)}else if(t.code==="ArrowDown"){const a=Math.min(500,o-r);r=r-a-1}return{startValue:r,endValue:o}},mergeData:(t,i)=>({time:[...t.time,...i.time.slice(1)],data:[...t.data,...i.data.slice(1)],mainIndicator:t.mainIndicator.map((r,o)=>({...r,data:[...r.data,...i.mainIndicator[o].data.slice(1)]})),subIndicator:t.subIndicator.map((r,o)=>({...r,data:[...r.data,...i.subIndicator[o].data.slice(1)]}))}),getDataZoomInfoByTime:t=>{const{showStartTime:i,showEndTime:r,maxShowDays:o}=t;let s=-1,a=-1,l={};return t.time.forEach((u,d)=>{const h=u.split(" ")[0];l[h]=l[h]||0,l[h]+=1,s===-1&&new Date(u)>=new Date(i)&&(s=d),a===-1&&new Date(u)>=new Date(r)&&(a=d)}),a=a===-1?t.time.length-1:a,{startValue:s,endValue:a,maxValueSpan:Math.max(...Object.values(l))*o}}}),(t,i)=>null}},MMt="",dlt=vn({__name:"index",props:{data:{type:Array,default:()=>[]}},emits:["change"],setup(n,{expose:e,emit:t}){let i,r,o=null;const s=t,a=n,l=c.ref();c.watch(()=>a.data,()=>{h()},{deep:!0}),c.onMounted(()=>{i=qr.init(l.value),u(),h();let f=!0;r=new ResizeObserver(()=>{if(f){f=null;return}i.resize()}),r.observe(l.value)}),c.onUnmounted(()=>{i.off("datazoom"),i.dispose(),r.disconnect(),r=null});const u=()=>{i.on("datazoom",f=>{f.dataZoomId&&(clearTimeout(o),o=setTimeout(()=>{const{data:p}=a,{start:g,end:m}=f,_=Math.floor(g*p.length/100),b=m===100?p.length-1:Math.floor(m*p.length/100);d(_,b),clearTimeout(o)},100))})},d=(f,p)=>{const g=a.data;if(g.length===0)return;const m=g[f][0].split(" ")[0],_=g[p][0].split(" ")[0];s("change",{startTime:`${m} 00:00:00`,endTime:`${_} 24:00:00`})},h=()=>{const{data:f}=a;if(f.length===0)return;const p=f.map(m=>m[0].split(" ")[0]),g=f.map(m=>m[1]);i.setOption({grid:{height:0,left:"80px",right:"80px"},xAxis:{type:"category",data:p,show:!1},yAxis:{type:"value"},series:[{data:g,type:"line"}]},!0)};return e({resetSlide:(f,p,g)=>{let m=-1,_=-1;a.data.forEach((b,C)=>{m===-1&&b[0]===f?m=C:m===-1&&new Date(b[0])>new Date(f)&&(m=C-1),(_===-1&&b[0]===p||_===-1&&new Date(b[0])>new Date(p))&&(_=C)}),_=_===-1?a.data.length-1:_,i.setOption({dataZoom:[{show:!0,startValue:m,endValue:_,maxValueSpan:g,textStyle:{color:"#ccc"}},{type:"inside",startValue:m,endValue:_,maxValueSpan:g}]})},resize:()=>{i==null||i.resize()}}),(f,p)=>(c.openBlock(),c.createElementBlock("div",{class:"klineSlide",ref_key:"slideChartRef",ref:l},null,512))}},[["__scopeId","data-v-7a2f3dd0"]]),hlt={install(n){n.component("st-kline",tlt),n.component("st-kline-sub-new",alt),n.component("st-kline-tips-new",ult),n.component("st-kline-slide-new",dlt),n.component("st-kline-utils-new",clt)}};let P2=null;const flt=n=>{const e=dJ(n,{handleReq:t=>{pJ()&&(t.headers.token=fJ())},handleRes:t=>{const{data:i}=t;if(i.code===401)return location.origin.includes("localhost")?location.href=`${location.origin}/#/404`:YE(),!0}});e.get,P2=e.post},plt=n=>P2("/middleLayer/kline/getKlineBasic",{...n,userId:R1("id")}),glt=n=>P2("/middleLayer/kline/getKline",n),mlt=async n=>P2("/alarm/deliversign/addAlarmPrice",{...n,userId:R1("id")}),blt=async n=>P2("/alarm/deliversign/findAlarmPriceByUserId",{...n,userId:R1("id")}),vne=async n=>P2("/alarm/deliversign/updateAlarmPrice",{...n,userId:R1("id")}),_lt=async n=>P2("/alarm/deliversign/deleteAlarmPrice",{...n,userId:R1("id")}),{round:o5}=bl,ylt=(n,e,t,i,r)=>{const{data:o,time:s}=n,{gridTop:a,gridRight:l,gridLeft:u,maxShowCounts:d,showSubChart:h}=e;return{animation:!1,grid:{top:`${a}px`,right:`${l}px`,bottom:h?"6px":"24px",left:`${u}px`},dataZoom:[{type:"inside",startValue:t,endValue:i,maxValueSpan:d}],tooltip:{trigger:"axis",appendToBody:!0,confine:!0,axisPointer:{type:"cross",label:{rich:{},formatter:f=>{const{axisDimension:p,value:g}=f;return p==="x"?h?"":["6","7","8"].includes(r)?bt(g).format("YYYY-MM-DD"):g:String(o5(g))}}},formatter:()=>""},xAxis:{show:!h,type:"category",data:s,splitLine:{show:!1},axisLabel:{formatter:f=>["6","7","8"].includes(r)?bt(f).format("YYYY-MM-DD"):f}},yAxis:{type:"value",axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}},min:f=>o5(f.min),max:f=>o5(f.max)},series:[{type:"candlestick",data:o,itemStyle:{color:"transparent",color0:"#00FFFF",borderColor:"#FF0000",borderColor0:"#00FFFF",borderWidth:1}},...n.mainIndicator.map(f=>({name:f.key,type:"line",silent:!0,symbol:"none",data:f.data,lineStyle:{width:f.width||1},itemStyle:{color:f.color}}))],toolbox:{show:!1},brush:{xAxisIndex:"all",brushLink:"all",transformable:!1,outOfBrush:{colorAlpha:2},brushStyle:{color:"rgba(255,255,255,0.1)",borderColor:"rgba(255,255,255,0.4)"}}}},vlt=(n,e,t,i,r)=>{const{variety:o,featureId:s,featureType:a}=t,{gridTop:l,gridLeft:u,gridRight:d}=i;return e.reduce((h,f)=>{const{warnPrice:p}=f,g=n==null?void 0:n.convertToPixel({yAxisIndex:0},p);if(g<=l||g>=(n==null?void 0:n.getHeight()))return h;let m=0;return[...h,{type:"group",name:"warningLine",info:f,draggable:"vertical",children:[{type:"line",info:f,shape:{x1:u,y1:g,x2:(n==null?void 0:n.getWidth())-d,y2:g},style:{stroke:"#FFF",lineWidth:1,lineDash:[8,4]},z:10},{type:"text",info:f,x:(n==null?void 0:n.getWidth())-d,y:g-5,style:{fill:"#FFF",text:p,stroke:"#000",lineWidth:1,opacity:1},z:10}],ondragstart:_=>{m=_.offsetY},ondrag:_=>{var b;if(_.target&&_.target.childAt(1)){const C=n.convertFromPixel({yAxisIndex:0},g+(_.offsetY-m));(b=_.target.childAt(1))==null||b.animate("style",!1).when(1,{text:o5(C,3)}).start()}},ondragend:async _=>{const C=_.offsetY-m;if(C!==0){const y=n==null?void 0:n.convertFromPixel({yAxisIndex:0},C+g),v={id:f.id,warnPrice:o5(y,3),featureId:s,featureCode:o,featureType:a};await vne(v),An.success("画线预警修改成功"),r&&r()}}}]},[])},Clt={class:"kline-tips"},wlt=c.defineComponent({__name:"index",props:{data:{type:Array,require:!0}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",Clt,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,(i,r)=>(c.openBlock(),c.createElementBlock("div",{key:r,class:"kline-tips-item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),128))]))}}),AMt="",sk=vn(wlt,[["__scopeId","data-v-f83b6b36"]]),IMt="",xlt={class:"kline-tips"},Slt=vn({__name:"index",props:{data:{type:Object,require:!0},activeIndex:{type:[Number,String],require:!0}},setup(n){const{round:e,formatValue:t}=bl,i=n,r=c.computed(()=>{const{data:s,activeIndex:a}=i;if(s.data&&s.data[a]){const l=s.data[a],u=[{label:"开",value:e(l[0])},{label:"高",value:e(l[3])},{label:"低",value:e(l[2])},{label:"收",value:e(l[1])}];l[4]!==null&&u.push({label:"额",value:t(l[4])});let d;return l[6]>0?d="red":l[6]<0&&(d="green"),u.push({label:"涨跌",value:`${e(l[6])}%`,color:d}),u}return[]}),o=c.computed(()=>{var l;const{data:s,activeIndex:a}=i;return((l=s==null?void 0:s.mainIndicator)==null?void 0:l.map(u=>({label:u.key,value:e(u.data[a]),color:u.color})))||[]});return(s,a)=>(c.openBlock(),c.createElementBlock("div",xlt,[c.createVNode(sk,{data:r.value},null,8,["data"]),c.createVNode(sk,{data:o.value},null,8,["data"])]))}},[["__scopeId","data-v-64b5c2a3"]]),OMt="",Dlt={class:"klineSub"},Nlt={class:"klineSub-tips"},Elt={key:0,class:"klineSub-tips-select"},klt=vn({__name:"index",props:{cycle:{type:[String,Number],default:()=>null},data:{type:Object,require:!0},activeIndex:{type:[Number,String],require:!0},modelValue:{type:String,required:!0},subIndicatorList:{type:Array,required:!0}},emits:["update:modelValue"],setup(n,{expose:e,emit:t}){const{round:i}=bl;let r,o;const s=t,a=n,l=c.ref(),u=c.computed({get(){return a.modelValue},set(f){s("update:modelValue",f)}}),d=c.computed(()=>{var g;const{data:f,activeIndex:p}=a;return((g=f==null?void 0:f.subIndicator)==null?void 0:g.map(m=>({label:m.key,color:m.color,value:m.data[p]||"-"})))||[]});c.onMounted(()=>{r=qr.init(l.value);let f=!0;o=new ResizeObserver(()=>{if(f){f=null;return}r.resize()}),o.observe(l.value)}),c.onUnmounted(()=>{r.dispose(),o.disconnect(),o=null});const h=(f,p)=>{const g=f[p],m=p===0?f[p]:f[p-1];return g[0]===g[1]?g[0]>=m[1]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}:g[1]>g[0]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}};return e({connect:f=>{qr.connect([f,r])},draw:(f,p)=>{c.nextTick(()=>{const{startValue:g,endValue:m,maxValueSpan:_}=f,{leftYAxisRange:b,rightYAxisRange:C}=a.data.subIndicator[0],y=a.data.subIndicator.map(v=>{if(v.series==="bar")return{name:"subMain",xAxisIndex:0,yAxisIndex:1,type:"bar",silent:!0,symbol:"none",data:v.data.map((w,x)=>v.seriesColor==="kline"?{value:w,itemStyle:h(a.data.data,x)}:v.seriesColor==="value"?{value:w,itemStyle:{color:w>=0?"#FF0000":"#00FFFF"}}:{value:w,itemStyle:{color:v.seriesColor}})};if(v.series==="line")return{xAxisIndex:0,yAxisIndex:v.yAxis==="right"?2:1,name:v.key,type:"line",silent:!0,symbol:"none",data:v.data,lineStyle:{width:1},itemStyle:{color:v.color}}});r.setOption({animation:!1,grid:{left:`${p.gridLeft}px`,top:"10px",right:`${p.gridRight}px`,bottom:"20px"},dataZoom:[{type:"inside",startValue:g,endValue:m,maxValueSpan:_}],tooltip:{trigger:"axis",appendToBody:!0,confine:!0,axisPointer:{type:"cross",label:{rich:{},formatter:v=>{const{axisDimension:w,value:x}=v;if(w==="x")return["6","7","8"].includes(a.cycle)?bt(x).format("YYYY-MM-DD"):x;if(v.axisIndex===1)return String(i(x))}}},formatter:()=>""},xAxis:{type:"category",data:a.data.time,axisLine:{show:!0},splitLine:{show:!1},axisLabel:{formatter:v=>["6","7","8"].includes(a.cycle)?bt(v).format("YYYY-MM-DD"):v}},yAxis:[{position:"right"},{position:"left",min:b==="cover"?v=>v.min:null,max:b==="cover"?v=>v.max:null,splitNumber:1,axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}}},{position:"right",min:C==="cover"?v=>v.min:null,max:C==="cover"?v=>v.max:null,splitNumber:1,axisLine:{show:!1},splitLine:{show:!1},axisLabel:{show:!1}}],series:y},!0)})}}),(f,p)=>{const g=Gl,m=Kl;return c.openBlock(),c.createElementBlock("div",Dlt,[c.createElementVNode("div",Nlt,[d.value.length?(c.openBlock(),c.createElementBlock("div",Elt,[c.createVNode(m,{modelValue:u.value,"onUpdate:modelValue":p[0]||(p[0]=_=>u.value=_),size:"small","popper-class":"element-dark",class:"element-dark subIndicator"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.subIndicatorList,_=>(c.openBlock(),c.createBlock(g,{key:_.value,label:_.label,value:_.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])])):c.createCommentVNode("",!0),c.createVNode(sk,{data:d.value},null,8,["data"])]),c.createElementVNode("div",{class:"klineSub-chart",ref_key:"subChartRef",ref:l},null,512)])}}},[["__scopeId","data-v-ab519de5"]]),Llt=c.defineComponent({__name:"index",emits:["closeContextMenuCallBack"],setup(n,{emit:e}){const t=e,i=c.ref(),r=c.ref(),o=c.ref({display:"none",top:"0px",left:"0px"}),s=()=>{o.value.display="none",t("closeContextMenuCallBack"),document.removeEventListener("click",s)},a=l=>{if(l.preventDefault(),o.value.display==="block"){const{offsetX:u,offsetY:d}=l,{offsetWidth:h,offsetHeight:f}=r.value;if(u<=h&&d<=f)return}i.value.click(),o.value={display:"block",top:`${l.offsetY}px`,left:`${l.offsetX}px`},c.nextTick(()=>{const u=i.value.getBoundingClientRect(),d=r.value.getBoundingClientRect();d.left+d.width>=u.right&&(o.value.left=`${l.offsetX-d.width}px`),d.top+d.height>=u.bottom&&(console.log("高度超出"),o.value.top=`${l.offsetY-d.height}px`)}),document.addEventListener("click",s)};return(l,u)=>(c.openBlock(),c.createElementBlock("div",{ref_key:"contextmenuRef",ref:i,class:"contextmenu",onContextmenu:a,onMouseleave:s},[c.renderSlot(l.$slots,"default",{},void 0,!0),o.value.display!=="none"?(c.openBlock(),c.createElementBlock("div",{key:0,ref_key:"contextmenuContentRef",ref:r,class:"contextmenu-popover",style:c.normalizeStyle(o.value)},[c.renderSlot(l.$slots,"popover",{},void 0,!0)],4)):c.createCommentVNode("",!0)],544))}}),PMt="",Mlt=vn(Llt,[["__scopeId","data-v-811db6b4"]]),BMt="",Cne=n=>(c.pushScopeId("data-v-9e6456be"),n=n(),c.popScopeId(),n),Tlt={class:"klineBasic-tips"},Alt={key:0,class:"klineBasic-sub"},Ilt={key:1,class:"klineBasic-empty"},Rlt={key:2,class:"klineBasic-error"},Olt=Cne(()=>c.createElementVNode("div",{class:"klineBasic-error-content"},"加载失败,请刷新重试",-1)),Flt={style:{"text-align":"center"}},Plt=Cne(()=>c.createElementVNode("span",{style:{"margin-right":"10px"}},"预警价格:",-1)),Blt={class:"dialog-footer"},Vlt=vn({__name:"index",props:{variety:{type:[String,Number],default:()=>null},varietyName:{type:[String,Number],default:()=>null},featureId:{type:[String,Number],default:()=>null},featureType:{type:[String,Number],default:()=>null},cycle:{type:[String,Number],default:()=>null},mainIndicator:{type:String,default:()=>""},indicatorStore:{type:Object,default:()=>null},startTime:{type:String,default:()=>null},endTime:{type:String,default:()=>null},right:{type:[String,Number],default:1},config:{type:Object,default:()=>({})},env:{type:Object,default:()=>({})},brushRange:{type:[Array,null],default:()=>null}},emits:["change","getFactorData"],setup(n,{expose:e,emit:t}){const i=[{label:"画线预警",key:"drawWarningLine"}];let r=null,o=null,s,a,l=!1,u=!1;const d=t,h=n,f=c.ref(!1),p=c.ref(!1),g=c.ref(!1),m=c.ref(null),_=c.ref(null),b=c.ref("VOL"),C=c.ref(0),y=c.ref({}),v=c.ref([]),w=c.ref({}),x=c.ref(!1),S=c.ref(""),N=c.ref([...i]),D=c.computed(()=>({defaultShowCounts:500,addCounts:2e3,maxShowCounts:5e3,loadCheckCounts:500,showSubChart:!0,gridTop:48,gridLeft:80,gridRight:50,showWarningLine:!0,getFactorData:!0,...h.config}));c.watch(()=>{var U,z;return[h.variety,h.cycle,h.mainIndicator,b.value,(U=h.indicatorStore)==null?void 0:U.filterIndicator,(z=h.indicatorStore)==null?void 0:z.customIndicator]},()=>{A()},{deep:!0}),c.onMounted(()=>{flt(h.env),A(),window.addEventListener("keydown",E)}),c.onUnmounted(()=>{o==null||o.off("datazoom"),o==null||o.off("highlight"),o==null||o.off("globalout"),o==null||o.dispose(),r==null||r.dispose(),window.removeEventListener("keydown",E)});const L=()=>{o||(o=qr.init(m.value),k(),D.value.showSubChart&&_.value.connect(o),r=hJ(m.value),r.listen(()=>{requestAnimationFrame(()=>{o.resize()})}))},E=({code:U,ctrlKey:z})=>{if(!(z||f.value))return;const{xAxis:ne,dataZoom:le}=o.getOption(),{data:ue}=(ne==null?void 0:ne[0])??{data:[]};let{startValue:X,endValue:oe}=(le==null?void 0:le[0])??{};if(ue!=null&&ue.length){switch(U){case"ArrowUp":{if(oe-X<5)return;const de=Math.floor((oe-X)/2)+1;X=X+de,oe-X<5&&(X=oe-4);break}case"ArrowDown":{const de=Math.min(500,oe-X);X=X-de-1;break}case"ArrowLeft":{X>0&&(X-=1,oe-=1),C.value>0&&(C.value-=1);break}case"ArrowRight":{oe<ue.length-1&&(X+=1,oe+=1),f.value&&C.value<ue.length-1&&(C.value+=1);break}}o.dispatchAction({type:"dataZoom",startValue:X,endValue:oe}),o.dispatchAction({type:"updateAxisPointer",seriesIndex:0,dataIndex:f.value?C.value:null}),o.dispatchAction({type:"highlight",dataIndex:f.value?C.value:oe})}},k=()=>{o==null||o.on("datazoom",z=>{clearTimeout(a),a=setTimeout(()=>{var le,ue,X,oe;const{loadCheckCounts:ne}=D.value;if((ue=(le=o==null?void 0:o.getOption())==null?void 0:le.dataZoom)!=null&&ue[0]){const{startValue:de}=(oe=(X=o==null?void 0:o.getOption())==null?void 0:X.dataZoom)==null?void 0:oe[0];de<ne&&l===!1&&u===!1&&(l=!0,R("history")),I()}clearTimeout(a)},100)}),o==null||o.on("highlight",z=>{var le,ue;let ne=z.dataIndex||-1;z.batch&&(ne=typeof((le=z==null?void 0:z.batch[0])==null?void 0:le.dataIndex)=="number"?(ue=z==null?void 0:z.batch[0])==null?void 0:ue.dataIndex:-1),clearTimeout(s),s=setTimeout(()=>{C.value=ne,clearTimeout(s)},20)}),o==null||o.on("globalout",()=>{var ne,le,ue;const z=(ue=(le=(ne=o==null?void 0:o.getOption())==null?void 0:ne.dataZoom)==null?void 0:le[0])==null?void 0:ue.endValue;C.value=z});let U=null;o==null||o.on("contextmenu",z=>{U=setTimeout(()=>{z.componentType==="graphic"&&(w.value=z.info,N.value=[{label:"删除画线",key:"deleteWarningLine"},{label:"修改画线",key:"changeWarningLine"}]),clearTimeout(U),U=null})})},A=async()=>{var U,z,ne,le,ue,X;try{if(!h.variety||!h.cycle)return;const{variety:oe,featureId:de,cycle:pe,indicatorStore:he,mainIndicator:ve,right:Le,startTime:re,endTime:W}=h,{defaultShowCounts:ee,addCounts:te,showWarningLine:J,getFactorData:ie}=D.value,G={variety:oe,featureId:de,cycle:pe,mainIndicatorList:he.getIndicatorParams(ve),subIndicator:b.value,right:Le,showWarningLine:J,getFactorData:ie};re&&W?(G.startTime=re,G.endTime=W):re?(G.startTime=re,G.limit=ee+te):W?(G.endTime=W,G.limit=ee+te):(G.endTime=bt().add(1,"hour").format("YYYY-MM-DD HH:mm:ss"),G.limit=ee+te);const Q=await plt(G);if((ne=(z=(U=Q==null?void 0:Q.body)==null?void 0:U.kline)==null?void 0:z.time)!=null&&ne.length)p.value=!1,g.value=!1;else{p.value=!0,g.value=!1;return}y.value=(le=Q==null?void 0:Q.body)==null?void 0:le.kline,v.value=((ue=Q==null?void 0:Q.body)==null?void 0:ue.warningLine)||[],B(),I(),ie&&d("getFactorData",(X=Q==null?void 0:Q.body)==null?void 0:X.factor)}catch(oe){throw g.value=!0,p.value=!1,new Error(oe)}},R=async U=>{const{variety:z,cycle:ne,indicatorStore:le,mainIndicator:ue,right:X}=h,{addCounts:oe}=D.value,{time:de}=y.value;if(U==="history"){const pe=await glt({variety:z,cycle:ne,endTime:de[0],limit:oe,mainIndicatorList:le.getIndicatorParams(ue),subIndicator:b.value,right:X});y.value={time:[...pe.body.time,...y.value.time.slice(1)],data:[...pe.body.data,...y.value.data.slice(1)],mainIndicator:y.value.mainIndicator.map((he,ve)=>{var Le;return{...he,data:[...((Le=pe.body.mainIndicator[ve])==null?void 0:Le.data)??[],...he.data.slice(1)]}}),subIndicator:y.value.subIndicator.map((he,ve)=>{var Le;return{...he,data:[...((Le=pe.body.subIndicator[ve])==null?void 0:Le.data)??[],...he.data.slice(1)]}})},B(!0),pe.body.data.length<oe&&(u=!0),l=!1}},B=(U=!1)=>{var ve,Le,re;L();const{time:z}=y.value,{gridRight:ne,gridLeft:le,defaultShowCounts:ue,maxShowCounts:X,showSubChart:oe}=D.value;let de=z.length-1-ue,pe=z.length-1;if(U){const W=o.getOption(),ee=(Le=(ve=W==null?void 0:W.xAxis)==null?void 0:ve[0])==null?void 0:Le.data,te=(re=W==null?void 0:W.dataZoom)==null?void 0:re[0],J=ee[te==null?void 0:te.startValue],ie=ee[te==null?void 0:te.endValue];de=z.findIndex(G=>G===J),pe=z.findIndex(G=>G===ie)}const he=ylt(y.value,D.value,de,pe,h.cycle);if(o.setOption(he,!0),C.value=pe,h.brushRange){let W=null,ee=null;switch(h.cycle){case"6":{W=z.find(te=>new Date(te).getTime()>=new Date(h.brushRange[0]).getTime()||bt(te).format("YYYY-MM-DD")===bt(h.brushRange[0]).format("YYYY-MM-DD")),ee=z.findLast(te=>new Date(te).getTime()<=new Date(h.brushRange[1]).getTime()||bt(te).format("YYYY-MM-DD")===bt(h.brushRange[1]).format("YYYY-MM-DD"));break}case"7":{W=z.find(te=>bt(te).day(5).format("YYYY-MM-DD")===bt(h.brushRange[0]).day(5).format("YYYY-MM-DD")),ee=z.findLast(te=>bt(te).day(5).format("YYYY-MM-DD")===bt(h.brushRange[1]).day(5).format("YYYY-MM-DD"));break}case"8":{W=z.find(te=>bt(te).endOf("month").format("YYYY-MM-DD")===bt(h.brushRange[0]).endOf("month").format("YYYY-MM-DD")),ee=z.findLast(te=>bt(te).endOf("month").format("YYYY-MM-DD")===bt(h.brushRange[1]).endOf("month").format("YYYY-MM-DD"));break}default:W=z.find(te=>new Date(te).getTime()>=new Date(h.brushRange[0]).getTime()),ee=z.findLast(te=>new Date(te).getTime()<=new Date(h.brushRange[1]).getTime())}console.log(W,ee),o.dispatchAction({type:"brush",areas:[{brushType:"lineX",coordRange:[W,ee],xAxisIndex:0}]})}oe&&_.value.draw({startValue:de,endValue:pe,maxValueSpan:X},{gridLeft:le,gridRight:ne}),M()},I=()=>{if(!o)return;const U=o==null?void 0:o.getOption();U&&(o==null||o.setOption({...U,graphic:[...vlt(o,v.value,h,D.value,()=>{O()})]},!0),M())},M=()=>{const{time:U}=y.value;if(h.brushRange&&(U!=null&&U.length)){let z=bt(h.brushRange[0]).format("YYYY-MM-DD 00:00:00"),ne=bt(h.brushRange[1]).format("YYYY-MM-DD 23:59:59"),le=null,ue=null;switch(h.cycle){case"6":{le=U.find(X=>bt(X).format("YYYY-MM-DD")===bt(z).format("YYYY-MM-DD")),ue=le;break}case"7":{le=U.find(X=>bt(X).day(5).format("YYYY-MM-DD")===bt(z).day(5).format("YYYY-MM-DD")),ue=U.findLast(X=>bt(X).day(5).format("YYYY-MM-DD")===bt(ne).day(5).format("YYYY-MM-DD"));break}case"8":{le=U.find(X=>bt(X).endOf("month").format("YYYY-MM-DD")===bt(z).endOf("month").format("YYYY-MM-DD")),ue=U.findLast(X=>bt(X).endOf("month").format("YYYY-MM-DD")===bt(ne).endOf("month").format("YYYY-MM-DD"));break}default:le=U.find(X=>{const oe=bt(X).format("YYYY-MM-DD")===bt(z).format("YYYY-MM-DD"),de=new Date(X).getTime()>=new Date(z).getTime();return oe&&de}),ue=U.findLast(X=>{const oe=bt(X).format("YYYY-MM-DD")===bt(ne).format("YYYY-MM-DD"),de=new Date(X).getTime()<=new Date(ne).getTime();return oe&&de})}o.dispatchAction({type:"brush",areas:[{brushType:"lineX",coordRange:[le,ue],xAxisIndex:0}]})}},O=async()=>{const U=await blt({featureId:h.featureId});v.value=(U==null?void 0:U.body)||[],I(),d("change","warningLine",v.value)},F=async U=>{const{variety:z,varietyName:ne,featureId:le,featureType:ue}=h;if(U.key==="drawWarningLine"){const X=o==null?void 0:o.getOption(),oe=X.tooltip[0];o==null||o.setOption({...X,tooltip:{...oe,axisPointer:{...oe.axisPointer,lineStyle:{width:0},crossStyle:{width:2},label:{...oe.axisPointer.label,backgroundColor:"transparent",formatter:pe=>""}}}});const de=async pe=>{o==null||o.getZr().off("mousedown",de);const he=o==null?void 0:o.convertFromPixel({yAxisIndex:0},pe.offsetY),ve=Math.round(he*1e3)/1e3;o==null||o.setOption({...X,tooltip:{...oe,axisPointer:{...oe.axisPointer,lineStyle:{width:1},crossStyle:{width:1},label:{...oe.axisPointer.label,backgroundColor:null}}}}),await mlt({featureCode:z,featureName:ne,featureId:le,featureType:ue,warnPrice:ve}),An.success("画线预警成功!"),O()};o==null||o.getZr().on("mousedown",de)}else U.key==="deleteWarningLine"?(await _lt({id:w.value.id}),An.success("画线预警删除成功"),O()):U.key==="changeWarningLine"&&(x.value=!0,S.value=w.value.warnPrice)},$=async()=>{const{variety:U,varietyName:z,featureId:ne,featureType:le}=h;await vne({id:w.value.id,featureCode:U,featureName:z,featureId:ne,featureType:le,warnPrice:S.value}),An.success("画线预警修改成功"),O()},Y=()=>{N.value=[...i]};return e({draw:(U,z)=>{U==="warningLine"&&(v.value=z,I())}}),(U,z)=>{var pe;const ne=lz,le=az,ue=Yg,X=so,oe=R6,de=ql;return c.openBlock(),c.createElementBlock(c.Fragment,null,[c.createElementVNode("div",{class:"klineBasic",onMousemove:z[1]||(z[1]=he=>f.value=!0),onMouseout:z[2]||(z[2]=he=>f.value=!1)},[c.createElementVNode("div",Tlt,[c.createVNode(Slt,{data:y.value,activeIndex:C.value},null,8,["data","activeIndex"])]),c.createElementVNode("div",{class:"klineBasic-main",style:c.normalizeStyle({height:D.value.showSubChart?"70%":"100%"})},[c.createVNode(Mlt,{onCloseContextMenuCallBack:Y},{popover:c.withCtx(()=>[c.createVNode(le,{style:{borderRadius:"4px",overflow:"hidden",background:"#fff",borderRight:0}},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(N.value,he=>(c.openBlock(),c.createBlock(ne,{style:{height:"36px"},key:he.key,index:he.key,onClick:ve=>F(he)},{default:c.withCtx(()=>[c.createTextVNode(c.toDisplayString(he.label),1)]),_:2},1032,["index","onClick"]))),128))]),_:1})]),default:c.withCtx(()=>[c.createElementVNode("div",{ref_key:"klineBasicMainRef",ref:m,style:{height:"100%"}},null,512)]),_:1})],4),D.value.showSubChart?(c.openBlock(),c.createElementBlock("div",Alt,[c.createVNode(klt,{ref_key:"klineSubRef",ref:_,modelValue:b.value,"onUpdate:modelValue":z[0]||(z[0]=he=>b.value=he),data:y.value,cycle:n.cycle,activeIndex:C.value,subIndicatorList:(pe=n.indicatorStore)==null?void 0:pe.subIndicatorList},null,8,["modelValue","data","cycle","activeIndex","subIndicatorList"])])):c.createCommentVNode("",!0),p.value?(c.openBlock(),c.createElementBlock("div",Ilt,[c.createVNode(ue,{class:"klineBasic-empty-content",description:"暂无数据"})])):c.createCommentVNode("",!0),g.value?(c.openBlock(),c.createElementBlock("div",Rlt,[Olt,c.createElementVNode("div",Flt,[c.createVNode(X,{onClick:A},{default:c.withCtx(()=>[c.createTextVNode("刷新")]),_:1})])])):c.createCommentVNode("",!0)],32),c.createVNode(de,{modelValue:x.value,"onUpdate:modelValue":z[5]||(z[5]=he=>x.value=he),title:"画线预警-修改价格",width:"30%","align-center":""},{footer:c.withCtx(()=>[c.createElementVNode("span",Blt,[c.createVNode(X,{onClick:z[4]||(z[4]=he=>x.value=!1)},{default:c.withCtx(()=>[c.createTextVNode("取消")]),_:1}),c.createVNode(X,{type:"primary",onClick:$},{default:c.withCtx(()=>[c.createTextVNode("确定")]),_:1})])]),default:c.withCtx(()=>[Plt,c.createVNode(oe,{modelValue:S.value,"onUpdate:modelValue":z[3]||(z[3]=he=>S.value=he),placeholder:"输入预警价格"},null,8,["modelValue"])]),_:1},8,["modelValue"])],64)}}},[["__scopeId","data-v-9e6456be"]]),zlt={install(n){n.component("st-klineBasic",Vlt)}},zMt="",HMt="",Hlt=[{label:"买卖",value:0},{label:"开平",value:1}],m_=()=>({mainIndicator:"MA",sellBuy:1,sellBuyByPrice:1,singelCycle:"6",multiCycleNum:6,multiCycleList:["1","2","3","4","5","6"],pageType:1,enable_tradeLogBrush:!0,enable_showScreenTimeRange:!0,enable_showScreenMaxPrice:!0,enable_dbClickOpenSingel:!0,enable_subChart:!0,enable_sliderChart:!0}),jlt=(n,e)=>{var t;return((t=e.find(i=>i.value===n))==null?void 0:t.label)??"-"},jMt="",_l=n=>(c.pushScopeId("data-v-009e01e7"),n=n(),c.popScopeId(),n),Wlt={class:"kline-config element-dark"},$lt={class:"setting-item"},Ult=_l(()=>c.createElementVNode("span",{class:"label"},"主图指标: ",-1)),qlt={class:"setting-item"},Klt=_l(()=>c.createElementVNode("span",{class:"label"},"交易点位: ",-1)),Glt={class:"setting-item"},Ylt=_l(()=>c.createElementVNode("span",{class:"label"},"开平点按价格标: ",-1)),Qlt={class:"setting-item"},Zlt=_l(()=>c.createElementVNode("span",{class:"label"},"单周期: ",-1)),Xlt={class:"setting-item"},Jlt=_l(()=>c.createElementVNode("span",{class:"label"},"多周期: ",-1)),eut={class:"mode"},tut={class:"cycleName"},nut={class:"content"},iut={class:"setting-item"},rut=_l(()=>c.createElementVNode("span",{class:"label"},"默认展示: ",-1)),out={class:"setting-item"},sut=_l(()=>c.createElementVNode("span",{class:"label"},"高亮交易范围: ",-1)),aut={class:"setting-item"},lut=_l(()=>c.createElementVNode("span",{class:"label"},"展示当屏时间: ",-1)),uut={class:"setting-item"},cut=_l(()=>c.createElementVNode("span",{class:"label"},"展示当屏最高价: ",-1)),dut={class:"setting-item"},hut=_l(()=>c.createElementVNode("span",{class:"label"},"多周期双击图表切换至单周期: ",-1)),fut={class:"setting-item"},put=_l(()=>c.createElementVNode("span",{class:"label"},"开启副图: ",-1)),gut={class:"setting-item"},mut=_l(()=>c.createElementVNode("span",{class:"label"},"开启拖拽轴: ",-1)),but={class:"setting-footer"},_ut=vn({__name:"index",props:{indicatorStore:{type:Object,default:()=>({})},origin:{type:String,default:"server"},cycleOptions:{type:Array,default:()=>[]}},emits:"callBack",setup(n,{expose:e,emit:t}){const{request:i}=c.inject("stConfig"),r=t,o=n,s=c.ref(!1),a=c.reactive({}),l=c.ref([]),u=c.ref([]),d=()=>{Object.assign(a,m_())},h=async()=>{const g=JSON.stringify(a);o.origin==="server"?await i.post("/common/qt/updateUserConfig",{appId:1,json:g}):localStorage.setItem("userKlineConfig",g),r("callBack",g),s.value=!1},f=async()=>{if(o.origin==="server"){const{body:g}=await i.post("/common/qt/getUserConfig",{appId:1});Object.assign(a,m_(),g?JSON.parse(g):{})}else{const g=localStorage.getItem("userKlineConfig");Object.assign(a,m_(),g?JSON.parse(g):{})}},p=async()=>{if(o.origin==="server"){const{body:g}=await i.post("/common/qt/getDict",{dictIds:[1002]});l.value=g[1002].map(m=>({label:m.dictName,value:m.dictCode}))}else l.value=o.cycleOptions};return c.onMounted(()=>{p(),u.value=o.indicatorStore.mainIndicatorList??[]}),e({open:async()=>{await f(),s.value=!0},getDefaultUserKlineConfig:m_}),(g,m)=>{const _=nS,b=Gl,C=Kl,y=u1,v=LH,w=rye,x=s1,S=so,N=D6e;return c.openBlock(),c.createElementBlock("div",Wlt,[c.createVNode(N,{modelValue:s.value,"onUpdate:modelValue":m[12]||(m[12]=D=>s.value=D),title:"K线自定义配置",size:320},{default:c.withCtx(()=>[c.createVNode(x,{class:"setting-main"},{default:c.withCtx(()=>[c.createVNode(_,{style:{"margin-top":"8px"}},{default:c.withCtx(()=>[c.createTextVNode("偏好设置")]),_:1}),c.createElementVNode("div",$lt,[Ult,c.createVNode(C,{modelValue:a.mainIndicator,"onUpdate:modelValue":m[0]||(m[0]=D=>a.mainIndicator=D),"popper-class":"element-dark"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(u.value,(D,L)=>(c.openBlock(),c.createBlock(b,{key:L,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),c.createElementVNode("div",qlt,[Klt,c.createVNode(C,{modelValue:a.sellBuy,"onUpdate:modelValue":m[1]||(m[1]=D=>a.sellBuy=D),"popper-class":"element-dark"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(c.unref(Hlt),(D,L)=>(c.openBlock(),c.createBlock(b,{key:L,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),c.createElementVNode("div",Glt,[Ylt,c.createVNode(y,{modelValue:a.sellBuyByPrice,"onUpdate:modelValue":m[2]||(m[2]=D=>a.sellBuyByPrice=D),"true-value":1,"false-value":0},null,8,["modelValue"])]),c.createElementVNode("div",Qlt,[Zlt,c.createVNode(C,{modelValue:a.singelCycle,"onUpdate:modelValue":m[3]||(m[3]=D=>a.singelCycle=D),"popper-class":"element-dark"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(l.value,(D,L)=>(c.openBlock(),c.createBlock(b,{key:L,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),c.createElementVNode("div",Xlt,[Jlt,c.createVNode(v,{size:"small",modelValue:a.multiCycleNum,"onUpdate:modelValue":m[4]||(m[4]=D=>a.multiCycleNum=D),options:[{label:"二图",value:2},{label:"四图",value:4},{label:"六图",value:6}],style:{height:"26px"}},null,8,["modelValue"])]),c.createElementVNode("div",{class:c.normalizeClass(`setting-multi-box grid-${a.multiCycleNum}`)},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(a.multiCycleList.slice(0,a.multiCycleNum),(D,L)=>(c.openBlock(),c.createElementBlock("div",eut,[c.createElementVNode("div",tut,[c.createElementVNode("span",null,c.toDisplayString(c.unref(jlt)(a.multiCycleList[L],l.value)),1),c.createVNode(C,{modelValue:a.multiCycleList[L],"onUpdate:modelValue":E=>a.multiCycleList[L]=E,"popper-class":"element-dark"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(l.value,(E,k)=>(c.openBlock(),c.createBlock(b,{key:k,label:E.label,value:E.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue"])]),c.createElementVNode("span",nut,c.toDisplayString(L+1)+"号位K线",1)]))),256))],2),c.createElementVNode("div",iut,[rut,c.createVNode(v,{size:"small",modelValue:a.pageType,"onUpdate:modelValue":m[5]||(m[5]=D=>a.pageType=D),options:[{label:"单周期",value:1},{label:"多周期",value:2}],style:{height:"26px"}},null,8,["modelValue"])]),c.createVNode(_,{style:{"margin-top":"44px"}},{default:c.withCtx(()=>[c.createTextVNode("功能配置")]),_:1}),c.createElementVNode("div",out,[sut,c.createVNode(w,{modelValue:a.enable_tradeLogBrush,"onUpdate:modelValue":m[6]||(m[6]=D=>a.enable_tradeLogBrush=D)},null,8,["modelValue"])]),c.createElementVNode("div",aut,[lut,c.createVNode(w,{modelValue:a.enable_showScreenTimeRange,"onUpdate:modelValue":m[7]||(m[7]=D=>a.enable_showScreenTimeRange=D)},null,8,["modelValue"])]),c.createElementVNode("div",uut,[cut,c.createVNode(w,{modelValue:a.enable_showScreenMaxPrice,"onUpdate:modelValue":m[8]||(m[8]=D=>a.enable_showScreenMaxPrice=D)},null,8,["modelValue"])]),c.createElementVNode("div",dut,[hut,c.createVNode(w,{modelValue:a.enable_dbClickOpenSingel,"onUpdate:modelValue":m[9]||(m[9]=D=>a.enable_dbClickOpenSingel=D)},null,8,["modelValue"])]),c.createVNode(_,{style:{"margin-top":"44px"}},{default:c.withCtx(()=>[c.createTextVNode("组件开关")]),_:1}),c.createElementVNode("div",fut,[put,c.createVNode(w,{modelValue:a.enable_subChart,"onUpdate:modelValue":m[10]||(m[10]=D=>a.enable_subChart=D)},null,8,["modelValue"])]),c.createElementVNode("div",gut,[mut,c.createVNode(w,{modelValue:a.enable_sliderChart,"onUpdate:modelValue":m[11]||(m[11]=D=>a.enable_sliderChart=D)},null,8,["modelValue"])])]),_:1}),c.createElementVNode("div",but,[c.createVNode(S,{onClick:d},{default:c.withCtx(()=>[c.createTextVNode(" 恢复默认 ")]),_:1}),c.createVNode(S,{type:"primary",onClick:h},{default:c.withCtx(()=>[c.createTextVNode(" 保存配置 ")]),_:1})])]),_:1},8,["modelValue"])])}}},[["__scopeId","data-v-009e01e7"]]),yut={install(n){n.component("st-klineConfig",_ut)}},vut=c.defineComponent({__name:"index",setup(n,{expose:e}){let t=!1,i=!0,r=[];const o=(s,a)=>s.length>a?s.slice(s.length-a):s;return e({initTalib:async()=>{if(!t)t=!0,await ek("./talib.wasm"),i=!1,r.forEach(s=>{s()});else if(i)return new Promise(s=>{r.push(s)})},handleKeyDown:(s,a)=>{let{startValue:l,endValue:u,maxIndex:d}=a;if(s.code==="ArrowLeft"){if(l===0)return;l=l-1,u=u-1}else if(s.code==="ArrowRight"){if(u===d)return;l=l+1,u=u+1}else if(s.code==="ArrowUp"){if(u-l<5)return;const h=Math.floor((u-l)/2)+1;l=l+h,u-l<5&&(l=u-4)}else if(s.code==="ArrowDown"){const h=Math.min(500,u-l);l=l-h-1}return{startValue:l,endValue:u}},getDataZoomInfoByTime:s=>{const{showStartTime:a,showEndTime:l,xAxisData:u,maxShowDays:d}=s;let h=-1,f=-1,p={};return u.forEach((g,m)=>{const _=g.split(" ")[0];p[_]=p[_]||0,p[_]+=1,new Date(g)>=new Date(a)&&h===-1&&(h=m),new Date(g)<=new Date(l)&&(f=m)}),{startValue:h,endValue:f,maxValueSpan:Math.max(...Object.values(p))*d}},formatDataBySlide:s=>{const{originDrawData:a,addData:l,startTime:u,endTime:d}=s,{mainIndicator:h,mainIndicatorList:f,subIndicator:p,subIndicatorList:g,config:m,timeRange:_}=s,{loadAddCount:b,preLoadCount:C}=m;let y=[],v=[],w=[],x=[];u&&d?(y=l.filter(k=>new Date(k[0])>=new Date(u)&&new Date(k[0])<=new Date(d)),x=[...l]):d?(y=[...l.filter((k,A)=>A>=l.length-b&&new Date(_[0])<=new Date(k[0])&&new Date(k[0])<=new Date(_[1])),...a.originData],x=[...l,...a.originData]):u&&(y=[...a.originData,...l.filter((k,A)=>A>=C&&new Date(_[0])<=new Date(k[0])&&new Date(k[0])<=new Date(_[1]))],x=y),y.forEach((k,A)=>{v.push([k[1],k[4],k[3],k[2],A===0?0:y[A-1][4],k[6]]),w.push(k[0])});let S=[],N=[];const D={time:[],open:[],close:[],high:[],low:[],originData:x};let L=null,E=null;return x.forEach((k,A)=>{D.time.push(k[0]),D.open.push(k[1]),D.close.push(k[4]),D.high.push(k[2]),D.low.push(k[3]),k[0]===y[0][0]&&(L=A),k[0]===y[y.length-1][0]&&(E=A+1)}),S=f.find(({value:k})=>k===h).config.map(k=>{const{calculationFn:A}=k;return{...k,data:A?A(i5,D,{time:[],open:[],close:[],high:[],low:[],originData:[]}).slice(L,E):[]}}),N=g.find(({value:k})=>k===p).config.reduce((k,A)=>{const{source:R,calculationFn:B}=A;return R==="calculation"?[...k,{...A,data:B?B(i5,D).slice(L,E):[]}]:k},[]),{originData:y,candlestickData:v,mainIndicatorData:S,subIndicatorData:N,xAxisData:w,startTime:y[0][0],endTime:y[y.length-1][0],length:y.length}},formatDataByCount:s=>{const{originDrawData:a,addData:l,mainIndicator:u,mainIndicatorList:d,subIndicator:h,subIndicatorList:f,config:p}=s;let g={};const{addCount:m,preLoadCount:_}=p,b=[],C=[],y=[],v=[],w=[];let x=[],S=[];const N=l.filter((A,R)=>(b.push(A[0]),C.push(A[1]),y.push(A[4]),v.push(A[2]),w.push(A[3]),x.push(A[0]),S.push([A[1],A[4],A[3],A[2],R===0?0:l[R-1][4],A[6]]),l.length>=m+_-1?R>=_:!0));x=o(x,N.length),S=o(S,N.length);const D={time:b,open:C,close:y,high:v,low:w,originData:l},E=d.find(A=>A.value===u).config.map(A=>({...A,data:o(A.calculationFn?A.calculationFn(i5,D,{time:[],open:[],close:[],high:[],low:[],originData:[]}):[],x.length)}));let k=[];return h&&f&&(k=f.find(R=>R.value===h).config.reduce((R,B)=>B.source==="calculation"?[...R,{...B,data:o(B.calculationFn?B.calculationFn(i5,D):[],x.length)}]:R,[])),a.length?g={originData:[...N,...a.originData],xAxisData:[...x,...a.xAxisData],candlestickData:[...S,...a.candlestickData],mainIndicatorData:a.mainIndicatorData.map((A,R)=>({...A,data:[...E[R].data,...A.data]})),subIndicatorData:a.subIndicatorData.map((A,R)=>({...A,data:[...k[R].data,...A.data]}))}:g={originData:N,xAxisData:x,candlestickData:S,mainIndicatorData:E,subIndicatorData:k},g.length=g.xAxisData.length,g.startTime=g.xAxisData[0],g.endTime=g.xAxisData[g.length-1],g},fn:()=>{}}),(s,a)=>null}}),Cut={class:"kline-tips"},wut=c.defineComponent({__name:"index",props:{data:{type:Array,require:!0}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",Cut,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,(i,r)=>(c.openBlock(),c.createElementBlock("div",{key:r,class:"kline-tips-item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),128))]))}}),$Mt="",ak=vn(wut,[["__scopeId","data-v-2a02e841"]]),xut={class:"kline-tips"},Sut=c.defineComponent({__name:"index",props:{drawData:{type:Object,require:!0},candlestickData:{type:Array,default:()=>null},mainIndicatorData:{type:Array,default:()=>null},activeIndex:{type:Number,require:!0}},setup(n){const{round:e,multiply:t,divide:i,subtract:r,formatValue:o}=bl,s=n,a=c.computed(()=>{const{drawData:u,activeIndex:d,candlestickData:h}=s;if(h!=null&&h.length&&h[d]){let f;return h[d][6]>0?f="red":h[d][6]<0&&(f="green"),[{label:"开",value:e(h[d][0])},{label:"高",value:e(h[d][3])},{label:"低",value:e(h[d][2])},{label:"收",value:e(h[d][1])},{label:"额",value:o(h[d][4])},{label:"涨跌",value:`${e(h[d][6])}%`,color:f}]}else if(u.candlestickData&&u.candlestickData[d]){const f=u.candlestickData[d],p=[{label:"开",value:e(f[0])},{label:"高",value:e(f[3])},{label:"低",value:e(f[2])},{label:"收",value:e(f[1])}];f[5]!==void 0&&p.push({label:"额",value:o(f[5])});const g=e(t(i(r(f[1],f[4]),Math.abs(f[4])),100));let m;return g>0?m="red":g<0&&(m="green"),p.push({label:"涨跌",value:`${g}%`,color:m}),p}return[]}),l=c.computed(()=>{var h;const{drawData:u,activeIndex:d}=s;return((h=u==null?void 0:u.mainIndicatorData)==null?void 0:h.map(f=>({label:f.key,value:e(f.data[d]),color:f.color})))||[]});return(u,d)=>(c.openBlock(),c.createElementBlock("div",xut,[c.createVNode(ak,{data:a.value},null,8,["data"]),c.createVNode(ak,{data:l.value},null,8,["data"])]))}}),UMt="",Dut=vn(Sut,[["__scopeId","data-v-234f3f41"]]),Nut={class:"klineSub"},Eut={class:"klineSub-tips"},kut={key:0,class:"klineSub-tips-select"},Lut=c.defineComponent({__name:"index",props:{drawData:{type:Object,require:!0},activeIndex:{type:Number,require:!0},modelValue:{type:String,required:!0},subIndicatorList:{type:Array,required:!0},config:{type:Object,require:!0}},emits:["update:modelValue"],setup(n,{expose:e,emit:t}){const{round:i}=bl;let r,o;const s=t,a=n,l=c.ref(),u=c.computed({get(){return a.modelValue},set(f){s("update:modelValue",f)}}),d=c.computed(()=>{const{drawData:f,activeIndex:p}=a,g=a.subIndicatorList.find(m=>m.value===u.value);return f.originData&&f.originData[p]?g.config.map(m=>{var b,C;let _="-";return m.source==="origin"?_=f.originData[p][m.dataIndex]||"-":m.source==="calculation"&&(_=(((C=(b=f.subIndicatorData)==null?void 0:b.find(v=>v.key===m.key))==null?void 0:C.data)||[])[p]),{label:m.key,color:m.color,value:_==="-"?_:i(_)}}):[]});c.onMounted(()=>{r=qr.init(l.value);let f=!0;o=new ResizeObserver(()=>{if(f){f=null;return}r.resize()}),o.observe(l.value)}),c.onUnmounted(()=>{r.dispose(),o.disconnect(),o=null});const h=(f,p)=>{const g=f[p],m=p===0?f[p]:f[p-1];return g[0]===g[1]?g[0]>=m[1]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}:g[1]>g[0]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}};return e({connect:f=>{qr.connect([f,r])},draw:f=>{c.nextTick(()=>{var x;const{startValue:p,endValue:g,maxValueSpan:m}=f,{xAxisData:_,subIndicatorData:b,candlestickData:C,originData:y}=a.drawData,v=a.subIndicatorList.find(S=>S.value===u.value),w=[];if(v.series==="bar"){let S=[];v.source==="origin"?S=y.map(N=>N[v.dataIndex]):S=((x=b==null?void 0:b.find(N=>N.key===v.dataIndex))==null?void 0:x.data)||[],w.push({name:"subMain",xAxisIndex:0,yAxisIndex:1,type:"bar",silent:!0,symbol:"none",data:S.map((N,D)=>v.color==="kline"?{value:N,itemStyle:h(C,D)}:v.color==="value"?{value:N,itemStyle:{color:N>=0?"#FF0000":"#00FFFF"}}:{value:N,itemStyle:{color:v.color}})})}b.forEach(S=>{if(S.series==="line"){let N=[];S.source==="origin"?N=y.map(D=>D[S.dataIndex]):S.source==="calculation"&&(N=S.data),w.push({xAxisIndex:0,yAxisIndex:S.yAxis==="right"?2:1,name:S.key,type:"line",silent:!0,symbol:"none",data:N,lineStyle:{width:1},itemStyle:{color:S.color}})}}),r.setOption({animation:!1,grid:{left:`${a.config.gridLeft}px`,top:"10px",right:`${a.config.gridRight}px`,bottom:"20px"},dataZoom:[{type:"inside",startValue:p,endValue:g,maxValueSpan:m}],tooltip:{trigger:"axis",appendToBody:!0,confine:!0,axisPointer:{type:"cross",label:{rich:{},formatter:S=>{const{axisDimension:N,value:D}=S;if(N==="x")return D;if(S.axisIndex===1)return String(i(D))}}},formatter:()=>""},xAxis:{type:"category",data:_,axisLine:{show:!0},splitLine:{show:!1},axisLabel:{show:!0,formatter:S=>S}},yAxis:[{position:"right"},{position:"left",min:v.leftYAxisRange==="cover"?S=>S.min:null,max:v.leftYAxisRange==="cover"?S=>S.max:null,splitNumber:1,axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}}},{position:"right",min:v.rightYAxisRange==="cover"?S=>S.min:null,max:v.rightYAxisRange==="cover"?S=>S.max:null,splitNumber:1,axisLine:{show:!1},splitLine:{show:!1},axisLabel:{show:!1}}],series:w},!0)})}}),(f,p)=>{const g=Gl,m=Kl;return c.openBlock(),c.createElementBlock("div",Nut,[c.createElementVNode("div",Eut,[d.value.length?(c.openBlock(),c.createElementBlock("div",kut,[c.createVNode(m,{modelValue:u.value,"onUpdate:modelValue":p[0]||(p[0]=_=>u.value=_),size:"small","popper-class":"element-dark",class:"element-dark subIndicator"},{default:c.withCtx(()=>[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.subIndicatorList,_=>(c.openBlock(),c.createBlock(g,{key:_.value,label:_.label,value:_.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])])):c.createCommentVNode("",!0),c.createVNode(ak,{data:d.value},null,8,["data"])]),c.createElementVNode("div",{class:"klineSub-chart",ref_key:"subChartRef",ref:l},null,512)])}}}),qMt="",Mut=vn(Lut,[["__scopeId","data-v-0a2f256e"]]),Tut=c.defineComponent({__name:"index",props:{data:{type:Array,default:()=>[]}},emits:["change"],setup(n,{expose:e,emit:t}){let i,r,o=null;const s=t,a=n,l=c.ref();c.watch(()=>a.data,()=>{h()},{deep:!0}),c.onMounted(()=>{i=qr.init(l.value),u(),h();let f=!0;r=new ResizeObserver(()=>{if(f){f=null;return}i.resize()}),r.observe(l.value)}),c.onUnmounted(()=>{i.off("datazoom"),i.dispose(),r.disconnect(),r=null});const u=()=>{i.on("datazoom",f=>{f.dataZoomId&&(clearTimeout(o),o=setTimeout(()=>{const{data:p}=a,{start:g,end:m}=f,_=Math.floor(g*p.length/100),b=m===100?p.length-1:Math.floor(m*p.length/100);d(_,b),clearTimeout(o)},100))})},d=(f,p)=>{const g=a.data;if(g.length===0)return;const m=g[f][0].split(" ")[0],_=g[p][0].split(" ")[0];s("change",{startTime:`${m} 00:00:00`,endTime:`${_} 24:00:00`})},h=()=>{const{data:f}=a;if(f.length===0)return;const p=f.map(m=>m[0].split(" ")[0]),g=f.map(m=>m[1]);i.setOption({grid:{height:0,left:"80px",right:"80px"},xAxis:{type:"category",data:p,show:!1},yAxis:{type:"value"},series:[{data:g,type:"line"}]},!0)};return e({resetSlide:(f,p,g)=>{let m=-1,_=-1;a.data.forEach((b,C)=>{m===-1&&b[0]===f?m=C:m===-1&&new Date(b[0])>new Date(f)&&(m=C-1),(_===-1&&b[0]===p||_===-1&&new Date(b[0])>new Date(p))&&(_=C)}),_=_===-1?a.data.length-1:_,i.setOption({dataZoom:[{show:!0,startValue:m,endValue:_,maxValueSpan:g,textStyle:{color:"#ccc"}},{type:"inside",startValue:m,endValue:_,maxValueSpan:g}]})},resize:()=>{i==null||i.resize()}}),(f,p)=>(c.openBlock(),c.createElementBlock("div",{class:"klineSlide",ref_key:"slideChartRef",ref:l},null,512))}}),KMt="",Aut=vn(Tut,[["__scopeId","data-v-5008746a"]]),Iut={install(n){n.component("st-klineUtils",vut),n.component("st-klineSub",Mut),n.component("st-klineTips",Dut),n.component("st-klineSlide",Aut)}},GMt="",Rut="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjM4NzI1IiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjI2MjUiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNGRjAwMDAiIHAtaWQ9IjI2MjYiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjcwOTMzMyAxNjcuNzIyNjY3YzAuMTI4LTIxLjc2IDkuOTg0LTQyLjY2NjY2NyAyNy4zOTItNTcuOTQxMzM0YTkzLjMxMiA5My4zMTIgMCAwIDEgNjQuNDY5MzM0LTIzLjg5MzMzM0w3NjEuNiA4NS4zMzMzMzNjMjUuNiAwLjU1NDY2NyA0Ny4zNiA4Ljc4OTMzMyA2NC45Mzg2NjcgMjQuNDA1MzM0IDE3LjkyIDE2IDI2Ljg4IDM1LjIgMjYuODggNTcuNDcybC0wLjU1NDY2NyA0MTkuODRjMC4yOTg2NjcgMjIuNjk4NjY3LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuOTIyNjY2LTEyLjYyOTMzMyAyNy4zMDY2NjctMjcuOTQ2NjY3IDQ4Ljg5Ni00NS44MjQgNjQuODk2bC0yMTEuMjQyNjY3IDE4OC4yMDI2NjdjLTE3LjU3ODY2NyAxNS43MDEzMzMtMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45Mzg2NjcgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0Ljk4MTMzMy0yMy41OTQ2NjdsLTIxMS4xNTczMzMtMTg4LjE2Yy0xNy45Mi0xNi4wNDI2NjctMzMuMjgtMzcuNzE3MzMzLTQ1LjkwOTMzNC02NC45ODEzMzMtMTIuNjcyLTI3LjMwNjY2Ny0xOS4wMjkzMzMtNTIuMzk0NjY3LTE5LjAyOTMzMy03NS4zMDY2NjdMMTcwLjY2NjY2NyAxNjcuNzIyNjY3eiBtNDIuNjY2NjY3IDAuMjU2bDAuNTU0NjY3IDQxOC42ODhjMCAxNi4yMTMzMzMgNC44MjEzMzMgMzUuMzI4IDE1LjAxODY2NiA1Ny4zNDQgMTAuMzY4IDIyLjI3MiAyMi4zNTczMzMgMzkuMjEwNjY3IDM1LjYyNjY2NyA1MS4wNzJsMjExLjQxMzMzMyAxODguNDE2YzguOTYgOC4xMDY2NjcgMjEuODg4IDEyLjggMzYuMjI0IDEyLjU0NCAxNS41MzA2NjctMC4wNDI2NjcgMjcuMDkzMzMzLTQuMjY2NjY3IDM2LjY5MzMzNC0xMi44bDIxMS4xNTczMzMtMTg4LjExNzMzNGMxMy4zMTItMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNTg0LTUxLjA3MiAxMC4xMTItMjEuODQ1MzMzIDE0Ljc2MjY2Ny00MC41NzYgMTQuNTA2NjY3LTU3LjA0NTMzM2wwLjU1NDY2Ni00MTkuNzU0NjY3YzAtOS44OTg2NjctMy41ODQtMTcuNjIxMzMzLTEyLjQ1ODY2Ni0yNS42YTU0LjY5ODY2NyA1NC42OTg2NjcgMCAwIDAtMzYuNjA4LTEzLjYxMDY2NmwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NyAxMy4zMTIgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzMgMjEuNDYxMzMzbC0wLjQyNjY2NyA0LjY5MzMzNHoiIGZpbGw9IiNBRTAwMDAiIHAtaWQ9IjI2MjciPjwvcGF0aD48cGF0aCBkPSJNMzg0IDY1NC4xMjI2NjdoMTUzLjUxNDY2N2M5Ni43NjggMCAxNDIuNzYyNjY3LTQ4Ljk4MTMzMyAxNDIuNzYyNjY2LTExNy4wNzczMzQgMC01OS43MzMzMzMtMzMuNDUwNjY3LTg4LjQwNTMzMy04NC44MjEzMzMtOTcuOTYyNjY2di0xLjc5MmM0OC45ODEzMzMtMTUuNTMwNjY3IDY2LjkwMTMzMy00Ni41OTIgNjYuOTAxMzMzLTg5LjYgMC02NS4xMDkzMzMtNDAuNjE4NjY3LTEwMy4zMzg2NjctMTM0Ljk5NzMzMy0xMDMuMzM4NjY3SDM4NHY0MDkuNzcwNjY3eiBtNzIuODc0NjY3LTU0Ljk1NDY2N3YtMTMxLjQxMzMzM2g2Ni4zMDRjNTEuOTY4IDAgODAuMDQyNjY3IDE3LjkyIDgwLjA0MjY2NiA2NS4xMDkzMzMgMCA0NC44LTI2LjI4MjY2NyA2Ni4zMDQtNzUuODYxMzMzIDY2LjMwNGgtNzAuNDg1MzMzeiBtMC0xODAuMzk0NjY3VjI5OC43MDkzMzNoNjAuMzMwNjY2YzQ3LjE4OTMzMyAwIDcyLjI3NzMzMyAxNC45MzMzMzMgNzIuMjc3MzM0IDU5LjEzNiAwIDQ2LjU5Mi0zMi4yNTYgNjAuOTI4LTc1LjI2NCA2MC45MjhoLTU3LjM0NHoiIGZpbGw9IiNGRkZGRkYiIHAtaWQ9IjI2MjgiPjwvcGF0aD48L3N2Zz4=",Out="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjQxNjY0IiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjI3NzciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiM1NEFCMzAiIHAtaWQ9IjI3NzgiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiMzODhEMTQiIHAtaWQ9IjI3NzkiPjwvcGF0aD48cGF0aCBkPSJNNTA2LjQ1MzMzMyA2NzQuNzMwNjY3Yzk5LjE1NzMzMyAwIDE0Ni4zNDY2NjctNDguMzg0IDE0Ni4zNDY2NjctMTI2LjAzNzMzNCAwLTcyLjg3NDY2Ny0zOC44MjY2NjctOTkuNzU0NjY3LTEwMy4zMzg2NjctMTE4LjI3MmwtMzguMjI5MzMzLTExLjk0NjY2NmMtNDAuNjE4NjY3LTExLjM0OTMzMy01Mi41NjUzMzMtMjUuMDg4LTUyLjU2NTMzMy01Ny4zNDQgMC0zMi44NTMzMzMgMjMuODkzMzMzLTUwLjc3MzMzMyA2Ni45MDEzMzMtNTAuNzczMzM0IDQ1LjM5NzMzMyAwIDc4Ljg0OCA5LjU1NzMzMyAxMDQuNTMzMzMzIDIwLjMwOTMzNFYyNzMuMzIyNjY3Yy0yMi42OTg2NjctMTEuOTQ2NjY3LTUxLjk2OC0yMi4xMDEzMzMtMTA1LjcyOC0yMi4xMDEzMzQtOTIuNTg2NjY3IDAtMTM3LjM4NjY2NyA0Ny4xODkzMzMtMTM3LjM4NjY2NiAxMTYuNDggMCA2OS4yOTA2NjcgMzUuMjQyNjY3IDEwMC4zNTIgOTMuMTg0IDExNi40OGwzOC44MjY2NjYgMTAuNzUyYzQ0LjggMTMuNzM4NjY3IDU5LjczMzMzMyAyNi44OCA1OS43MzMzMzQgNjAuOTI4IDAgMzcuMDM0NjY3LTIzLjI5NiA1OS43MzMzMzMtNzguMjUwNjY3IDU5LjczMzMzNC00NC44IDAtODMuNjI2NjY3LTEwLjc1Mi0xMTYuNDgtMjUuMDg4djU3Ljk0MTMzM2MyOC4wNzQ2NjcgMTQuOTMzMzMzIDY4LjY5MzMzMyAyNi4yODI2NjcgMTIyLjQ1MzMzMyAyNi4yODI2Njd6IiBmaWxsPSIjRkZGRkZGIiBwLWlkPSIyNzgwIj48L3BhdGg+PC9zdmc+",Fut="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjI4MjAyIiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjMwNzgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNDODgwRkYiIHAtaWQ9IjMwNzkiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiNBRTQ0RkYiIHAtaWQ9IjMwODAiPjwvcGF0aD48cGF0aCBkPSJNNDc1LjMwNjY2NyA2NTguMjE4NjY3aDczLjQ3MlYzMDYuMzg5MzMzaDExNi40OFYyNDguNDQ4aC0zMDcuNjI2NjY3djU3Ljk0MTMzM2gxMTcuNjc0NjY3eiIgZmlsbD0iI0ZGRkZGRiIgcC1pZD0iMzA4MSI+PC9wYXRoPjwvc3ZnPg==",{round:Put}=bl,B2={minValueSpan:5,maxValueSpan:2e3,loadCheckCount:500,loadAddCount:2e3},But={1:240,2:48,3:16,4:8,5:4,6:1,7:.2,8:.033},wne=({startTime:n,endTime:e,cycle:t,type:i="end"})=>{const{maxValueSpan:r}=B2,o=Math.ceil((r+1e3)/But[t]),s=bt(n);if(bt(e).diff(s,"day")<=o)return[n,e];if(i==="end")return[bt(e).subtract(o,"day").format("YYYY-MM-DD HH:mm:ss"),e];if(i==="middle"){const u=bt((bt(n).valueOf()+bt(e).valueOf())/2).format("YYYY-MM-DD HH:mm:ss");return console.log("超过一屏数量上限, 进行中间时间计算",u,o/2),[bt(u).subtract(o/2,"day").format("YYYY-MM-DD HH:mm:ss"),bt(u).add(o/2,"day").format("YYYY-MM-DD HH:mm:ss")]}},Vut=(n,e)=>{const t=n[e],i=e===0?n[e]:n[e-1];return t[0]===t[1]?t[0]>=i[1]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}:t[1]>t[0]?{color:"transparent",borderColor:"#FF0000"}:{color:"#00FFFF"}},zut=(n,e,t)=>{var r,o,s,a;const i=n.subIndicator.map(l=>{if(l.series==="bar")return{name:"subMain",xAxisIndex:0,yAxisIndex:1,type:"bar",silent:!0,symbol:"none",data:l.data.map((u,d)=>l.seriesColor==="kline"?{value:u,itemStyle:Vut(n.data,d)}:l.seriesColor==="value"?{value:u,itemStyle:{color:u>=0?"#FF0000":"#00FFFF"}}:{value:u,itemStyle:{color:l.seriesColor}})};if(l.series==="line")return{xAxisIndex:0,yAxisIndex:l.yAxis==="right"?2:1,name:l.key,type:"line",silent:!0,symbol:"none",data:l.data,lineStyle:{width:1},itemStyle:{color:l.color}}});return{animation:!1,grid:{top:"10px",left:"60px",right:"20px",bottom:"10px"},dataZoom:[{type:"inside",startValue:e,endValue:t,maxValueSpan:B2.maxValueSpan}],tooltip:{show:!1},axisPointer:{show:!0,triggerTooltip:!1,label:{rich:{},formatter:l=>{const{axisDimension:u,value:d}=l;if(u==="x")return null;if(l.axisIndex===1)return String(Put(d))}}},xAxis:{type:"category",data:n.time,axisLine:{show:!0},splitLine:{show:!1},axisLabel:{show:!1}},yAxis:[{position:"right"},{position:"left",min:((r=n.subIndicator[0])==null?void 0:r.leftYAxisRange)==="cover"?l=>l.min:null,max:((o=n.subIndicator[0])==null?void 0:o.leftYAxisRange)==="cover"?l=>l.max:null,splitNumber:1,axisLine:{show:!0},splitLine:{show:!0,lineStyle:{type:"dotted",color:"#333"}}},{position:"right",min:((s=n.subIndicator[0])==null?void 0:s.rightYAxisRange)==="cover"?l=>l.min:null,max:((a=n.subIndicator[0])==null?void 0:a.rightYAxisRange)==="cover"?l=>l.max:null,splitNumber:1,axisLine:{show:!1},splitLine:{show:!1},axisLabel:{show:!1}}],series:i}},lk=(n,e,t="strict")=>{let i=0,r=n.length-1,o=-1;for(;i<=r;){let s=Math.floor((i+r)/2);if(t==="strict"){if(n[s]===e)return s;n[s]<e?i=s+1:r=s-1}else t==="gte"&&(n[s]>=e?(o=s,r=s-1):i=s+1)}return t==="strict"?-1:o},Hut=n=>{const e=[];return n.reduce((t,i)=>{const r=`${i.coord[0]}+${i.label.position}`,o=i.label.position==="top"?-16:16,s=t.get(r);return s?(t.set(r,s+1),i.symbolOffset[1]=o*(s+1)):(t.set(r,1),i.symbolOffset[1]=i.label.position==="top"?-7:7),e.push(i),t},new Map),e},xne=(n,e)=>({data:[...n.data,...e.data.slice(1)],mainIndicator:n.mainIndicator.map((t,i)=>({...t,data:[...t.data,...e.mainIndicator[i].data.slice(1)]})),subIndicator:n.subIndicator.map((t,i)=>({...t,data:[...t.data,...e.subIndicator[i].data.slice(1)]})),time:[...n.time,...e.time.slice(1)]}),uk=(n,e,t)=>{switch(t){case"5":{let h=[...new Set(n.slice(-20).map(y=>{const v=new Date(y),w=String(v.getHours()).padStart(2,"0"),x=String(v.getMinutes()).padStart(2,"0"),S=String(v.getSeconds()).padStart(2,"0");return`${w}:${x}:${S}`}))];h.includes("00:00:00")&&(h.splice(h.indexOf("00:00:00"),1),h.push("24:00:00")),h=h.sort((y,v)=>new Date(`2000-01-30 ${y}`).getTime()-new Date(`2000-01-30 ${v}`).getTime());const f=new Date(e),p=f.getFullYear(),g=String(f.getMonth()+1).padStart(2,"0"),m=String(f.getDate()).padStart(2,"0"),_=String(f.getHours()).padStart(2,"0"),b=String(f.getMinutes()).padStart(2,"0"),C=String(f.getSeconds()).padStart(2,"0");if(`${_}:${b}:${C}`=="00:00:00")return`${p}-${g}-${m} 01:00:00`;{let y=null;for(let v=0;v<h.length;v++){const w=h[v].split(":");if(+`${w[0]}${w[1]}${w[2]}`>=+`${_}${b}${C}`){y=h[v];break}}if(y==="24:00:00"){const v=new Date(e);v.setDate(v.getDate()+1);const w=v.getFullYear(),x=String(v.getMonth()+1).padStart(2,"0"),S=String(v.getDate()).padStart(2,"0");return`${w}-${x}-${S} 00:00:00`}return`${p}-${g}-${m} ${y}`}}case"6":{const h=new Date(e),f=h.getHours();if(f>=4&&f<21){const p=h.getFullYear(),g=String(h.getMonth()+1).padStart(2,"0"),m=String(h.getDate()).padStart(2,"0");return`${p}-${g}-${m} 09:00:00`}else{const p=new Date(e);p.getHours()>=21&&p.setDate(p.getDate()+1);const g=p.getFullYear(),m=String(p.getMonth()+1).padStart(2,"0"),_=String(p.getDate()).padStart(2,"0"),b=`${g}-${m}-${_} 09:00:00`,C=lk(n,b,"gte");return C===-1?b:n[C]}}case"7":{const h=new Date(e),f=new Date(h);f.setDate(h.getDate()-h.getDay()),f.setHours(0,0,0,0);const p=new Date(f);p.setDate(f.getDate()+5),p.setHours(23,59,59,0);const g=new Date(f);g.setDate(f.getDate()+12),g.setHours(9,0,0,0);const m=h<=p?p:g,_=m.getFullYear(),b=String(m.getMonth()+1).padStart(2,"0"),C=String(m.getDate()).padStart(2,"0");return`${_}-${b}-${C} 09:00:00`}case"8":{const h=new Date(e),f=new Date(h.getFullYear(),h.getMonth()+1,1),p=new Date(f);p.setDate(f.getDate()-1),p.setHours(9,0,0,0);const g=p.getFullYear(),m=String(p.getMonth()+1).padStart(2,"0"),_=String(p.getDate()).padStart(2,"0");return`${g}-${m}-${_} 09:00:00`}}const i=new Date(e),r=i.getFullYear(),o=i.getMonth(),s=i.getDate(),a=i.getHours(),l=i.getMinutes(),u=i.getSeconds(),d=h=>{let f=null;const p=Math.floor(l/h);l%h===0&&u===0?f=l:f=(p+1)*h;const g=Math.floor(f/60),m=a+g,_=f%60,b=new Date(r,o,s,m,_,0),C=N=>String(N).padStart(2,"0"),y=b.getFullYear(),v=C(b.getMonth()+1),w=C(b.getDate()),x=C(b.getHours()),S=C(b.getMinutes());return`${y}-${v}-${w} ${x}:${S}:00`};switch(t){case"1":return d(1);case"2":return d(5);case"3":return d(15);case"4":return d(30);default:throw new Error(`Unsupported cycle: ${e} ${t}`)}},ck=(n,e,t)=>{let i=null,r=null;const[o,s]=e;switch(t){case"6":{i=n.find(a=>new Date(bt(a).format("YYYY-MM-DD 23:59:59")).getTime()>=new Date(o).getTime()),r=n.findLast(a=>new Date(bt(a).format("YYYY-MM-DD 00:00:00")).getTime()<=new Date(s).getTime());break}case"7":{const a=bt(s).endOf("week").add(1,"day").format("YYYY-MM-DD 23:59:59");i=n.find(l=>bt(l).endOf("week").add(1,"day").format("YYYY-MM-DD")===bt(o).endOf("week").add(1,"day").format("YYYY-MM-DD")),r=n.findLast(l=>new Date(l).getTime()<=new Date(a).getTime());break}case"8":{i=n.find(a=>bt(a).format("YYYY-MM")===bt(o).format("YYYY-MM")),r=n.findLast(a=>bt(a).format("YYYY-MM")===bt(s).format("YYYY-MM"));break}default:i=n.find(a=>new Date(a).getTime()>=new Date(o).getTime()),r=n.findLast(a=>new Date(a).getTime()<=new Date(s).getTime())}return[i,r]},jut=(n,e,t,i,r,o)=>{const s=(p,g)=>{const{direction:m="",tradeAction:_="",tradeType:b=""}=p,C=b??m+_;switch(g){case 0:return new Map([["开多","买"],["平多","卖"],["开空","卖"],["平空","买"]]).get(C);case 1:return b??m+_}},a=(p,g,m,_)=>p.reduce((b,C)=>{var D;const y=s(C,0),v=p.filter(L=>L.klineTime===C.klineTime),w=[...new Set(v.map(L=>s(L,0)))];let x=null;w.length>1?x="image://"+new URL("data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjgzNzAzMjI4MjAyIiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9IjMwNzgiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PHBhdGggZD0iTTE5OC4wMTYgMTA5LjczODY2N0E3Ny44NjY2NjcgNzcuODY2NjY3IDAgMCAwIDE3MC42NjY2NjcgMTY3LjY4bDAuNTEyIDQxOC45NDRjMCAyMi44NjkzMzMgNi40IDQ4IDE5LjAyOTMzMyA3NS4zMDY2NjcgMTIuNjcyIDI3LjIyMTMzMyAyNy45ODkzMzMgNDguOTM4NjY3IDQ1Ljk1MiA2NC45Mzg2NjZsMjExLjE1NzMzMyAxODguMjAyNjY3YzE3LjA2NjY2NyAxNS40ODggNDAuNTc2IDIzLjk3ODY2NyA2NC45Mzg2NjcgMjMuNTk0NjY3IDI1LjY4NTMzMy0wLjA4NTMzMyA0Ny4zNi03LjkzNiA2NC45ODEzMzMtMjMuNTk0NjY3bDIxMS4yLTE4OC4yMDI2NjdjMTcuOTItMTYgMzMuMTk0NjY3LTM3LjYzMiA0NS44NjY2NjctNjQuOTM4NjY2IDEyLjY3Mi0yNy4zMDY2NjcgMTguNzczMzMzLTUyLjIyNCAxOC41MTczMzMtNzQuOTIyNjY3TDg1My4zMzMzMzMgMTY3LjI1MzMzM2MwLTIyLjI3Mi04Ljk2LTQxLjQ3Mi0yNi44MzczMzMtNTcuNDcyLTE3LjU3ODY2Ny0xNS42MTYtMzkuMzM4NjY3LTIzLjg5MzMzMy02NC45Mzg2NjctMjQuNDA1MzMzbC00OTkuMDI5MzMzIDAuNDY5MzMzYTkzLjMxMiA5My4zMTIgMCAwIDAtNjQuNTEyIDIzLjg5MzMzNHoiIGZpbGw9IiNDODgwRkYiIHAtaWQ9IjMwNzkiPjwvcGF0aD48cGF0aCBkPSJNMTcwLjY2NjY2NyAxNjcuNjhjMC4xMjgtMjEuNzYgOS45NDEzMzMtNDIuNjY2NjY3IDI3LjM0OTMzMy01Ny45NDEzMzNhOTMuMzEyIDkzLjMxMiAwIDAgMSA2NC41MTItMjMuODkzMzM0TDc2MS41NTczMzMgODUuMzMzMzMzYzI1LjYgMC41NTQ2NjcgNDcuMzYgOC43ODkzMzMgNjQuOTM4NjY3IDI0LjQwNTMzNCAxNy45MiAxNiAyNi44MzczMzMgMzUuMiAyNi44MzczMzMgNTcuNDcybC0wLjUxMiA0MTkuODRjMC4yOTg2NjcgMjIuNjU2LTUuODQ1MzMzIDQ3LjYxNi0xOC41MTczMzMgNzQuODgtMTIuNjcyIDI3LjMwNjY2Ny0yNy45NDY2NjcgNDguOTM4NjY3LTQ1Ljg2NjY2NyA2NC45Mzg2NjZsLTIxMS4yIDE4OC4yMDI2NjdjLTE3LjYyMTMzMyAxNS42NTg2NjctMzkuMjUzMzMzIDIzLjUwOTMzMy02NC45ODEzMzMgMjMuNTk0NjY3YTk0LjcyIDk0LjcyIDAgMCAxLTY0LjkzODY2Ny0yMy41OTQ2NjdsLTIxMS4yLTE4OC4yMDI2NjdjLTE3LjkyLTE2LTMzLjIzNzMzMy0zNy43MTczMzMtNDUuOTA5MzMzLTY0LjkzODY2Ni0xMi42MjkzMzMtMjcuMzA2NjY3LTE5LjAyOTMzMy01Mi40MzczMzMtMTkuMDI5MzMzLTc1LjMwNjY2N0wxNzAuNjY2NjY3IDE2Ny42OHogbTQyLjYyNCAwLjI1NmwwLjU1NDY2NiA0MTguNjg4YzAgMTYuMTcwNjY3IDQuODY0IDM1LjMyOCAxNS4wNjEzMzQgNTcuMzQ0IDEwLjM2OCAyMi4yNzIgMjIuMzE0NjY3IDM5LjE2OCAzNS42MjY2NjYgNTEuMDI5MzMzbDIxMS40MTMzMzQgMTg4LjQxNmM4Ljk2IDguMTA2NjY3IDIxLjg4OCAxMi44IDM2LjIyNCAxMi41ODY2NjcgMTUuNTMwNjY3LTAuMDQyNjY3IDI3LjA5MzMzMy00LjI2NjY2NyAzNi42OTMzMzMtMTIuOGwyMTEuMTE0NjY3LTE4OC4xNmMxMy4zNTQ2NjctMTEuOTQ2NjY3IDI1LjMwMTMzMy0yOC44NDI2NjcgMzUuNjI2NjY2LTUxLjA3MiAxMC4xMTItMjEuNzYgMTQuNzYyNjY3LTQwLjUzMzMzMyAxNC41MDY2NjctNTcuMDAyNjY3TDgxMC42NjY2NjcgMTY3LjIxMDY2N2MwLTkuODk4NjY3LTMuNTg0LTE3LjYyMTMzMy0xMi41MDEzMzQtMjUuNkE1NC42OTg2NjcgNTQuNjk4NjY3IDAgMCAwIDc2MS42IDEyOGwtNDk5LjYyNjY2NyAwLjQ2OTMzM2E1MS4zMjggNTEuMzI4IDAgMCAwLTM1Ljc1NDY2NiAxMy4yNjkzMzQgMzYuNTY1MzMzIDM2LjU2NTMzMyAwIDAgMC0xMi41MDEzMzQgMjEuNTA0bC0wLjQyNjY2NiA0LjY5MzMzM3oiIGZpbGw9IiNBRTQ0RkYiIHAtaWQ9IjMwODAiPjwvcGF0aD48cGF0aCBkPSJNNDc1LjMwNjY2NyA2NTguMjE4NjY3aDczLjQ3MlYzMDYuMzg5MzMzaDExNi40OFYyNDguNDQ4aC0zMDcuNjI2NjY3djU3Ljk0MTMzM2gxMTcuNjc0NjY3eiIgZmlsbD0iI0ZGRkZGRiIgcC1pZD0iMzA4MSI+PC9wYXRoPjwvc3ZnPg==",self.location).href:x="image://"+new URL(Object.assign({"./images/buy.svg":Rut,"./images/sell.svg":Out,"./images/t.svg":Fut})[`./images/${y==="买"?"buy":"sell"}.svg`],self.location).href;const S=lk(m,C.klineTime),N=(D=_[S])==null?void 0:D[3];return g.forEach(L=>{var k;const E=y==="买"?0:1;L.range[E]===C.klineTime&&(L.rangeValue[E]=(k=_[S])==null?void 0:k[y==="买"?2:3])}),b.push({symbol:x,symbolSize:25,symbolRotate:0,symbolOffset:[0,0],label:{show:!1,position:"top"},coord:[C.klineTime,N],silent:!0,animation:!1,customData:{tradeType:y,amount:C.amount,part:C.part,profitAndLoss:C.profitAndLoss,openPriceAll:C.openPriceAll,closePriceAll:C.closePriceAll}}),b},[]),l=(p,g,m,_)=>{const{sellBuyByPrice:b}=o,C=p.reduce((y,v,w)=>{var D,L;const x=s(v,1),S=["开多","开空"].includes(x)?"top":"bottom";let N=null;if(b)N=S==="top"?(v.openPriceAll/v.amount).toFixed(2):(v.closePriceAll/v.amount).toFixed(2);else{const E=lk(m,v.klineTime);N=S==="top"?(D=_[E])==null?void 0:D[3]:(L=_[E])==null?void 0:L[2]}return g.forEach(E=>{(S==="top"?E.range[0]:E.range[1])===v.klineTime&&(E.rangeValue[S==="top"?0:1]=N)}),y.push({symbol:"triangle",symbolSize:[10,12],symbolRotate:S==="top"?180:0,symbolOffset:[0,0],label:{show:!0,position:S,color:"#fff",formatter:`${x} ${S==="top"?"+":"-"} ${v.amount}手 ${v.part?`(${v.part}份)`:""}`},itemStyle:{color:S==="top"?"#FF0000":"#389e0d"},coord:[v.klineTime,N],silent:!0,animation:!1,customData:{tradeType:x,amount:v.amount,part:v.part,profitAndLoss:v.profitAndLoss,openPriceAll:v.openPriceAll,closePriceAll:v.closePriceAll}}),y},[]);return b?C:Hut(C)},u=(p,g,m)=>{const{basePointData:_,baseLineData:b}=p.reduce((w,x)=>{const S={pointTime:x.openTime,tradeAction:"开",tradeDirection:x.tradeDirection?"空":"多",tradeType:`开${x.tradeDirection?"空":"多"}`,part:null,amount:x.tradeVolume,profitAndLoss:x.profitAndLoss,openPriceAll:x.openPrice*x.tradeVolume,closePriceAll:x.closePrice*x.tradeVolume,klineTime:uk(m,x.openTime,g)},N={pointTime:x.closeTime,tradeAction:"平",tradeDirection:x.tradeDirection?"空":"多",tradeType:`平${x.tradeDirection?"空":"多"}`,part:null,amount:x.tradeVolume,profitAndLoss:x.profitAndLoss,openPriceAll:x.openPrice*x.tradeVolume,closePriceAll:x.closePrice*x.tradeVolume,klineTime:uk(m,x.closeTime,g)},D={range:[S.klineTime,N.klineTime],rangeValue:[null,null],color:N.profitAndLoss>0?"#FF0000":"#389e0d"};return w.basePointData.push(S,N),w.baseLineData.push(D),w},{basePointData:[],baseLineData:[]}),y=[..._.reduce((w,x)=>{const S=JSON.parse(JSON.stringify(x)),N=S.klineTime+S.tradeType;if(w.has(N)){const D=w.get(N);S.amount+=D.amount,S.part+=D.part,S.profitAndLoss+=D.profitAndLoss,S.openPriceAll+=D.openPriceAll,S.closePriceAll+=D.closePriceAll}return w.set(N,S),w},new Map([])).values()].sort((w,x)=>new Date(w.klineTime)-new Date(x.klineTime)),v=b.filter(({range:w})=>w[0]!==w[1]);return{pointData:y,lineData:v}},{pointData:d,lineData:h}=u(n,e,i);return{tradePointData:(t===0?a:l)(d,h,i,r),tradeLineData:h.map(({range:p,rangeValue:g,color:m})=>[{symbol:"none",coord:[p[0],g[0]],lineStyle:{color:m,width:2,type:"solid"},silent:!0,animation:!1},{symbol:"none",coord:[p[1],g[1]],silent:!0,animation:!1}])}},Wut=(n,e)=>{let t=[];if(Number(e)<=5)t=n.map(({tradeDate:i,netPositionValue:r})=>[bt(i).format("YYYY-MM-DD HH:mm:ss"),r]);else if(Number(e)===6){const i=n.reduce((r,o)=>{const{tradeDate:s,netPositionValue:a}=o;return r.set(bt(s).format("YYYY-MM-DD 09:00:00"),a),r},new Map);t=Array.from(i,([r,o])=>[r,o])}else t=[];return{netPositionLineData:t}},$ut=(n,e,t,i)=>{let r=[];if(["6","7","8"].includes(e)){const o=n.reduce((s,a)=>{const l=uk(i,a.date,e),u=a[t===0?"simple":"compound"];return s.set(l,u),s},new Map);r=Array.from(o,([s,a])=>[s,a])}else r=[];return{tradeIncomeRateLineData:r}},YMt="",Uut={class:"tips"},dk=vn({__name:"Tips",props:{data:{type:Array,default:()=>[]}},setup(n){return(e,t)=>(c.openBlock(),c.createElementBlock("div",Uut,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(n.data,(i,r)=>(c.openBlock(),c.createElementBlock("span",{key:r,class:"item",style:c.normalizeStyle({color:i.color})},c.toDisplayString(i.label)+" "+c.toDisplayString(i.value),5))),128))]))}},[["__scopeId","data-v-df1caefe"]]),ZMt="",qut=vn({__name:"SliderChart",props:{screenTimeRange:{type:Array,required:!0},varietyCode:{type:String,required:!0},varietyStock:{type:Number,required:!0},rightType:{type:[Number,null],default:null},klineType:{type:[Number,null],default:null},deleteFirstNumber:{type:Number,default:1},withoutPermission:{type:Number,default:0}},emits:["change"],setup(n,{expose:e,emit:t}){const{request:i}=c.inject("stConfig");let r=null;const o=c.ref(null),s=t,a=n,l=c.ref({data:[],mainIndicator:[],subIndicator:[],time:[]}),u=async()=>{const p={varietyCode:a.varietyCode,cycle:"6",right:a.varietyStock===1?a.rightType:0,contractType:a.varietyStock?null:a.klineType,startTime:"1999-01-01 00:00:00",endTime:bt().format("YYYY-MM-DD 23:59:59"),deleteFirstNumber:a.deleteFirstNumber,withoutPermission:a.withoutPermission},{body:g}=await i.post("/middleLayer/kline/getKline",p);g?l.value=g:l.value={data:[],mainIndicator:[],subIndicator:[],time:[]},f("init")},d=F2(p=>{if(!p.dataZoomId)return;const g=r.getOption();if(g!=null&&g.dataZoom[0]){const{startValue:m,endValue:_}=r.getOption().dataZoom[0],{time:b}=l.value,C=`${b[m].split(" ")[0]} 00:00:00`,y=`${b[_].split(" ")[0]} 23:59:59`;console.log(`检测到拖拽轴被拖动, 时间区间: ${C} - ${y}`),s("change",{startTime:C,endTime:y})}},200),h=F2(({startTime:p,endTime:g})=>{f("reset",{startTime:p,endTime:g})},100),f=(p,g)=>{switch(p){case"init":{const{data:m,time:_}=l.value,{xAxisData:b,lineData:C}=m.reduce((v,w,x)=>(v.xAxisData.push(_[x].split(" ")[0]),v.lineData.push(w[1]),v),{xAxisData:[],lineData:[]}),y={grid:{height:0,left:"100px",right:"80px"},xAxis:{type:"category",data:b,show:!1},yAxis:{type:"value"},dataZoom:[{show:!0,startValue:0,endValue:0,textStyle:{color:"#ccc"}},{type:"inside",startValue:0,endValue:0}],series:[{data:C,type:"line"}]};if(r.setOption(y,!0),a.screenTimeRange.length){const[v,w]=a.screenTimeRange;h({startTime:v,endTime:w})}break}case"reset":{const{time:m}=l.value,_=bt(g.startTime).format("YYYY-MM-DD"),b=bt(g.endTime).format("YYYY-MM-DD");let C=-1,y=-1;for(let v=0;v<m.length;v++){const w=bt(m[v]).format("YYYY-MM-DD");if(C!==-1&&y!==-1)break;C===-1&&(new Date(w)===new Date(_)?C=v:new Date(w)>new Date(_)&&(C=v-1)),y===-1&&(new Date(w)===new Date(b)?y=v:new Date(w)>new Date(b)&&(y=v-1))}y===-1&&(y=m.length-1),r.dispatchAction({type:"dataZoom",startValue:C,endValue:y});break}}};return c.onMounted(()=>{c.nextTick(()=>{r=qr.init(o.value),r.on("datazoom",d),u()})}),c.watch(()=>a.screenTimeRange,p=>{const[g,m]=p;h({startTime:g,endTime:m})},{deep:!0}),c.onUnmounted(()=>{r.off("datazoom"),r.dispose()}),e({resize:F2(()=>r.resize(),100)}),(p,g)=>(c.openBlock(),c.createElementBlock("div",{class:"chart",ref_key:"sliderChartRef",ref:o},null,512))}},[["__scopeId","data-v-0c715da1"]]),JMt="",Kut={class:"main-chart"},Gut={class:"indicator"},Yut={key:0,class:"screen-time-range"},Qut={key:0,class:"sub-chart"},Zut={class:"indicator"},Xut={class:"title"},Jut={key:1,class:"slider-chart"},ect=vn({__name:"index",props:{varietyCode:{type:String,required:!0},varietyStock:{type:Number,required:!0},indicatorStore:{type:Object,required:!0},userKlineConfig:{type:Object,required:!0},cycle:{type:String,required:!0},sellBuy:{type:Number,default:1},rightType:{type:[Number,null],default:null},klineType:{type:[Number,null],default:null},incomeType:{type:Number,default:0},initTimeRange:{type:Array,required:!0},mainIndicator:{type:String,required:!0},tradeLog:{type:Array,default:()=>[]},netPositionData:{type:Array,default:()=>[]},tradeIncomeRateData:{type:Array,default:()=>[]},positionTime:{type:[String,null],default:null},syncBrushRange:{type:Object,default:()=>({cycleList:[],startTime:null,endTime:null})},deleteFirstNumber:{type:Number,default:1},withoutPermission:{type:Number,default:0}},setup(n,{expose:e}){const{round:t,formatValue:i}=bl,{request:r}=c.inject("stConfig"),o=c.ref(),s=c.ref(!1),a=c.ref(!1),l=n;let u=!1,d=!1,h=!1,f=!1,p=null,g=null,m=null;const _=c.ref(null),b=c.ref(null),C=c.ref({data:[],mainIndicator:[],subIndicator:[],time:[]}),y=c.ref(0),v=c.ref([]),w=c.ref(null),x=c.ref("VOL"),S=c.computed(()=>{const O=C.value.data[y.value];if(!O)return[{label:"开",value:"-"},{label:"高",value:"-"},{label:"低",value:"-"},{label:"收",value:"-"},{label:"额",value:"-"},{label:"涨跌",value:"-"}];const F=[{label:"开",value:t(O[0])},{label:"高",value:t(O[3])},{label:"低",value:t(O[2])},{label:"收",value:t(O[1])}];O[4]!==null&&F.push({label:"额",value:i(O[4])});let $;return O[6]>0?$="red":O[6]<0&&($="green"),F.push({label:"涨跌",value:`${t(O[6])}%`,color:$}),F}),N=c.computed(()=>{var O,F;return((F=(O=C.value)==null?void 0:O.mainIndicator)==null?void 0:F.map($=>({label:$.key,value:t($.data[y.value]),color:$.color})))||[]}),D=c.computed(()=>{var O,F;return((F=(O=C.value)==null?void 0:O.subIndicator)==null?void 0:F.map($=>({label:$.key,color:$.color,value:$.data[y.value]||"-"})))||[]}),L=()=>{m||(m=qr.init(b.value),m.on("highlight",F2(O=>{var F;O.dataIndex?y.value=O.dataIndex:y.value=((F=O.batch)==null?void 0:F[0].dataIndex)??-1},10)),m.on("datazoom",F2(async()=>{var Y;const{loadCheckCount:O}=B2,{startValue:F,endValue:$}=((Y=m.getOption())==null?void 0:Y.dataZoom[0])??{};h===!1&&f===!1&&F<O&&await k("history"),u===!1&&d===!1&&$>C.value.time.length-O&&await k("new"),A(),B()})),m.on("globalout",()=>{const O=m.getOption();y.value=O.dataZoom[0].endValue}),m.getZr().on("contextmenu",()=>{var O;w.value=(O=C.value)==null?void 0:O.time[y.value]}),window.addEventListener("keydown",M),l.userKlineConfig.enable_subChart&&(g=qr.init(_.value),qr.connect([m,g])),p=hJ(b.value),p.listen(()=>{requestAnimationFrame(()=>{var O;m.resize(),g==null||g.resize(),(O=o.value)==null||O.resize()})}))},E=async({startTime:O,endTime:F})=>{h=!1,f=!1,u=!1,d=!1;try{s.value=!0;const $={varietyCode:l.varietyCode,cycle:l.cycle,right:l.varietyStock===1?l.rightType:0,contractType:l.varietyStock?null:l.klineType,mainIndicatorList:l.indicatorStore.getIndicatorParams(l.mainIndicator),subIndicator:x.value,deleteFirstNumber:l.deleteFirstNumber,withoutPermission:l.withoutPermission};["1","2","3","4","5"].includes(l.cycle)?Object.assign($,{startTime:bt(O).subtract(1,"day").format("YYYY-MM-DD HH:mm:ss"),endTime:bt(F).add(1,"day").format("YYYY-MM-DD HH:mm:ss")}):["6","7"].includes(l.cycle)?Object.assign($,{startTime:bt(O).subtract(50,"day").format("YYYY-MM-DD HH:mm:ss"),endTime:bt(F).add(50,"day").format("YYYY-MM-DD HH:mm:ss")}):Object.assign($,{startTime:bt(O).subtract(10,"month").format("YYYY-MM-DD HH:mm:ss"),endTime:bt(F).add(10,"month").format("YYYY-MM-DD HH:mm:ss")});const{body:Y}=await r.post("/middleLayer/kline/getKline",$);C.value=Y??{data:[],mainIndicator:[],subIndicator:[],time:[]};let U=-1,z=-1;for(let ne=0;ne<C.value.time.length;ne++){const le=bt(C.value.time[ne]).format("YYYY-MM-DD");if(U!==-1&&z!==-1)break;U===-1&&(new Date(le)===new Date(O)?U=ne:new Date(le)>new Date(O)&&(U=ne-1)),z===-1&&(new Date(le)===new Date(F)?z=ne:new Date(le)>new Date(F)&&(z=ne-1))}z===-1&&(z=C.value.time.length-1),R({startValue:U===-1?0:U,endValue:z===-1?C.value.time.length-1:z})}finally{s.value=!1}},k=async O=>{var le,ue;const{loadAddCount:F}=B2;switch(O){case"history":{h=!0;const X={varietyCode:l.varietyCode,cycle:l.cycle,right:l.varietyStock===1?l.rightType:0,contractType:l.varietyStock?null:l.klineType,endTime:C.value.time[0],limit:F,mainIndicatorList:l.indicatorStore.getIndicatorParams(l.mainIndicator),subIndicator:x.value,deleteFirstNumber:l.deleteFirstNumber,withoutPermission:l.withoutPermission},{body:oe}=await r.post("/middleLayer/kline/getKline",X);C.value=xne(oe,C.value),oe.data.length<F&&(console.log("[K线] 获取更多数据: 左侧已全部获取完毕, 关闭"),f=!0),h=!1;break}case"new":{u=!0;const X={varietyCode:l.varietyCode,cycle:l.cycle,right:l.varietyStock===1?l.rightType:0,contractType:l.varietyStock?null:l.klineType,startTime:C.value.time[C.value.time.length-1],limit:F,mainIndicatorList:l.indicatorStore.getIndicatorParams(l.mainIndicator),subIndicator:x.value,deleteFirstNumber:l.deleteFirstNumber,withoutPermission:l.withoutPermission},{body:oe}=await r.post("/middleLayer/kline/getKline",X);C.value=xne(C.value,oe),oe.data.length<F&&(console.log("[K线] 获取更多数据: 右侧已全部获取完毕, 关闭"),d=!0),u=!1;break}}const{startValue:$,endValue:Y}=((le=m.getOption())==null?void 0:le.dataZoom[0])??{},U=(ue=m.getOption())==null?void 0:ue.xAxis[0].data,z=C.value.time.findIndex(X=>new Date(X)>=new Date(U[$])),ne=C.value.time.findIndex(X=>new Date(X)>=new Date(U[Y]));R({startValue:z===-1?0:z,endValue:ne===-1?C.value.time.length-1:ne})},A=()=>{var z;if(!C.value.time.length)return v.value=[];const{time:O}=C.value,{startValue:F,endValue:$}=((z=m.getOption())==null?void 0:z.dataZoom[0])??{},Y=O[F],U=O[$];["6","7","8"].includes(l.cycle)?v.value=[bt(Y).format("YYYY-MM-DD"),bt(U).format("YYYY-MM-DD")]:v.value=[Y,U]},R=(O={startValue:0,endValue:0})=>{L();const{maxValueSpan:F}=B2,{time:$,data:Y,mainIndicator:U}=C.value,z=O.endValue-O.startValue>F?O.endValue-F:O.startValue,ne=O.endValue,le=U.map(pe=>({name:pe.key,type:"line",silent:!0,symbol:"none",data:pe.data,lineStyle:{width:pe.width||1},itemStyle:{color:pe.color}})),{netPositionLineData:ue}=Wut(l.netPositionData,l.cycle),{tradeIncomeRateLineData:X}=$ut(l.tradeIncomeRateData,l.cycle,l.incomeType,$),{tradePointData:oe,tradeLineData:de}=jut(l.tradeLog,l.cycle,l.sellBuy,$,Y,l.userKlineConfig);m.setOption({animation:!1,grid:{top:"40px",left:"60px",right:"20px",bottom:"20px"},dataZoom:[{type:"inside",startValue:z,endValue:ne,minValueSpan:B2.minValueSpan,maxValueSpan:B2.maxValueSpan}],tooltip:{trigger:"axis",appendToBody:!0,confine:!0,axisPointer:{type:"cross",label:{rich:{},formatter:pe=>{const{axisDimension:he,value:ve}=pe;return he==="x"?["6","7","8"].includes(l.cycle)?bt(ve).format("YYYY-MM-DD"):ve:String(t(ve))}}},formatter:pe=>{if(!(pe!=null&&pe.length))return null;let he="";if(pe.forEach(Le=>{if(Le.seriesName==="netPosition"&&Le.data!==null&&(he+=`<div>资产持仓净值: ${Le.data[1]}</div>`),Le.componentSubType==="candlestick")if(l.sellBuy===0){const re=oe.filter(te=>(te==null?void 0:te.coord[0])===Le.axisValue);let W=0,ee=0;re.forEach(te=>{const{tradeType:J,amount:ie}=te.customData;J==="买"&&(W+=ie),J==="卖"&&(ee+=ie)}),W&&(he+=`<div>买: ${W}</div>`),ee&&(he+=`<div>卖: ${ee}</div>`)}else oe.forEach(re=>{if((re==null?void 0:re.coord[0])===Le.axisValue){const{tradeType:W,amount:ee,profitAndLoss:te,openPriceAll:J,closePriceAll:ie}=re.customData;let G=`<div>${W}: ${ee}手</div>`;if(W.includes("开")&&(G+=`<div>开仓价: ${(J/ee).toFixed(2)}</div>`),W.includes("平")){const Q=(J/ee).toFixed(2),Z=(ie/ee).toFixed(2);G+=`<div>平仓价: ${Z}</div>`,G+=`<div>盈亏: ${te==null?void 0:te.toFixed(2)}</div>`,G+=`<div>盈亏比率: ${((Z-Q)/Q*100).toFixed(2)} %</div>`}he+=G}})}),!he)return null;let ve=pe[0].axisValue;return["6","7","8"].includes(l.cycle)&&(ve=bt(ve).format("YYYY-MM-DD")),`
143
143
  <div>