openc3-cosmos-tool-dataviewer 5.12.0 → 5.13.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/tools/dataviewer/js/176.js +2 -0
- data/tools/dataviewer/js/176.js.map +1 -0
- data/tools/dataviewer/js/797.js +10 -0
- data/tools/dataviewer/js/797.js.map +1 -0
- data/tools/dataviewer/js/app.js +1 -1
- data/tools/dataviewer/js/app.js.map +1 -1
- metadata +6 -6
- data/tools/dataviewer/js/202.js +0 -10
- data/tools/dataviewer/js/202.js.map +0 -1
- data/tools/dataviewer/js/325.js +0 -2
- data/tools/dataviewer/js/325.js.map +0 -1
data/tools/dataviewer/js/325.js
DELETED
@@ -1,2 +0,0 @@
|
|
1
|
-
(self["webpackChunk_openc3_cosmos_tool_dataviewer"]=self["webpackChunk_openc3_cosmos_tool_dataviewer"]||[]).push([[325],{3325:(e,n,t)=>{"use strict";function l(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DataViewer.vue",n="80cd0b01ddf4df9a2c8cf45c816e95e73fd50a30",t=new Function("return this")(),o="__coverage__",i={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DataViewer.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:6428}},4:{start:{line:1,column:395},end:{line:1,column:412}},5:{start:{line:1,column:649},end:{line:1,column:666}},6:{start:{line:1,column:905},end:{line:1,column:920}},7:{start:{line:1,column:1168},end:{line:1,column:1183}},8:{start:{line:1,column:1951},end:{line:1,column:1966}},9:{start:{line:1,column:2170},end:{line:1,column:2183}},10:{start:{line:1,column:2378},end:{line:1,column:2403}},11:{start:{line:1,column:2602},end:{line:1,column:2616}},12:{start:{line:1,column:2686},end:{line:1,column:2852}},13:{start:{line:1,column:2770},end:{line:1,column:2795}},14:{start:{line:1,column:3154},end:{line:1,column:3168}},15:{start:{line:1,column:3237},end:{line:1,column:4065}},16:{start:{line:1,column:3585},end:{line:1,column:3611}},17:{start:{line:1,column:3854},end:{line:1,column:3873}},18:{start:{line:1,column:4456},end:{line:1,column:4474}},19:{start:{line:1,column:4692},end:{line:1,column:4710}},20:{start:{line:1,column:4855},end:{line:1,column:4876}},21:{start:{line:1,column:5207},end:{line:1,column:5225}},22:{start:{line:1,column:5843},end:{line:1,column:5862}},23:{start:{line:1,column:6345},end:{line:1,column:6375}},24:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:379},end:{line:1,column:380}},loc:{start:{line:1,column:394},end:{line:1,column:413}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:633},end:{line:1,column:634}},loc:{start:{line:1,column:648},end:{line:1,column:667}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:889},end:{line:1,column:890}},loc:{start:{line:1,column:904},end:{line:1,column:921}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:1152},end:{line:1,column:1153}},loc:{start:{line:1,column:1167},end:{line:1,column:1184}},line:1},5:{name:"(anonymous_5)",decl:{start:{line:1,column:1935},end:{line:1,column:1936}},loc:{start:{line:1,column:1950},end:{line:1,column:1967}},line:1},6:{name:"(anonymous_6)",decl:{start:{line:1,column:2154},end:{line:1,column:2155}},loc:{start:{line:1,column:2169},end:{line:1,column:2184}},line:1},7:{name:"(anonymous_7)",decl:{start:{line:1,column:2362},end:{line:1,column:2363}},loc:{start:{line:1,column:2377},end:{line:1,column:2404}},line:1},8:{name:"(anonymous_8)",decl:{start:{line:1,column:2586},end:{line:1,column:2587}},loc:{start:{line:1,column:2601},end:{line:1,column:2617}},line:1},9:{name:"(anonymous_9)",decl:{start:{line:1,column:2666},end:{line:1,column:2667}},loc:{start:{line:1,column:2685},end:{line:1,column:2853}},line:1},10:{name:"(anonymous_10)",decl:{start:{line:1,column:2759},end:{line:1,column:2760}},loc:{start:{line:1,column:2770},end:{line:1,column:2795}},line:1},11:{name:"(anonymous_11)",decl:{start:{line:1,column:3138},end:{line:1,column:3139}},loc:{start:{line:1,column:3153},end:{line:1,column:3169}},line:1},12:{name:"(anonymous_12)",decl:{start:{line:1,column:3217},end:{line:1,column:3218}},loc:{start:{line:1,column:3236},end:{line:1,column:4066}},line:1},13:{name:"(anonymous_13)",decl:{start:{line:1,column:3579},end:{line:1,column:3580}},loc:{start:{line:1,column:3585},end:{line:1,column:3611}},line:1},14:{name:"(anonymous_14)",decl:{start:{line:1,column:3841},end:{line:1,column:3842}},loc:{start:{line:1,column:3854},end:{line:1,column:3873}},line:1},15:{name:"(anonymous_15)",decl:{start:{line:1,column:4440},end:{line:1,column:4441}},loc:{start:{line:1,column:4455},end:{line:1,column:4475}},line:1},16:{name:"(anonymous_16)",decl:{start:{line:1,column:4676},end:{line:1,column:4677}},loc:{start:{line:1,column:4691},end:{line:1,column:4711}},line:1},17:{name:"(anonymous_17)",decl:{start:{line:1,column:4839},end:{line:1,column:4840}},loc:{start:{line:1,column:4854},end:{line:1,column:4877}},line:1},18:{name:"(anonymous_18)",decl:{start:{line:1,column:5191},end:{line:1,column:5192}},loc:{start:{line:1,column:5206},end:{line:1,column:5226}},line:1},19:{name:"(anonymous_19)",decl:{start:{line:1,column:5827},end:{line:1,column:5828}},loc:{start:{line:1,column:5842},end:{line:1,column:5863}},line:1},20:{name:"(anonymous_20)",decl:{start:{line:1,column:6329},end:{line:1,column:6330}},loc:{start:{line:1,column:6344},end:{line:1,column:6376}},line:1}},branchMap:{0:{loc:{start:{line:1,column:789},end:{line:1,column:828}},type:"cond-expr",locations:[{start:{line:1,column:803},end:{line:1,column:823}},{start:{line:1,column:826},end:{line:1,column:828}}],line:1},1:{loc:{start:{line:1,column:1052},end:{line:1,column:1091}},type:"cond-expr",locations:[{start:{line:1,column:1066},end:{line:1,column:1086}},{start:{line:1,column:1089},end:{line:1,column:1091}}],line:1},2:{loc:{start:{line:1,column:1280},end:{line:1,column:1638}},type:"cond-expr",locations:[{start:{line:1,column:1294},end:{line:1,column:1438}},{start:{line:1,column:1439},end:{line:1,column:1638}}],line:1},3:{loc:{start:{line:1,column:1718},end:{line:1,column:1767}},type:"binary-expr",locations:[{start:{line:1,column:1718},end:{line:1,column:1729}},{start:{line:1,column:1733},end:{line:1,column:1742}},{start:{line:1,column:1746},end:{line:1,column:1767}}],line:1},4:{loc:{start:{line:1,column:2909},end:{line:1,column:2959}},type:"cond-expr",locations:[{start:{line:1,column:2940},end:{line:1,column:2954}},{start:{line:1,column:2957},end:{line:1,column:2959}}],line:1},5:{loc:{start:{line:1,column:3906},end:{line:1,column:4053}},type:"cond-expr",locations:[{start:{line:1,column:3941},end:{line:1,column:4044}},{start:{line:1,column:4045},end:{line:1,column:4053}}],line:1},6:{loc:{start:{line:1,column:4083},end:{line:1,column:4271}},type:"cond-expr",locations:[{start:{line:1,column:4109},end:{line:1,column:4262}},{start:{line:1,column:4263},end:{line:1,column:4271}}],line:1},7:{loc:{start:{line:1,column:4288},end:{line:1,column:4511}},type:"cond-expr",locations:[{start:{line:1,column:4305},end:{line:1,column:4502}},{start:{line:1,column:4503},end:{line:1,column:4511}}],line:1},8:{loc:{start:{line:1,column:4524},end:{line:1,column:4747}},type:"cond-expr",locations:[{start:{line:1,column:4541},end:{line:1,column:4738}},{start:{line:1,column:4739},end:{line:1,column:4747}}],line:1},9:{loc:{start:{line:1,column:6126},end:{line:1,column:6424}},type:"cond-expr",locations:[{start:{line:1,column:6155},end:{line:1,column:6415}},{start:{line:1,column:6416},end:{line:1,column:6424}}],line:1}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"80cd0b01ddf4df9a2c8cf45c816e95e73fd50a30"},a=t[o]||(t[o]={});a[e]&&a[e].hash===n||(a[e]=i);var s=a[e];return l=function(){return s},s}t.r(n),t.d(n,{default:()=>Oe}),l(),l().s[0]++;var o=function(){l().f[0]++;var e=(l().s[1]++,this),n=(l().s[2]++,e._self._c);return l().s[3]++,n("div",[n("top-bar",{attrs:{menus:e.menus,title:e.title}}),e._v(" "),n("v-card",[n("v-container",[n("v-row",{attrs:{dense:""}},[n("v-col",[n("v-text-field",{attrs:{label:"Start Date",type:"date",rules:[e.rules.required],"data-test":"start-date"},model:{value:e.startDate,callback:function(n){l().f[1]++,l().s[4]++,e.startDate=n},expression:"startDate"}})],1),e._v(" "),n("v-col",[n("v-text-field",{attrs:{label:"Start Time",type:"time",step:"1",rules:[e.rules.required],"data-test":"start-time"},model:{value:e.startTime,callback:function(n){l().f[2]++,l().s[5]++,e.startTime=n},expression:"startTime"}})],1),e._v(" "),n("v-col",[n("v-text-field",{attrs:{label:"End Date",type:"date",rules:e.endTime?(l().b[0][0]++,[e.rules.required]):(l().b[0][1]++,[]),"data-test":"end-date"},model:{value:e.endDate,callback:function(n){l().f[3]++,l().s[6]++,e.endDate=n},expression:"endDate"}})],1),e._v(" "),n("v-col",[n("v-text-field",{attrs:{label:"End Time",type:"time",step:"1",rules:e.endDate?(l().b[1][0]++,[e.rules.required]):(l().b[1][1]++,[]),"data-test":"end-time"},model:{value:e.endTime,callback:function(n){l().f[4]++,l().s[7]++,e.endTime=n},expression:"endTime"}})],1),e._v(" "),n("v-col",{staticClass:"pt-4",attrs:{cols:"auto"}},[e.running?(l().b[2][0]++,n("v-btn",{attrs:{color:"primary",width:"100","data-test":"stop-button"},on:{click:e.stop}},[e._v("\n Stop\n ")])):(l().b[2][1]++,n("v-btn",{staticClass:"pulse-button",attrs:{disabled:!e.canStart,color:"primary",width:"100","data-test":"start-button"},on:{click:e.start}},[e._v("\n Start\n ")]))],1)],1),e._v(" "),n("div",{directives:[{name:"show",rawName:"v-show",value:(l().b[3][0]++,e.warning||(l().b[3][1]++,e.error)||(l().b[3][2]++,e.connectionFailure)),expression:"warning || error || connectionFailure"}],staticClass:"mb-3"},[n("v-alert",{attrs:{type:"warning",dismissible:""},model:{value:e.warning,callback:function(n){l().f[5]++,l().s[8]++,e.warning=n},expression:"warning"}},[e._v("\n "+e._s(e.warningText)+"\n ")]),e._v(" "),n("v-alert",{attrs:{type:"error",dismissible:""},model:{value:e.error,callback:function(n){l().f[6]++,l().s[9]++,e.error=n},expression:"error"}},[e._v("\n "+e._s(e.errorText)+"\n ")]),e._v(" "),n("v-alert",{attrs:{type:"error"},model:{value:e.connectionFailure,callback:function(n){l().f[7]++,l().s[10]++,e.connectionFailure=n},expression:"connectionFailure"}},[e._v("\n OpenC3 backend connection failed.\n ")])],1)],1),e._v(" "),n("v-tabs",{ref:"tabs",model:{value:e.curTab,callback:function(n){l().f[8]++,l().s[11]++,e.curTab=n},expression:"curTab"}},[e._l(e.config.tabs,(function(t,o){return l().f[9]++,l().s[12]++,n("v-tab",{key:o,attrs:{"data-test":"tab"},on:{contextmenu:n=>(l().f[10]++,l().s[13]++,e.tabMenu(n,o))}},[e._v("\n "+e._s(t.tabName)+"\n ")])})),e._v(" "),n("v-btn",{staticClass:"mt-2 ml-2",class:0===e.config.tabs.length?(l().b[4][0]++,"pulse-button"):(l().b[4][1]++,""),attrs:{icon:"","data-test":"new-tab"},on:{click:e.addTab}},[n("v-icon",[e._v("mdi-tab-plus")])],1)],2),e._v(" "),n("v-tabs-items",{model:{value:e.curTab,callback:function(n){l().f[11]++,l().s[14]++,e.curTab=n},expression:"curTab"}},e._l(e.config.tabs,(function(t,o){return l().f[12]++,l().s[15]++,n("v-tab-item",{key:t.ref,attrs:{eager:""}},[n("keep-alive",[n("v-card",{attrs:{flat:""}},[n("v-divider"),e._v(" "),n("v-card-title",{staticClass:"pa-3"},[n("span",{domProps:{textContent:e._s(t.name)}}),e._v(" "),n("v-spacer"),e._v(" "),n("v-btn",{attrs:{icon:"","data-test":"delete-component"},on:{click:()=>(l().f[13]++,l().s[16]++,e.deleteComponent(o))}},[n("v-icon",{attrs:{color:"red"}},[e._v("mdi-delete")])],1)],1),e._v(" "),n(t.type,e._g({ref:t.ref,refInFor:!0,tag:"component",attrs:{name:t.component,config:t.config,packets:t.packets},on:{config:e=>(l().f[14]++,l().s[17]++,t.config=e)}},e.$listeners)),e._v(" "),0===e.receivedPackets.length?(l().b[5][0]++,n("v-card-text",[e._v("\n No data! Make sure to hit the START button!\n ")])):(l().b[5][1]++,e._e())],1)],1)],1)})),1),e._v(" "),e.config.tabs.length?(l().b[6][1]++,e._e()):(l().b[6][0]++,n("v-card",[n("v-card-title",[e._v("You're not viewing any packets")]),e._v(" "),n("v-card-text",[e._v("Click the new tab icon to start.")])],1))],1),e._v(" "),e.openConfig?(l().b[7][0]++,n("open-config-dialog",{attrs:{configKey:e.configKey},on:{success:e.openConfiguration},model:{value:e.openConfig,callback:function(n){l().f[15]++,l().s[18]++,e.openConfig=n},expression:"openConfig"}})):(l().b[7][1]++,e._e()),e._v(" "),e.saveConfig?(l().b[8][0]++,n("save-config-dialog",{attrs:{configKey:e.configKey},on:{success:e.saveConfiguration},model:{value:e.saveConfig,callback:function(n){l().f[16]++,l().s[19]++,e.saveConfig=n},expression:"saveConfig"}})):(l().b[8][1]++,e._e()),e._v(" "),n("v-dialog",{attrs:{width:"600"},model:{value:e.tabNameDialog,callback:function(n){l().f[17]++,l().s[20]++,e.tabNameDialog=n},expression:"tabNameDialog"}},[n("v-card",[n("v-system-bar",[n("v-spacer"),e._v(" "),n("span",[e._v(" DataViewer: Rename Tab")]),e._v(" "),n("v-spacer")],1),e._v(" "),n("v-card-text",[n("v-text-field",{attrs:{label:"Tab name","data-test":"rename-tab-input"},model:{value:e.newTabName,callback:function(n){l().f[18]++,l().s[21]++,e.newTabName=n},expression:"newTabName"}})],1),e._v(" "),n("v-card-actions",[n("v-spacer"),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{outlined:"","data-test":"cancel-rename"},on:{click:e.cancelTabRename}},[e._v("\n Cancel\n ")]),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{color:"primary","data-test":"rename",disabled:!e.newTabName},on:{click:e.renameTab}},[e._v("\n Rename\n ")])],1)],1)],1),e._v(" "),n("v-menu",{attrs:{"position-x":e.tabMenuX,"position-y":e.tabMenuY,absolute:"","offset-y":""},model:{value:e.showTabMenu,callback:function(n){l().f[19]++,l().s[22]++,e.showTabMenu=n},expression:"showTabMenu"}},[n("v-list",[n("v-list-item",{attrs:{"data-test":"context-menu-rename"}},[n("v-list-item-title",{staticStyle:{cursor:"pointer"},on:{click:e.openTabNameDialog}},[e._v("\n Rename\n ")])],1)],1)],1),e._v(" "),e.showAddComponentDialog?(l().b[9][0]++,n("add-component-dialog",{attrs:{components:e.components},on:{add:e.addComponent,cancel:e.cancelAddComponent},model:{value:e.showAddComponentDialog,callback:function(n){l().f[20]++,l().s[23]++,e.showAddComponentDialog=n},expression:"showAddComponentDialog"}})):(l().b[9][1]++,e._e())],1)},i=(l().s[24]++,[]),a=(t(1979),t(4936),t(5127),t(309),t(8966)),s=t(9644),c=t.n(s),r=t(4091);const u=new r["default"],m=c().create({baseURL:location.origin,timeout:6e4,params:{}});m.interceptors.response.use((e=>e),(e=>{if(e.response){var n,t,l,o,i;if(401===e.response.status&&OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity,!0).then((function(e){e&&OpenC3Auth.setTokens()})),e.response.headers["ignore-errors"]&&e.response.headers["ignore-errors"].includes(e.response.status.toString()))return Promise.reject(e);let s=`HTTP ${e.response.status} - `;if(null!==(n=e.response)&&void 0!==n&&n.statusText&&(s+=`${e.response.statusText} `),null!==(t=e.response)&&void 0!==t&&null!==(t=t.config)&&void 0!==t&&t.data&&(s+=`${e.response.config.data} `),null!==(l=e.response)&&void 0!==l&&null!==(l=l.data)&&void 0!==l&&l.message)s+=`${e.response.data.message}`;else if(null!==(o=e.response)&&void 0!==o&&null!==(o=o.data)&&void 0!==o&&o.exception)s+=`${e.response.data.exception}`;else if(null!==(i=e.response)&&void 0!==i&&null!==(i=i.data)&&void 0!==i&&null!==(i=i.error)&&void 0!==i&&i.message)e.response.data.error.class&&(s+=`${e.response.data.error.class} `),s+=`${e.response.data.error.message}`;else{var a;s+=`${null===(a=e.response)||void 0===a?void 0:a.data}`}throw u.$notify&&u.$notify.serious({title:"Network error",body:s}),e}throw e}));const d=m,A=async function(e,n,{data:t,params:l={},headers:o,noAuth:i=!1,noScope:a=!1}={}){if(!i){try{let e=await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity);e&&OpenC3Auth.setTokens()}catch(s){OpenC3Auth.login()}o["Authorization"]=localStorage.openc3Token}return a||l["scope"]||(l["scope"]=window.openc3Scope),d({method:e,url:n,data:t,params:l,headers:o})},p={Accept:"application/json"},h={...p,"Content-Type":"application/json"},f={get:function(e,{params:n,headers:t=p,noScope:l,noAuth:o}={}){return A("get",e,{params:n,headers:t,noScope:l,noAuth:o})},put:function(e,{data:n,params:t,headers:l=h,noScope:o,noAuth:i}={}){return A("put",e,{data:n,params:t,headers:l,noScope:o,noAuth:i})},post:function(e,{data:n,params:t,headers:l=h,noScope:o,noAuth:i}={}){return A("post",e,{data:n,params:t,headers:l,noScope:o,noAuth:i})},delete:function(e,{params:n,headers:t=p,noScope:l,noAuth:o}={}){return A("delete",e,{params:n,headers:t,noScope:l,noAuth:o})}};t(1531);var v=t(6088);t(978),t(5984),t(7380),t(527),t(1697),t(9394),t(3438),t(3616),t(5630),t(896),t(4139);class C{constructor(){(0,v.Z)(this,"id",1)}async exec(e,n,t={},l={},o=6e4){try{let e=await OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity);e&&OpenC3Auth.setTokens()}catch(a){OpenC3Auth.login()}this.id=this.id+1;try{t["scope"]=window.openc3Scope;const i=await d.post("/openc3-api/api",{jsonrpc:"2.0",method:e,params:n,id:this.id,keyword_params:t},{headers:{Authorization:localStorage.openc3Token,"Content-Type":"application/json-rpc",...l},timeout:o});return i.data.result}catch(a){var i=new Error;throw a.response?(i.name=a.response.data.error.data.class,i.message=a.response.data.error.data.message):a.request?(i.name="Request error",i.message="Request error, no response received"):i.name="Unknown error",i}}decode_openc3_type(e){if(null!==e&&"object"===typeof e&&"Float"==e.json_class&&e.raw){if("NaN"==e.raw)return NaN;if("Infinity"==e.raw)return 1/0;if("-Infinity"==e.raw)return-1/0}return null}encode_openc3_type(e){return Number.isNaN(e)?{json_class:"Float",raw:"NaN"}:e==Number.POSITIVE_INFINITY?{json_class:"Float",raw:"Infinity"}:e==Number.NEGATIVE_INFINITY?{json_class:"Float",raw:"-Infinity"}:null}ensure_offline_access(){this.offline_access_needed().then((e=>{e&&(localStorage.openc3OfflineToken?this.set_offline_access(localStorage.openc3OfflineToken).then((()=>{delete localStorage.openc3OfflineToken})):OpenC3Auth.getOfflineAccess())}))}offline_access_needed(){return this.exec("offline_access_needed",[])}set_offline_access(e){return this.exec("set_offline_access",[e])}get_all_interface_info(){return this.exec("get_all_interface_info",[])}map_target_to_interface(e,n){return this.exec("map_target_to_interface",[e,n])}connect_interface(e,...n){return n.length>0?this.exec("connect_interface",[e,...n]):this.exec("connect_interface",[e])}disconnect_interface(e){return this.exec("disconnect_interface",[e])}get_all_router_info(){return this.exec("get_all_router_info",[])}connect_router(e){return this.exec("connect_router",[e])}disconnect_router(e){return this.exec("disconnect_router",[e])}get_target_interfaces(){return this.exec("get_target_interfaces",[])}get_all_target_info(){return this.exec("get_all_target_info",[])}get_tlm_cnts(e){return this.exec("get_tlm_cnts",[e])}get_item(e,n,t){return this.exec("get_item",[e,n,t])}get_parameter(e,n,t){return this.exec("get_parameter",[e,n,t])}get_limits_sets(){return this.exec("get_limits_sets",[])}get_limits_set(){return this.exec("get_limits_set",[])}set_limits_set(e){return this.exec("set_limits_set",[e])}get_target(e){return this.exec("get_target",[e])}get_target_list(){return this.exec("get_target_list",[])}get_target_names(){return this.exec("get_target_names",[])}get_telemetry(e,n){return this.exec("get_telemetry",[e,n])}get_all_telemetry(e){return this.exec("get_all_telemetry",[e])}get_all_telemetry_names(e){return this.exec("get_all_telemetry_names",[e])}async get_tlm_packet(e,n,t,l=30){const o=await this.exec("get_tlm_packet",[e,n],{type:t,stale_time:l});if(null!=o)for(var i=o.length,a=null,s=0;s<i;s++)a=this.decode_openc3_type(o[s][1]),null!==a&&(o[s][1]=a);return o}get_packet_derived_items(e,n){return this.exec("get_packet_derived_items",[e,n])}get_tlm_buffer(e,n){return this.exec("get_tlm_buffer",[e,n])}async get_tlm_values(e,n=30){const t=await this.exec("get_tlm_values",[e],{stale_time:n},{},1e4);for(var l=t[0].length,o=null,i=0;i<l;i++)o=this.decode_openc3_type(t[0][i]),null!==o&&(t[0][i]=o);return t}get_limits(e,n,t){return this.exec("get_limits",[e,n,t])}async tlm(e,n,t,l="CONVERTED"){let o=null;if(void 0===n)o=await this.exec("tlm",[e]);else if(void 0===t){if(!["RAW","CONVERTED","FORMATTED","WITH_UNITS"].includes(n)){var i=new Error;throw i.name="TypeError",i.message=`Invalid data type ${n}. Valid options are RAW, CONVERTED, FORMATTED, and WITH_UNITS.`,i}o=await this.exec("tlm",[e],{type:n})}else o=await this.exec("tlm",[e,n,t],{type:l});var a=this.decode_openc3_type(o);return null!==a&&(o=a),o}async inject_tlm(e,n,t=null,l="CONVERTED"){data=await this.exec("inject_tlm",[e,n,t],{type:l})}set_tlm(e,n,t,l){return this.exec("set_tlm",[e,n,t],{type:l})}override_tlm(e,n,t,l){return this.exec("override_tlm",[e,n,t],{type:l})}get_overrides(){return this.exec("get_overrides")}normalize_tlm(e,n,t,l){return this.exec("normalize_tlm",[e,n,t],{type:l})}get_all_commands(e){return this.exec("get_all_commands",[e])}get_all_command_names(e){return this.exec("get_all_command_names",[e])}get_command(e,n){return this.exec("get_command",[e,n])}get_cmd_cnts(e){return this.exec("get_cmd_cnts",[e])}get_cmd_value(e,n,t,l="CONVERTED"){return this.exec("get_cmd_value",[e,n,t,l])}get_cmd_buffer(e,n){return this.exec("get_cmd_buffer",[e,n])}_cmd(e,n,t,l,o){var i=null;for(var a in l)Object.prototype.hasOwnProperty.call(l,a)&&(i=this.encode_openc3_type(l[a]),null!==i&&(l[a]=i));return this.exec(e,[n,t,l],{},o)}get_cmd_hazardous(e,n,t){return void 0===n?this.exec("get_cmd_hazardous",e):this._cmd("get_cmd_hazardous",e,n,t)}cmd(e,n,t,l={}){return void 0===n?this.exec("cmd",e,{},l):this._cmd("cmd",e,n,t,l)}cmd_no_range_check(e,n,t){return void 0===n?this.exec("cmd_no_range_check",e):this._cmd("cmd_no_range_check",e,n,t)}cmd_raw(e,n,t){return void 0===n?this.exec("cmd_raw",e):this._cmd("cmd_raw",e,n,t)}cmd_raw_no_range_check(e,n,t){return void 0===n?this.exec("cmd_raw_no_range_check",e):this._cmd("cmd_raw_no_range_check",e,n,t)}cmd_no_hazardous_check(e,n,t){return void 0===n?this.exec("cmd_no_hazardous_check",e):this._cmd("cmd_no_hazardous_check",e,n,t)}cmd_no_checks(e,n,t){return void 0===n?this.exec("cmd_no_checks",e):this._cmd("cmd_no_checks",e,n,t)}cmd_raw_no_hazardous_check(e,n,t){return void 0===n?this.exec("cmd_raw_no_hazardous_check",e):this._cmd("cmd_raw_no_hazardous_check",e,n,t)}cmd_raw_no_checks(e,n,t){return void 0===n?this.exec("cmd_raw_no_checks",e):this._cmd("cmd_raw_no_checks",e,n,t)}build_command(e,n,t){return void 0===n?this.exec("build_command",e):this._cmd("build_command",e,n,t)}get_interface_names(){return this.exec("get_interface_names",[])}send_raw(e,n){return this.exec("send_raw",[e,n])}list_configs(e){return this.exec("list_configs",[e])}load_config(e,n){return this.exec("load_config",[e,n])}save_config(e,n,t){return this.exec("save_config",[e,n,t])}delete_config(e,n){return this.exec("delete_config",[e,n])}enable_limits(e,n,t){return this.exec("enable_limits",[e,n,t])}disable_limits(e,n,t){return this.exec("disable_limits",[e,n,t])}get_out_of_limits(){return this.exec("get_out_of_limits",[])}get_overall_limits_state(e){return this.exec("get_overall_limits_state",[e])}list_settings(){return this.exec("list_settings",[])}get_all_settings(){return this.exec("get_all_settings",[])}get_setting(e){return this.exec("get_setting",[e])}get_settings(e){return this.exec("get_settings",e)}set_setting(e,n){return this.exec("set_setting",[e,n])}save_setting(e,n){return this.exec("save_setting",[e,n])}get_metrics(){return this.exec("get_metrics",[])}async hashString(e){if(window.isSecureContext){const n=(new TextEncoder).encode(e),t=await crypto.subtle.digest("SHA-256",n),l=new Uint8Array(t);return Array.from(l).map((e=>e.toString(16).padStart(2,"0"))).join("")}}}const g={data:{configKey:""},methods:{openConfigBase:function(e,n=!1,t=null){localStorage[`lastconfig__${this.configKey}`]=e,(new C).load_config(this.configKey,e).then((l=>{l?(this.$notify.normal({title:"Loading configuration",body:e}),t&&t(JSON.parse(l)),n||this.$router.currentRoute.fullPath.includes(e)||this.$router.push({query:{config:e}}),localStorage[`lastconfig__${this.configKey}`]=e):(this.$notify.caution({title:"Unknown configuration",body:e}),localStorage.removeItem(`lastconfig__${this.configKey}`))})).catch((n=>{n&&this.$notify.serious({title:`Error opening configuration: ${e}`,body:n}),localStorage.removeItem(`lastconfig__${this.configKey}`)}))},saveConfigBase:function(e,n){(new C).save_config(this.configKey,e,JSON.stringify(n)).then((()=>{this.$notify.normal({title:"Saved configuration",body:e}),localStorage[`lastconfig__${this.configKey}`]=e})).catch((n=>{n&&this.$notify.serious({title:`Error saving configuration: ${e}`,body:n}),localStorage.removeItem(`lastconfig__${this.configKey}`)}))},resetConfigBase:function(){localStorage.removeItem(`lastconfig__${this.configKey}`),"/"!==this.$router.currentRoute.fullPath&&this.$router.replace(this.$router.currentRoute.path),this.$router.go()}}};var b=function(){var e=this,n=e._self._c;return n("v-dialog",{attrs:{width:"600"},on:{keydown:function(n){return!n.type.indexOf("key")&&e._k(n.keyCode,"esc",27,n.key,["Esc","Escape"])?null:e.cancel.apply(null,arguments)}},model:{value:e.show,callback:function(n){e.show=n},expression:"show"}},[n("v-card",[n("form",{on:{submit:function(n){return n.preventDefault(),e.success.apply(null,arguments)}}},[n("v-system-bar",[n("v-spacer"),e._v(" "),n("span",[e._v("Open Configuration")]),e._v(" "),n("v-spacer")],1),e._v(" "),n("v-card-text",[n("div",{staticClass:"pa-3"},[n("v-row",{attrs:{dense:""}},[n("v-text-field",{attrs:{label:"search",type:"text","data-test":"search","prepend-icon":"mdi-magnify","clear-icon":"mdi-close-circle-outline",clearable:"",autofocus:"","single-line":"","hide-details":""},model:{value:e.search,callback:function(n){e.search=n},expression:"search"}})],1),e._v(" "),n("v-data-table",{attrs:{"show-select":"","single-select":"","item-key":"configId",search:e.search,headers:e.headers,items:e.configs,"items-per-page":5,"footer-props":{"items-per-page-options":[5]}},on:{"item-selected":e.itemSelected,"click:row":(e,n)=>n.select(e)},scopedSlots:e._u([{key:"item.actions",fn:function({item:t}){return[n("v-btn",{staticClass:"mt-1",attrs:{"data-test":"item-delete",icon:""},on:{click:function(n){return e.deleteConfig(t)}}},[n("v-icon",[e._v("mdi-delete")])],1)]}}])}),e._v(" "),n("v-row",{attrs:{dense:""}},[n("span",{directives:[{name:"show",rawName:"v-show",value:e.error,expression:"error"}],staticClass:"ma-2 red--text",domProps:{textContent:e._s(e.error)}})])],1)]),e._v(" "),n("v-card-actions",[n("v-spacer"),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{outlined:"","data-test":"open-config-cancel-btn"},on:{click:e.cancel}},[e._v("\n Cancel\n ")]),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{type:"submit",color:"primary","data-test":"open-config-submit-btn",disabled:!!e.error},on:{click:function(n){return n.preventDefault(),e.success.apply(null,arguments)}}},[e._v("\n Ok\n ")])],1)],1)])],1)},y=[];const k={props:{configKey:String,value:Boolean},data(){return{configs:[],headers:[{text:"Configuration",value:"config"},{text:"Actions",value:"actions",align:"end",sortable:!1}],search:null,selectedItem:null}},computed:{error:function(){return""===this.selectedItem||null===this.selectedItem?"Must select a config":null},show:{get(){return this.value},set(e){this.$emit("input",e)}}},mounted(){let e=-1;(new C).list_configs(this.configKey).then((n=>{this.configs=n.map((n=>(e+=1,{configId:e,config:n})))})).catch((e=>{this.$emit("warning",`Failed to connect to OpenC3. ${e}`)}))},methods:{itemSelected:function(e){e.value?this.selectedItem=e.item:this.selectedItem=null},success:function(){this.$emit("success",this.selectedItem.config),this.show=!1,this.search=null,this.selectedItem=null},cancel:function(){this.show=!1,this.search=null,this.selectedItem=null},deleteConfig:function(e){this.$dialog.confirm(`Are you sure you want to delete: ${e.config}`,{okText:"Delete",cancelText:"Cancel"}).then((n=>{this.selectedItem.config===e.config&&(this.selectedItem=null),this.configs.splice(this.configs.indexOf(e),1),(new C).delete_config(this.configKey,e.config),localStorage[`lastconfig__${this.configKey}`]===e.config&&localStorage.removeItem(`lastconfig__${this.configKey}`)})).catch((n=>{n&&this.$emit("warning",`Failed to delete config ${e.config} Error: ${n}`)}))}}},w=k;var T=t(3483),x=(0,T.Z)(w,b,y,!1,null,null,null);const N=x.exports;var D=function(){var e=this,n=e._self._c;return n("v-dialog",{attrs:{width:"600"},on:{keydown:function(n){return!n.type.indexOf("key")&&e._k(n.keyCode,"esc",27,n.key,["Esc","Escape"])?null:e.cancel.apply(null,arguments)}},model:{value:e.show,callback:function(n){e.show=n},expression:"show"}},[n("v-card",[n("form",{on:{submit:function(n){return n.preventDefault(),e.success.apply(null,arguments)}}},[n("v-system-bar",[n("v-spacer"),e._v(" "),n("span",[e._v("Save Configuration")]),e._v(" "),n("v-spacer")],1),e._v(" "),n("v-card-text",[n("div",{staticClass:"pa-3"},[n("v-row",{attrs:{dense:""}},[n("v-text-field",{attrs:{label:"search",type:"text","data-test":"search","prepend-icon":"mdi-magnify","clear-icon":"mdi-close-circle-outline",clearable:"","single-line":"","hide-details":""},model:{value:e.search,callback:function(n){e.search=n},expression:"search"}})],1),e._v(" "),n("v-data-table",{attrs:{"show-select":"","single-select":"","item-key":"configId",search:e.search,headers:e.headers,items:e.configs,"items-per-page":5,"footer-props":{"items-per-page-options":[5]}},on:{"item-selected":e.itemSelected,"click:row":(e,n)=>n.select(e)},scopedSlots:e._u([{key:"item.actions",fn:function({item:t}){return[n("v-btn",{staticClass:"mt-1",attrs:{icon:"","data-test":"item-delete"},on:{click:function(n){return e.deleteConfig(t)}}},[n("v-icon",[e._v("mdi-delete")])],1)]}}])}),e._v(" "),n("v-row",{attrs:{dense:""}},[n("v-text-field",{attrs:{"hide-details":"",autofocus:"",disabled:!!e.selectedItem,label:"Configuration Name","data-test":"name-input-save-config-dialog"},model:{value:e.configName,callback:function(n){e.configName=n},expression:"configName"}})],1),e._v(" "),n("v-row",{attrs:{dense:""}},[n("span",{directives:[{name:"show",rawName:"v-show",value:e.error,expression:"error"}],staticClass:"ma-2 red--text",domProps:{textContent:e._s(e.error)}})])],1)]),e._v(" "),n("v-card-actions",[n("v-spacer"),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{outlined:""},on:{click:e.cancel}},[e._v(" Cancel ")]),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{type:"submit",color:"primary","data-test":"save-config-submit-btn",disabled:!!e.error},on:{click:function(n){return n.preventDefault(),e.success.apply(null,arguments)}}},[e._v("\n Ok\n ")])],1)],1)])],1)},S=[];const P={props:{configKey:String,value:Boolean},data(){return{configName:"",configs:[],headers:[{text:"Configuration",value:"config"},{text:"Actions",value:"actions",align:"end",sortable:!1}],search:null,selectedItem:null}},computed:{error:function(){return""===this.configName?"Config must have a name":null},show:{get(){return this.value},set(e){this.$emit("input",e)}}},mounted(){let e=-1;(new C).list_configs(this.configKey).then((n=>{this.configs=n.map((n=>(e+=1,{configId:e,config:n})))})).catch((e=>{this.$emit("warning",`Failed to connect to OpenC3. ${e}`)}))},methods:{itemSelected:function(e){e.value?(this.selectedItem=e.item,this.configName=e.item.config):(this.selectedItem=null,this.configName="")},success:function(){this.$emit("success",this.configName),this.show=!1,this.search=null,this.selectedItem=null,this.configName=""},cancel:function(){this.show=!1,this.search=null,this.selectedItem=null,this.configName=""},deleteConfig:function(e){this.$dialog.confirm(`Are you sure you want to delete: ${e.config}`,{okText:"Delete",cancelText:"Cancel"}).then((n=>{this.configName===e.config&&(this.selectedItem=null,this.configName=""),this.configs.splice(this.configs.indexOf(e.config),1),(new C).delete_config(this.configKey,e.config),localStorage[`lastconfig__${this.configKey}`]===e.config&&localStorage.removeItem(`lastconfig__${this.configKey}`)})).catch((n=>{n&&this.$emit("warning",`Failed to delete config ${e.config} Error: ${n}`)}))}}},O=P;var $=(0,T.Z)(O,D,S,!1,null,null,null);const I=$.exports;var R=t(7146);R.ju.staleThreshold=10;class M{constructor(e="/openc3-api/cable"){this._cable=null,this._url=e}disconnect(){this._cable&&this._cable.disconnect()}createSubscription(e,n,t={},l={}){return OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then((n=>{if(n&&OpenC3Auth.setTokens(),null==this._cable){let e=this._url+"?scope="+window.openc3Scope+"&authorization="+localStorage.openc3Token;this._cable=R.zD(encodeURI(e))}return this._cable.subscriptions.create({channel:e,...l},t)}))}recordPing(){this._cable.connection.monitor.recordPing()}}var E=function(){var e=this,n=e._self._c;return n("mounting-portal",{attrs:{"mount-to":"#openc3-menu",append:""}},[n("div",{staticClass:"v-toolbar__content"},[e._l(e.menus,(function(t,l){return n("v-menu",{key:l,ref:"topmenu",refInFor:!0,attrs:{"offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:l,attrs:o}){return[n("v-btn",e._g(e._b({staticClass:"mx-1",attrs:{outlined:"","data-test":e.formatDT(`${e.title} ${t.label}`)}},"v-btn",o,!1),l),[n("span",{domProps:{textContent:e._s(t.label)}}),e._v(" "),n("v-icon",{attrs:{right:""}},[e._v(" mdi-menu-down ")])],1)]}}],null,!0)},[e._v(" "),n("v-list",[n("v-radio-group",{staticClass:"ma-0 pa-0",attrs:{value:t.radioGroup,"hide-details":"",dense:""}},[e._l(t.items,(function(l,o){return[l.divider?n("v-divider",{key:o}):l.subMenu?n("div",{key:o},[n("v-menu",{key:e.k,attrs:{"open-on-hover":"","offset-x":"",bottom:""},scopedSlots:e._u([{key:"activator",fn:function({on:t,attrs:i}){return[n("v-list-item",e._g(e._b({key:o,attrs:{disabled:l.disabled}},"v-list-item",i,!1),t),[l.icon?n("v-list-item-icon",[n("v-icon",{attrs:{disabled:l.disabled}},[e._v(e._s(l.icon))])],1):e._e(),e._v(" "),l.radio||l.checkbox?e._e():n("v-list-item-title",{style:"cursor: pointer;"+(l.disabled?"opacity: 0.2":"")},[e._v(e._s(l.label)+"\n ")]),e._v(" "),n("v-icon",[e._v(" mdi-chevron-right ")])],1)]}}],null,!0)},[e._v(" "),n("v-list",e._l(l.subMenu,(function(t,l){return n("v-list-item",{key:l,on:{click:function(n){return e.subMenuClick(t)}}},[t.icon?n("v-list-item-icon",[n("v-icon",[e._v(e._s(t.icon))])],1):e._e(),e._v(" "),n("v-list-item-title",[e._v(e._s(t.label))])],1)})),1)],1)],1):n("v-list-item",{key:o,attrs:{disabled:l.disabled,"data-test":e.formatDT(`${e.title} ${t.label} ${l.label}`)},on:{click:function(e){return l.command(l)}}},[l.radio?n("v-list-item-action",[n("v-radio",{attrs:{color:"secondary",label:l.label,value:l.label}})],1):e._e(),e._v(" "),l.checkbox?n("v-list-item-action",[n("v-checkbox",{attrs:{color:"secondary",label:l.label},model:{value:l.checked,callback:function(n){e.$set(l,"checked",n)},expression:"option.checked"}})],1):e._e(),e._v(" "),l.icon?n("v-list-item-icon",[n("v-icon",{attrs:{disabled:l.disabled}},[e._v(e._s(l.icon))])],1):e._e(),e._v(" "),l.radio||l.checkbox?e._e():n("v-list-item-title",{style:"cursor: pointer;"+(l.disabled?"opacity: 0.2":"")},[e._v(e._s(l.label))])],1)]}))],2)],1)],1)})),e._v(" "),n("v-spacer"),e._v(" "),n("v-toolbar-title",[e._v(e._s(e.title))]),e._v(" "),n("v-spacer")],2)])},L=[];t(4597);const V={props:{menus:{type:Array,default:function(){return[]}},title:{type:String,default:""}},methods:{formatDT:function(e){return e.replaceAll(" ","-").toLowerCase()},subMenuClick(e){e.command(e),this.$refs.topmenu[0].isActive=!1}},mounted(){"COSMOS "===this.title.substring(0,7)?document.title=this.title.substring(7):document.title=this.title}},U=V;t(2416);var F=(0,T.Z)(U,E,L,!1,null,"11569d60",null);const K=F.exports;function j(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/AddComponentDialog.vue",n="8c107e84b7a1e3aa0a59c0dd3ccbffc5d6e8a979",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/AddComponentDialog.vue",statementMap:{0:{start:{line:1,column:13},end:{line:9,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:8,column:1026}},4:{start:{line:1,column:163},end:{line:1,column:175}},5:{start:{line:1,column:728},end:{line:1,column:753}},6:{start:{line:1,column:1085},end:{line:1,column:1110}},7:{start:{line:1,column:1659},end:{line:1,column:1680}},8:{start:{line:1,column:2187},end:{line:1,column:2213}},9:{start:{line:8,column:113},end:{line:8,column:138}},10:{start:{line:8,column:202},end:{line:8,column:571}},11:{start:{line:8,column:310},end:{line:8,column:505}},12:{start:{line:8,column:374},end:{line:8,column:401}},13:{start:{line:10,column:22},end:{line:10,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:9,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:147},end:{line:1,column:148}},loc:{start:{line:1,column:162},end:{line:1,column:176}},line:1},2:{name:"(anonymous_2)",decl:{start:{line:1,column:712},end:{line:1,column:713}},loc:{start:{line:1,column:727},end:{line:1,column:754}},line:1},3:{name:"(anonymous_3)",decl:{start:{line:1,column:1069},end:{line:1,column:1070}},loc:{start:{line:1,column:1084},end:{line:1,column:1111}},line:1},4:{name:"(anonymous_4)",decl:{start:{line:1,column:1643},end:{line:1,column:1644}},loc:{start:{line:1,column:1658},end:{line:1,column:1681}},line:1},5:{name:"(anonymous_5)",decl:{start:{line:1,column:2171},end:{line:1,column:2172}},loc:{start:{line:1,column:2186},end:{line:1,column:2214}},line:1},6:{name:"(anonymous_6)",decl:{start:{line:8,column:96},end:{line:8,column:97}},loc:{start:{line:8,column:112},end:{line:8,column:139}},line:8},7:{name:"(anonymous_7)",decl:{start:{line:8,column:183},end:{line:8,column:184}},loc:{start:{line:8,column:201},end:{line:8,column:572}},line:8},8:{name:"(anonymous_8)",decl:{start:{line:8,column:286},end:{line:8,column:287}},loc:{start:{line:8,column:309},end:{line:8,column:506}},line:8},9:{name:"(anonymous_9)",decl:{start:{line:8,column:357},end:{line:8,column:358}},loc:{start:{line:8,column:373},end:{line:8,column:402}},line:8}},branchMap:{0:{loc:{start:{line:1,column:1971},end:{line:1,column:2258}},type:"cond-expr",locations:[{start:{line:1,column:2003},end:{line:1,column:2249}},{start:{line:1,column:2250},end:{line:1,column:2258}}],line:1}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8c107e84b7a1e3aa0a59c0dd3ccbffc5d6e8a979"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return j=function(){return a},a}j(),j().s[0]++;var B=function(){j().f[0]++;var e=(j().s[1]++,this),n=(j().s[2]++,e._self._c);return j().s[3]++,n("div",[n("v-dialog",{attrs:{width:"800"},model:{value:e.show,callback:function(n){j().f[1]++,j().s[4]++,e.show=n},expression:"show"}},[n("v-card",[n("v-system-bar",[n("v-spacer"),e._v(" "),n("span",[e._v(" Configure Component ")]),e._v(" "),n("v-spacer")],1),e._v(" "),n("v-card-text",[n("v-container",[n("v-row",{attrs:{align:"center"}},[n("v-col",[e._v("Select Component:")]),e._v(" "),n("v-col",[n("v-select",{attrs:{"hide-details":"",dense:"",outlined:"",items:e.components,"item-text":"label","item-value":"value","return-object":"","data-test":"select-component"},model:{value:e.selectedComponent,callback:function(n){j().f[2]++,j().s[5]++,e.selectedComponent=n},expression:"selectedComponent"}})],1)],1),e._v(" "),n("v-row",[n("v-col",[e._v("Add packets for this component to process.")])],1),e._v(" "),n("v-row",[n("v-col",{staticClass:"my-2"},[n("v-radio-group",{staticClass:"mt-0",attrs:{row:"","hide-details":""},model:{value:e.newPacketCmdOrTlm,callback:function(n){j().f[3]++,j().s[6]++,e.newPacketCmdOrTlm=n},expression:"newPacketCmdOrTlm"}},[n("v-radio",{attrs:{label:"Command",value:"cmd","data-test":"command-packet-radio"}}),e._v(" "),n("v-radio",{attrs:{label:"Telemetry",value:"tlm","data-test":"telemetry-packet-radio"}})],1)],1)],1),e._v(" "),n("v-row",[n("v-col",[n("target-packet-item-chooser",{attrs:{unknown:"","button-text":"Add Packet"},on:{click:e.addPacket}})],1)],1),e._v(" "),n("v-row",[n("v-col",[n("v-radio-group",{attrs:{row:"","hide-details":""},model:{value:e.newPacketMode,callback:function(n){j().f[4]++,j().s[7]++,e.newPacketMode=n},expression:"newPacketMode"}},[n("v-radio",{attrs:{label:"Raw",value:"RAW","data-test":"new-packet-raw-radio"}}),e._v(" "),n("v-radio",{attrs:{label:"Decom",value:"DECOM",disabled:e.disableRadioOptions,"data-test":"new-packet-decom-radio"}})],1)],1),e._v(" "),n("v-col",["DECOM"===e.newPacketMode?(j().b[0][0]++,n("v-select",{attrs:{"hide-details":"",label:"Value Type","data-test":"add-packet-value-type",items:e.valueTypes},model:{value:e.newPacketValueType,callback:function(n){j().f[5]++,j().s[8]++,e.newPacketValueType=n},expression:"newPacketValueType"}})):(j().b[0][1]++,e._e())],1)],1),e._v(" "),n("v-row",[n("v-col",[n("v-data-table",{attrs:{headers:e.headers,items:e.packets,search:e.search,"items-per-page":e.itemsPerPage,"footer-props":{itemsPerPageOptions:[10,100],showFirstLastPage:!0,firstIcon:"mdi-page-first",lastIcon:"mdi-page-last",prevIcon:"mdi-chevron-left",nextIcon:"mdi-chevron-right"},"calculate-widths":"","multi-sort":"",dense:""},on:{"update:items-per-page":function(n){j().f[6]++,j().s[9]++,e.itemsPerPage=n}},scopedSlots:e._u([{key:"item.delete",fn:function({item:t}){return j().f[7]++,j().s[10]++,[n("v-tooltip",{attrs:{bottom:""},scopedSlots:e._u([{key:"activator",fn:function({on:l,attrs:o}){return j().f[8]++,j().s[11]++,[n("v-icon",e._g(e._b({on:{click:function(n){return j().f[9]++,j().s[12]++,e.deleteItem(t)}}},"v-icon",o,!1),l),[e._v("\n mdi-delete\n ")])]}}],null,!0)},[e._v(" "),n("span",[e._v("Delete Item")])])]}}])})],1)],1)],1)],1),e._v(" "),n("v-card-actions",[n("v-spacer"),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{outlined:"","data-test":"cancel-component"},on:{click:e.cancelAddComponent}},[e._v("\n Cancel\n ")]),e._v(" "),n("v-btn",{staticClass:"mx-2",attrs:{color:"primary","data-test":"add-component",disabled:e.notValid},on:{click:e.addComponent}},[e._v("\n Create\n ")])],1)],1)],1)],1)},W=(j().s[13]++,[]),z=function(){var e=this,n=e._self._c;return n("v-container",{staticClass:"c-chooser px-0"},[n("v-row",[n("v-col",{attrs:{cols:e.colSize,"data-test":"select-target"}},[n("v-autocomplete",{attrs:{label:"Select Target","hide-details":"",dense:"",items:e.targetNames,"item-text":"label","item-value":"value"},on:{change:e.targetNameChanged},model:{value:e.selectedTargetName,callback:function(n){e.selectedTargetName=n},expression:"selectedTargetName"}})],1),e._v(" "),n("v-col",{attrs:{cols:e.colSize,"data-test":"select-packet"}},[n("v-autocomplete",{attrs:{label:"Select Packet","hide-details":"",dense:"",disabled:e.packetsDisabled||e.buttonDisabled,items:e.packetNames,"item-text":"label","item-value":"value"},on:{change:e.packetNameChanged},model:{value:e.selectedPacketName,callback:function(n){e.selectedPacketName=n},expression:"selectedPacketName"}})],1),e._v(" "),e.chooseItem&&!e.buttonDisabled?n("v-col",{attrs:{cols:e.colSize,"data-test":"select-item"}},[n("v-autocomplete",{attrs:{label:"Select Item","hide-details":"",dense:"",disabled:e.itemsDisabled||e.buttonDisabled,items:e.itemNames,"item-text":"label","item-value":"value"},on:{change:function(n){return e.itemNameChanged(n)}},model:{value:e.selectedItemName,callback:function(n){e.selectedItemName=n},expression:"selectedItemName"}})],1):e._e(),e._v(" "),e.buttonText?n("v-col",{attrs:{cols:e.colSize}},[n("v-btn",{attrs:{disabled:e.buttonDisabled,block:"",color:"primary","data-test":"select-send"},on:{click:e.buttonPressed}},[e._v("\n "+e._s(e.actualButtonText)+"\n ")])],1):e._e()],1),e._v(" "),e.selectTypes?n("v-row",[n("v-col",{attrs:{cols:e.colSize,"data-test":"data-type"}},[n("v-autocomplete",{attrs:{label:"Value Type","hide-details":"",dense:"",items:e.valueTypes},model:{value:e.selectedValueType,callback:function(n){e.selectedValueType=n},expression:"selectedValueType"}})],1),e._v(" "),n("v-col",{attrs:{cols:e.colSize,"data-test":"reduced"}},[n("v-autocomplete",{attrs:{label:"Reduced","hide-details":"",dense:"",items:e.reductionModes},model:{value:e.selectedReduced,callback:function(n){e.selectedReduced=n},expression:"selectedReduced"}})],1),e._v(" "),n("v-col",{attrs:{cols:e.colSize,"data-test":"reduced-type"}},[n("v-autocomplete",{attrs:{label:"Reduced Type","hide-details":"",dense:"",disabled:"DECOM"===e.selectedReduced,items:e.reducedTypes},model:{value:e.selectedReducedType,callback:function(n){e.selectedReducedType=n},expression:"selectedReducedType"}})],1),e._v(" "),n("v-col",{attrs:{cols:e.colSize}})],1):e._e(),e._v(" "),n("v-row",{staticClass:"pt-1",attrs:{"no-gutters":""}},[e.hazardous?n("v-col",{staticClass:"openc3-yellow",staticStyle:{"white-space":"pre"},attrs:{cols:e.colSize}},[e._v("Description: "+e._s(e.description)+" (HAZARDOUS)")]):n("v-col",{staticStyle:{"white-space":"pre"},attrs:{cols:e.colSize}},[e._v("Description: "+e._s(e.description)+"\n ")])],1)],1)},H=[];t(2464);const q={props:{allowAll:{type:Boolean,default:!1},allowAllTargets:{type:Boolean,default:!1},buttonText:{type:String,default:null},chooseItem:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},initialTargetName:{type:String,default:""},initialPacketName:{type:String,default:""},initialItemName:{type:String,default:""},selectTypes:{type:Boolean,default:!1},mode:{type:String,default:"tlm",validator:e=>["cmd","tlm"].includes(e)},unknown:{type:Boolean,default:!1},vertical:{type:Boolean,default:!1}},data(){var e,n,t;return{targetNames:[],selectedTargetName:null===(e=this.initialTargetName)||void 0===e?void 0:e.toUpperCase(),packetNames:[],selectedPacketName:null===(n=this.initialPacketName)||void 0===n?void 0:n.toUpperCase(),itemNames:[],selectedItemName:null===(t=this.initialItemName)||void 0===t?void 0:t.toUpperCase(),valueTypes:["CONVERTED","RAW"],selectedValueType:"CONVERTED",reductionModes:[{text:"NONE",value:"DECOM"},{text:"REDUCED_MINUTE",value:"REDUCED_MINUTE"},{text:"REDUCED_HOUR",value:"REDUCED_HOUR"},{text:"REDUCED_DAY",value:"REDUCED_DAY"}],selectedReduced:"DECOM",reducedTypes:["MIN","MAX","AVG","STDDEV"],selectedReducedType:"AVG",description:"",hazardous:!1,internalDisabled:!1,packetsDisabled:!1,itemsDisabled:!1,api:null,ALL:{label:"[ ALL ]",value:"ALL",description:"ALL"},UNKNOWN:{label:"[ UNKNOWN ]",value:"UNKNOWN",description:"UNKNOWN"}}},created(){this.internalDisabled=!0,this.api=new C,this.api.get_target_names().then((e=>{this.targetNames=e.flatMap((e=>"UNKNOWN"==e?[]:{label:e,value:e})),this.allowAllTargets&&this.targetNames.unshift(this.ALL),this.selectedTargetName||(this.selectedTargetName=this.targetNames[0].value,this.targetNameChanged(this.selectedTargetName)),this.updatePackets(),this.unknown&&this.targetNames.push(this.UNKNOWN)}))},computed:{actualButtonText:function(){return"ALL"===this.selectedPacketName?"Add Target":"ALL"===this.selectedItemName?"Add Packet":this.buttonText},buttonDisabled:function(){return this.disabled||this.internalDisabled},targetChooserStyle:function(){return this.chooseItem||this.buttonText?{width:"25%",float:"left","margin-right":"5px"}:{width:"49%",float:"left"}},packetChooserStyle:function(){return this.chooseItem||this.buttonText?{width:"25%",float:"left","margin-right":"5px"}:{width:"50%",float:"right"}},colSize:function(){return!!this.vertical&&12}},watch:{mode:function(e,n){this.selectedPacketName=null,this.selectedItemName=null,this.updatePackets()}},methods:{updatePackets:function(){if("UNKNOWN"===this.selectedTargetName)return this.packetNames=[this.UNKNOWN],this.selectedPacketName=this.packetNames[0].value,this.packetNameChanged(this.UNKNOWN.value),void(this.description="UNKNOWN");if("ALL"===this.selectedTargetName)return this.packetNames=[this.ALL],this.selectedPacketName=this.packetNames[0].value,this.packetNameChanged(this.ALL.value),void(this.description="ALL");this.internalDisabled=!0;const e="tlm"===this.mode?"get_all_telemetry_names":"get_all_command_names";this.api[e](this.selectedTargetName).then((e=>{this.packetNames=e.map((e=>({label:e,value:e}))),this.allowAll&&this.packetNames.unshift(this.ALL),this.selectedPacketName||(this.selectedPacketName=this.packetNames[0].value),this.packetNameChanged(this.selectedPacketName);this.packetNames.find((e=>e.value===this.selectedPacketName));this.chooseItem&&this.updateItems(),this.internalDisabled=!1}))},updateItems:function(){if("ALL"===this.selectedPacketName)return;this.internalDisabled=!0;const e="tlm"===this.mode?"get_telemetry":"get_command";this.api[e](this.selectedTargetName,this.selectedPacketName).then((e=>{this.itemNames=e.items.map((e=>[{label:e.name,value:e.name,description:e.description}])).reduce(((e,n)=>e.concat(n)),[]),this.allowAll&&this.itemNames.unshift(this.ALL),this.selectedItemName||(this.selectedItemName=this.itemNames[0].value),this.description=this.itemNames[0].description,this.internalDisabled=!1,this.$emit("on-set",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,itemName:this.selectedItemName,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})}))},targetNameChanged:function(e){this.selectedTargetName=e,this.selectedPacketName="",this.selectedItemName="",this.updatePackets()},packetNameChanged:function(e){if("ALL"===e)this.itemsDisabled=!0,this.internalDisabled=!1;else{this.itemsDisabled=!1;const n=this.packetNames.find((n=>e===n.value));this.selectedPacketName=n.value;const t="tlm"===this.mode?"get_telemetry":"get_command";this.api[t](this.selectedTargetName,this.selectedPacketName).then((e=>{this.description=e.description,this.hazardous=e.hazardous}))}this.chooseItem?this.updateItems():this.$emit("on-set",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,itemName:this.selectedItemName,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})},itemNameChanged:function(e){const n=this.itemNames.find((n=>e===n.value));this.selectedItemName=n.value,this.description=n.description,this.$emit("on-set",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,itemName:this.selectedItemName,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})},buttonPressed:function(){"ALL"===this.selectedPacketName?this.allTargetPacketItems():"ALL"===this.selectedItemName?this.allPacketItems():this.chooseItem?this.$emit("click",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,itemName:this.selectedItemName,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType}):this.$emit("click",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})},allTargetPacketItems:function(){this.packetNames.forEach((e=>{if(e===this.ALL)return;const n="tlm"===this.mode?"get_telemetry":"get_command";this.api[n](this.selectedTargetName,e.value).then((n=>{n.items.forEach((n=>{this.$emit("click",{targetName:this.selectedTargetName,packetName:e.value,itemName:n["name"],valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})}))}))}))},allPacketItems:function(){this.itemNames.forEach((e=>{e!==this.ALL&&this.$emit("click",{targetName:this.selectedTargetName,packetName:this.selectedPacketName,itemName:e.value,valueType:this.selectedValueType,reduced:this.selectedReduced,reducedType:this.selectedReducedType})}))}}},G=q;t(985);var Y=(0,T.Z)(G,z,H,!1,null,null,null);const Z=Y.exports;function X(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/AddComponentDialog.vue",n="61dc42db7c91abce276d9244422190456608f03f",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/AddComponentDialog.vue",statementMap:{0:{start:{line:13,column:4},end:{line:30,column:5}},1:{start:{line:34,column:6},end:{line:38,column:7}},2:{start:{line:35,column:8},end:{line:35,column:19}},3:{start:{line:37,column:8},end:{line:37,column:20}},4:{start:{line:41,column:6},end:{line:43,column:7}},5:{start:{line:42,column:8},end:{line:42,column:50}},6:{start:{line:44,column:6},end:{line:44,column:18}},7:{start:{line:48,column:8},end:{line:48,column:25}},8:{start:{line:51,column:8},end:{line:51,column:34}},9:{start:{line:59,column:8},end:{line:59,column:29}},10:{start:{line:65,column:17},end:{line:65,column:40}},11:{start:{line:66,column:6},end:{line:68,column:7}},12:{start:{line:67,column:8},end:{line:67,column:20}},13:{start:{line:69,column:6},end:{line:75,column:8}},14:{start:{line:78,column:6},end:{line:83,column:8}},15:{start:{line:86,column:18},end:{line:86,column:44}},16:{start:{line:87,column:6},end:{line:87,column:35}},17:{start:{line:90,column:6},end:{line:90,column:30}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:12,column:2},end:{line:12,column:3}},loc:{start:{line:12,column:9},end:{line:31,column:3}},line:12},1:{name:"(anonymous_1)",decl:{start:{line:33,column:14},end:{line:33,column:15}},loc:{start:{line:33,column:26},end:{line:39,column:5}},line:33},2:{name:"(anonymous_2)",decl:{start:{line:40,column:25},end:{line:40,column:26}},loc:{start:{line:40,column:37},end:{line:45,column:5}},line:40},3:{name:"(anonymous_3)",decl:{start:{line:47,column:6},end:{line:47,column:7}},loc:{start:{line:47,column:12},end:{line:49,column:7}},line:47},4:{name:"(anonymous_4)",decl:{start:{line:50,column:6},end:{line:50,column:7}},loc:{start:{line:50,column:17},end:{line:52,column:7}},line:50},5:{name:"(anonymous_5)",decl:{start:{line:58,column:15},end:{line:58,column:16}},loc:{start:{line:58,column:27},end:{line:60,column:7}},line:58},6:{name:"(anonymous_6)",decl:{start:{line:64,column:15},end:{line:64,column:16}},loc:{start:{line:64,column:32},end:{line:76,column:5}},line:64},7:{name:"(anonymous_7)",decl:{start:{line:77,column:18},end:{line:77,column:19}},loc:{start:{line:77,column:35},end:{line:84,column:5}},line:77},8:{name:"(anonymous_8)",decl:{start:{line:85,column:16},end:{line:85,column:17}},loc:{start:{line:85,column:32},end:{line:88,column:5}},line:85},9:{name:"(anonymous_9)",decl:{start:{line:89,column:24},end:{line:89,column:25}},loc:{start:{line:89,column:36},end:{line:91,column:5}},line:89}},branchMap:{0:{loc:{start:{line:34,column:6},end:{line:38,column:7}},type:"if",locations:[{start:{line:34,column:6},end:{line:38,column:7}},{start:{line:36,column:13},end:{line:38,column:7}}],line:34},1:{loc:{start:{line:34,column:10},end:{line:34,column:70}},type:"binary-expr",locations:[{start:{line:34,column:10},end:{line:34,column:41}},{start:{line:34,column:45},end:{line:34,column:70}}],line:34},2:{loc:{start:{line:41,column:6},end:{line:43,column:7}},type:"if",locations:[{start:{line:41,column:6},end:{line:43,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:41},3:{loc:{start:{line:66,column:6},end:{line:68,column:7}},type:"if",locations:[{start:{line:66,column:6},end:{line:68,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:66}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,sources:["AddComponentDialog.vue"],names:[],mappings:";AA+KA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"AddComponentDialog.vue",sourceRoot:"src/tools/DataViewer",sourcesContent:['\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addstopums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n \x3c!-- Dialog for adding a new component to a tab --\x3e\n <v-dialog v-model="show" width="800">\n <v-card>\n <v-system-bar>\n <v-spacer />\n <span> Configure Component </span>\n <v-spacer />\n </v-system-bar>\n <v-card-text>\n <v-container>\n <v-row align="center">\n <v-col>Select Component:</v-col>\n <v-col>\n <v-select\n hide-details\n dense\n outlined\n :items="components"\n item-text="label"\n item-value="value"\n v-model="selectedComponent"\n return-object\n data-test="select-component"\n />\n </v-col>\n </v-row>\n <v-row\n ><v-col>Add packets for this component to process.</v-col></v-row\n >\n <v-row>\n <v-col class="my-2">\n <v-radio-group\n v-model="newPacketCmdOrTlm"\n row\n hide-details\n class="mt-0"\n >\n <v-radio\n label="Command"\n value="cmd"\n data-test="command-packet-radio"\n />\n <v-radio\n label="Telemetry"\n value="tlm"\n data-test="telemetry-packet-radio"\n />\n </v-radio-group>\n </v-col>\n </v-row>\n <v-row>\n <v-col>\n <target-packet-item-chooser\n unknown\n button-text="Add Packet"\n @click="addPacket"\n />\n </v-col>\n </v-row>\n <v-row>\n <v-col>\n <v-radio-group v-model="newPacketMode" row hide-details>\n <v-radio\n label="Raw"\n value="RAW"\n data-test="new-packet-raw-radio"\n />\n <v-radio\n label="Decom"\n value="DECOM"\n :disabled="disableRadioOptions"\n data-test="new-packet-decom-radio"\n />\n </v-radio-group>\n </v-col>\n <v-col>\n <v-select\n v-if="newPacketMode === \'DECOM\'"\n v-model="newPacketValueType"\n hide-details\n label="Value Type"\n data-test="add-packet-value-type"\n :items="valueTypes"\n />\n </v-col>\n </v-row>\n <v-row\n ><v-col>\n <v-data-table\n :headers="headers"\n :items="packets"\n :search="search"\n :items-per-page="itemsPerPage"\n @update:items-per-page="itemsPerPage = $event"\n :footer-props="{\n itemsPerPageOptions: [10, 100],\n showFirstLastPage: true,\n firstIcon: \'mdi-page-first\',\n lastIcon: \'mdi-page-last\',\n prevIcon: \'mdi-chevron-left\',\n nextIcon: \'mdi-chevron-right\',\n }"\n calculate-widths\n multi-sort\n dense\n >\n <template v-slot:item.delete="{ item }">\n <v-tooltip bottom>\n <template v-slot:activator="{ on, attrs }">\n <v-icon\n @click="deleteItem(item)"\n v-bind="attrs"\n v-on="on"\n >\n mdi-delete\n </v-icon>\n </template>\n <span>Delete Item</span>\n </v-tooltip>\n </template>\n </v-data-table>\n </v-col></v-row\n >\n </v-container>\n </v-card-text>\n <v-card-actions>\n <v-spacer />\n <v-btn\n outlined\n class="mx-2"\n data-test="cancel-component"\n @click="cancelAddComponent"\n >\n Cancel\n </v-btn>\n <v-btn\n color="primary"\n class="mx-2"\n data-test="add-component"\n :disabled="notValid"\n @click="addComponent"\n >\n Create\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n </div>\n</template>\n\n<script>\nimport TargetPacketItemChooser from \'@openc3/tool-common/src/components/TargetPacketItemChooser\'\n\nexport default {\n components: {\n TargetPacketItemChooser,\n },\n props: {\n value: Boolean, // value is the default prop when using v-model\n components: Object,\n },\n data() {\n return {\n selectedComponent: this.components[0],\n newPacket: null,\n newPacketCmdOrTlm: \'tlm\',\n newPacketMode: \'RAW\',\n valueTypes: [\'CONVERTED\', \'RAW\', \'FORMATTED\', \'WITH_UNITS\'],\n newPacketValueType: \'WITH_UNITS\',\n headers: [\n { text: \'Cmd/Tlm\', value: \'cmdOrTlm\' },\n { text: \'Target\', value: \'targetName\' },\n { text: \'Packet\', value: \'packetName\' },\n { text: \'Mode\', value: \'mode\' },\n { text: \'ValueType\', value: \'valueType\' },\n { text: \'Delete\', value: \'delete\' },\n ],\n itemsPerPage: 20,\n packets: [],\n }\n },\n computed: {\n notValid: function () {\n if (this.selectedComponent === null || this.packets.length === 0) {\n return true\n } else {\n return false\n }\n },\n disableRadioOptions: function () {\n if (this.newPacket) {\n return this.newPacket.packet === \'UNKNOWN\'\n }\n return false\n },\n show: {\n get() {\n return this.value\n },\n set(value) {\n this.$emit(\'input\', value) // input is the default event when using v-model\n },\n },\n },\n watch: {\n newPacketCmdOrTlm: {\n immediate: true,\n handler: function () {\n this.newPacket = null\n },\n },\n },\n methods: {\n addPacket: function (event) {\n let type = this.newPacketValueType\n if (this.newPacketMode === \'RAW\') {\n type = \'N/A\'\n }\n this.packets.push({\n cmdOrTlm: this.newPacketCmdOrTlm.toUpperCase(),\n targetName: event.targetName,\n packetName: event.packetName,\n mode: this.newPacketMode,\n valueType: type,\n })\n },\n addComponent: function (event) {\n this.$emit(\'add\', {\n packets: this.packets,\n component: this.selectedComponent,\n mode: this.newPacketMode,\n valueType: this.newPacketValueType,\n })\n },\n deleteItem: function (item) {\n var index = this.packets.indexOf(item)\n this.packets.splice(index, 1)\n },\n cancelAddComponent: function () {\n this.$emit(\'cancel\', {})\n },\n },\n}\n<\/script>\n']},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"61dc42db7c91abce276d9244422190456608f03f"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return X=function(){return a},a}X();const J={components:{TargetPacketItemChooser:Z},props:{value:Boolean,components:Object},data(){return X().f[0]++,X().s[0]++,{selectedComponent:this.components[0],newPacket:null,newPacketCmdOrTlm:"tlm",newPacketMode:"RAW",valueTypes:["CONVERTED","RAW","FORMATTED","WITH_UNITS"],newPacketValueType:"WITH_UNITS",headers:[{text:"Cmd/Tlm",value:"cmdOrTlm"},{text:"Target",value:"targetName"},{text:"Packet",value:"packetName"},{text:"Mode",value:"mode"},{text:"ValueType",value:"valueType"},{text:"Delete",value:"delete"}],itemsPerPage:20,packets:[]}},computed:{notValid:function(){return X().f[1]++,X().s[1]++,X().b[1][0]++,null===this.selectedComponent||(X().b[1][1]++,0===this.packets.length)?(X().b[0][0]++,X().s[2]++,!0):(X().b[0][1]++,X().s[3]++,!1)},disableRadioOptions:function(){return X().f[2]++,X().s[4]++,this.newPacket?(X().b[2][0]++,X().s[5]++,"UNKNOWN"===this.newPacket.packet):(X().b[2][1]++,X().s[6]++,!1)},show:{get(){return X().f[3]++,X().s[7]++,this.value},set(e){X().f[4]++,X().s[8]++,this.$emit("input",e)}}},watch:{newPacketCmdOrTlm:{immediate:!0,handler:function(){X().f[5]++,X().s[9]++,this.newPacket=null}}},methods:{addPacket:function(e){X().f[6]++;let n=(X().s[10]++,this.newPacketValueType);X().s[11]++,"RAW"===this.newPacketMode?(X().b[3][0]++,X().s[12]++,n="N/A"):X().b[3][1]++,X().s[13]++,this.packets.push({cmdOrTlm:this.newPacketCmdOrTlm.toUpperCase(),targetName:e.targetName,packetName:e.packetName,mode:this.newPacketMode,valueType:n})},addComponent:function(e){X().f[7]++,X().s[14]++,this.$emit("add",{packets:this.packets,component:this.selectedComponent,mode:this.newPacketMode,valueType:this.newPacketValueType})},deleteItem:function(e){X().f[8]++;var n=(X().s[15]++,this.packets.indexOf(e));X().s[16]++,this.packets.splice(n,1)},cancelAddComponent:function(){X().f[9]++,X().s[17]++,this.$emit("cancel",{})}}},Q=J;var ee=(0,T.Z)(Q,B,W,!1,null,null,null);const ne=ee.exports;function te(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DynamicComponent.vue",n="683d9f83ba62344b008ac49ba690564dd445d63e",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DynamicComponent.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:266}},4:{start:{line:1,column:184},end:{line:1,column:210}},5:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:171},end:{line:1,column:172}},loc:{start:{line:1,column:184},end:{line:1,column:210}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"683d9f83ba62344b008ac49ba690564dd445d63e"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return te=function(){return a},a}te(),te().s[0]++;var le=function(){te().f[0]++;var e=(te().s[1]++,this),n=(te().s[2]++,e._self._c);return te().s[3]++,n(e.widgetType,e._b({ref:"dynamic",tag:"component",attrs:{config:e.currentConfig},on:{config:n=>(te().f[1]++,te().s[4]++,e.currentConfig=n)}},"component",{...e.$props,...e.$attrs},!1))},oe=(te().s[5]++,[]);const ie={props:{config:{type:Object},packets:{type:Array}},data:function(){return{currentConfig:{},currentPackets:[],latestData:null}},computed:{hasRaw:function(){for(let e=0;e<this.currentPackets.length;e++)if("RAW"===this.currentPackets[e].mode)return!0;return!1},hasDecom:function(){for(let e=0;e<this.currentPackets.length;e++)if("DECOM"===this.currentPackets[e].mode)return!0;return!1}},watch:{currentConfig:{deep:!0,handler:function(e){this.$emit("config",e)}}},created:function(){this.config&&(this.currentConfig={...this.config}),this.packets&&(this.currentPackets=[...this.packets])},methods:{receive:function(e){this.latestData=e}}};function ae(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DynamicComponent.vue",n="bb923feddbd69c5fa223c7b28bb2331f8d7de1ca",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DynamicComponent.vue",statementMap:{0:{start:{line:7,column:4},end:{line:9,column:5}},1:{start:{line:16,column:6},end:{line:16,column:91}},2:{start:{line:21,column:6},end:{line:21,column:41}},3:{start:{line:25,column:4},end:{line:30,column:5}},4:{start:{line:27,column:6},end:{line:27,column:79}},5:{start:{line:29,column:6},end:{line:29,column:53}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:9},end:{line:10,column:3}},line:6},1:{name:"(anonymous_1)",decl:{start:{line:15,column:9},end:{line:15,column:10}},loc:{start:{line:15,column:21},end:{line:17,column:5}},line:15},2:{name:"(anonymous_2)",decl:{start:{line:20,column:16},end:{line:20,column:17}},loc:{start:{line:20,column:32},end:{line:22,column:5}},line:20},3:{name:"(anonymous_3)",decl:{start:{line:24,column:2},end:{line:24,column:3}},loc:{start:{line:24,column:18},end:{line:31,column:3}},line:24}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0,2:0,3:0},b:{},inputSourceMap:{version:3,sources:["DynamicComponent.vue"],names:[],mappings:";AA6BA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"DynamicComponent.vue",sourceRoot:"src/tools/DataViewer",sourcesContent:['\x3c!--\n# Copyright 2022 OpenC3, Inc.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <component\n ref="dynamic"\n :is="widgetType"\n :config="currentConfig"\n @config="(config) => (currentConfig = config)"\n v-bind="{ ...$props, ...$attrs }"\n ></component>\n</template>\n\n<script>\nimport Component from \'@openc3/tool-common/src/components/dataviewer/Component\'\n\nexport default {\n mixins: [Component],\n data() {\n return {\n widgetType: null,\n }\n },\n props: {\n name: { default: null },\n },\n computed: {\n url: function () {\n return `${window.location.origin}/tools/widgets/${this.name}/${this.name}.umd.min.js`\n },\n },\n watch: {\n latestData: function (data) {\n this.$refs[\'dynamic\'].receive(data)\n },\n },\n async mounted() {\n try {\n /* eslint-disable-next-line */\n this.widgetType = await System.import(/* webpackIgnore: true */ this.url)\n } catch (e) {\n throw new Error(`Unknown widget: ${this.name}`)\n }\n },\n}\n<\/script>\n']},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"bb923feddbd69c5fa223c7b28bb2331f8d7de1ca"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return ae=function(){return a},a}ae();const se={mixins:[ie],data(){return ae().f[0]++,ae().s[0]++,{widgetType:null}},props:{name:{default:null}},computed:{url:function(){return ae().f[1]++,ae().s[1]++,`${window.location.origin}/tools/widgets/${this.name}/${this.name}.umd.min.js`}},watch:{latestData:function(e){ae().f[2]++,ae().s[2]++,this.$refs["dynamic"].receive(e)}},async mounted(){ae().f[3]++,ae().s[3]++;try{ae().s[4]++,this.widgetType=await System.import(this.url)}catch(e){throw ae().s[5]++,new Error(`Unknown widget: ${this.name}`)}}},ce=se;var re=(0,T.Z)(ce,le,oe,!1,null,null,null);const ue=re.exports;function me(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DumpComponent.vue",n="6e7aed508e299df55187c4d24d333fd30a1ae7fe",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DumpComponent.vue",statementMap:{0:{start:{line:1,column:13},end:{line:2,column:1}},1:{start:{line:1,column:39},end:{line:1,column:43}},2:{start:{line:1,column:47},end:{line:1,column:59}},3:{start:{line:1,column:60},end:{line:1,column:271}},4:{start:{line:1,column:241},end:{line:1,column:267}},5:{start:{line:3,column:22},end:{line:3,column:24}}},fnMap:{0:{name:"render",decl:{start:{line:1,column:22},end:{line:1,column:28}},loc:{start:{line:1,column:30},end:{line:2,column:1}},line:1},1:{name:"(anonymous_1)",decl:{start:{line:1,column:228},end:{line:1,column:229}},loc:{start:{line:1,column:241},end:{line:1,column:267}},line:1}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0},b:{},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6e7aed508e299df55187c4d24d333fd30a1ae7fe"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return me=function(){return a},a}me(),me().s[0]++;var de=function(){me().f[0]++;var e=(me().s[1]++,this),n=(me().s[2]++,e._self._c);return me().s[3]++,n("history-component",{ref:"history",attrs:{config:e.currentConfig,packets:e.currentPackets,calculatePacketText:e.calculatePacketText},on:{config:n=>(me().f[1]++,me().s[4]++,e.currentConfig=n)}})},Ae=(me().s[5]++,[]),pe=function(){var e=this,n=e._self._c;return n("v-container",{staticClass:"pt-0"},[n("v-row",{attrs:{dense:""}},[n("v-col",[n("v-text-field",{staticClass:"pt-0 mt-0",attrs:{label:"Search","append-icon":"mdi-magnify","single-line":"","hide-details":"","data-test":"history-component-search"},model:{value:e.filterText,callback:function(n){e.filterText=n},expression:"filterText"}})],1)],1),e._v(" "),n("v-row",[n("v-col",[n("v-slider",{attrs:{"prepend-icon":"mdi-step-backward","append-icon":"mdi-step-forward",min:1-e.currentConfig.history,max:0,"hide-details":""},on:{mousedown:e.pause,"click:prepend":e.stepBackward,"click:append":e.stepForward},model:{value:e.pauseOffset,callback:function(n){e.pauseOffset=n},expression:"pauseOffset"}})],1)],1),e._v(" "),n("v-row",{attrs:{dense:"","no-gutters":""}},[n("v-col",[n("div",{staticClass:"text-area-container"},[n("v-textarea",{ref:"textarea",attrs:{value:e.displayText,rows:"1","no-resize":"",readonly:"",solo:"",flat:"","hide-details":"","data-test":"history-component-text-area"}}),e._v(" "),n("div",{staticClass:"floating-buttons"},[n("v-menu",{attrs:{"close-on-content-click":!1,"min-width":700,"nudge-left":710,"nudge-top":250},scopedSlots:e._u([{key:"activator",fn:function({on:t,attrs:l}){return[n("v-btn",e._g(e._b({staticClass:"ml-2",attrs:{color:"secondary",fab:"",small:"","data-test":"history-component-open-settings"}},"v-btn",l,!1),t),[n("v-icon",[e._v("$astro-settings")])],1)]}}])},[e._v(" "),n("v-card",[n("v-card-title",{attrs:{"data-test":"display-settings-card"}},[e._v("\n Display settings\n ")]),e._v(" "),n("v-card-text",[n("v-row",[n("v-col",[n("v-switch",{attrs:{label:"Show timestamp",dense:"","hide-details":"","data-test":"history-component-settings-show-timestamp"},model:{value:e.currentConfig.showTimestamp,callback:function(n){e.$set(e.currentConfig,"showTimestamp",n)},expression:"currentConfig.showTimestamp"}}),e._v(" "),e.hasRaw?n("v-switch",{attrs:{label:"Show ASCII",dense:"","hide-details":"","data-test":"history-component-settings-show-ascii"},model:{value:e.currentConfig.showAscii,callback:function(n){e.$set(e.currentConfig,"showAscii",n)},expression:"currentConfig.showAscii"}}):e._e(),e._v(" "),e.hasRaw?n("v-switch",{attrs:{label:"Show line address",dense:"","hide-details":"","data-test":"history-component-settings-show-address"},model:{value:e.currentConfig.showLineAddress,callback:function(n){e.$set(e.currentConfig,"showLineAddress",n)},expression:"currentConfig.showLineAddress"}}):e._e()],1),e._v(" "),n("v-col",[n("v-radio-group",{attrs:{label:"Print newest packets to the"},model:{value:e.currentConfig.newestAtTop,callback:function(n){e.$set(e.currentConfig,"newestAtTop",n)},expression:"currentConfig.newestAtTop"}},[n("v-radio",{attrs:{label:"Top",value:!0,"data-test":"history-component-settings-newest-top"}}),e._v(" "),n("v-radio",{attrs:{label:"Bottom",value:!1,"data-test":"history-component-settings-newest-bottom"}})],1)],1),e._v(" "),n("v-col",[n("v-text-field",{attrs:{label:"History Buffer",type:"number",min:"1","persistent-hint":"",rules:[e.rules.required,e.rules.min],"data-test":"history-component-settings-history"},model:{value:e.currentConfig.history,callback:function(n){e.$set(e.currentConfig,"history",n)},expression:"currentConfig.history"}}),e._v(" "),e.hasRaw?n("v-text-field",{attrs:{label:"Bytes per line",type:"number",min:"1",rules:[e.rules.required,e.rules.min],"data-test":"history-component-settings-num-bytes"},model:{value:e.currentConfig.bytesPerLine,callback:function(n){e.$set(e.currentConfig,"bytesPerLine",n)},expression:"currentConfig.bytesPerLine"}}):e._e(),e._v(" "),n("v-text-field",{attrs:{label:"Packets to show",type:"number",min:"1",hint:`Maximum: ${e.currentConfig.history}`,"persistent-hint":"",rules:[e.rules.required,e.rules.min,e.rules.max],"data-test":"history-component-settings-num-packets"},model:{value:e.currentConfig.packetsToShow,callback:function(n){e.$set(e.currentConfig,"packetsToShow",n)},expression:"currentConfig.packetsToShow"}})],1)],1)],1)],1)],1),e._v(" "),n("v-btn",{staticClass:"ml-2",attrs:{color:"secondary",fab:"",small:"","data-test":"history-component-download"},on:{click:e.download}},[n("v-icon",[e._v("mdi-file-download")])],1),e._v(" "),n("v-btn",{staticClass:"ml-2",class:{pulse:e.paused},attrs:{color:"primary",fab:"","data-test":"history-component-play-pause"},on:{click:e.togglePlayPause}},[e.paused?n("v-icon",{attrs:{large:""}},[e._v("mdi-play")]):n("v-icon",{attrs:{large:""}},[e._v("mdi-pause")])],1)],1)],1)])],1)],1)},he=[],fe=(t(823),t(1629),t(4163),t(5850),t(3631),t(1399),t(6635)),ve=t.n(fe);const Ce={props:["calculatePacketText"],mixins:[ie],data:function(){return{history:[],historyPointer:-1,filterText:"",paused:!1,pausedAt:0,pauseOffset:0,pausedHistory:[],textarea:null,displayText:"",rules:{required:e=>!!e||"Required.",min:e=>e>=1||"Minimum: 1",max:e=>parseInt(e)<=this.currentConfig.history||`Maximum: ${this.currentConfig.history}`}}},computed:{allInstantSettings:function(){return`${this.currentConfig.showLineAddress}|${this.currentConfig.showTimestamp}|${this.currentConfig.showAscii}|${this.currentConfig.newestAtTop}|${this.pauseOffset}`},allDebouncedSettings:function(){return`${this.currentConfig.bytesPerLine}|${this.currentConfig.packetsToShow}|${this.filterText}`}},watch:{latestData:function(e){e.forEach((e=>{"buffer"in e&&(e.buffer=atob(e.buffer)),this.historyPointer=++this.historyPointer%this.currentConfig.history,isNaN(this.historyPointer)&&(this.historyPointer=0),this.history[this.historyPointer]=e,this.paused||this.rebuildDisplayText()}))},paused:function(e){e?(this.pausedAt=this.historyPointer,this.pausedHistory=this.history.slice()):(this.pauseOffset=0,this.rebuildDisplayText())},allInstantSettings:function(){this.rebuildDisplayText()},allDebouncedSettings:ve().debounce((function(){this.rebuildDisplayText()}),300)},created:function(){const e={history:300,showTimestamp:!0,showAscii:!0,showLineAddress:!0,packetsToShow:1,bytesPerLine:16,newestAtTop:!0};this.currentConfig={...e,...this.currentConfig}},mounted:function(){this.textarea=this.$refs.textarea.$el.querySelectorAll("textarea")[0]},methods:{rebuildDisplayText:function(){let e=this.paused?this.pausedHistory:this.history;const n=this.paused?this.pausedAt:this.historyPointer;if(e=e.filter((e=>e)).slice(n+1,this.currentConfig.history).concat(e.slice(0,n+1)).map(this.calculatePacketText).map(this.matchesSearch),this.paused){const n=Math.max(e.length+this.pauseOffset,1);e=e.slice(0,n)}const t=Math.max(this.currentConfig.packetsToShow,1);e=e.slice(-t),this.currentConfig.newestAtTop&&(e=e.reverse());let l="\n";""===this.filterText&&(l+="\n"),this.displayText=e.join(l)},matchesSearch:function(e){return""===this.filterText?e:e.split("\n").filter((e=>e.toLowerCase().includes(this.filterText.toLowerCase()))).join("\n")},download:function(){const e=new Blob([this.displayText],{type:"text/plain"}),n=document.createElement("a");let t=URL.createObjectURL(e);n.href=t,n.setAttribute("download",`${(0,a.Z)(new Date,"yyyy_MM_dd_HH_mm_ss")}.txt`),n.click(),window.URL.revokeObjectURL(t)},pause:function(){this.paused=!0},togglePlayPause:function(){this.paused=!this.paused},stepBackward:function(){this.pause(),this.pauseOffset--},stepForward:function(){this.pause(),this.pauseOffset++}}},ge=Ce;t(5442);var be=(0,T.Z)(ge,pe,he,!1,null,"625a8260",null);const _e=be.exports;function ye(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DumpComponent.vue",n="c7d6c674fa23b8e86b3f3eebeeae52b012b0eb47",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DumpComponent.vue",statementMap:{0:{start:{line:13,column:6},end:{line:13,column:41}},1:{start:{line:18,column:17},end:{line:18,column:19}},2:{start:{line:19,column:6},end:{line:28,column:7}},3:{start:{line:20,column:29},end:{line:20,column:52}},4:{start:{line:21,column:32},end:{line:21,column:64}},5:{start:{line:22,column:29},end:{line:22,column:65}},6:{start:{line:23,column:24},end:{line:23,column:72}},7:{start:{line:24,column:8},end:{line:24,column:63}},8:{start:{line:25,column:8},end:{line:25,column:57}},9:{start:{line:26,column:8},end:{line:26,column:69}},10:{start:{line:27,column:8},end:{line:27,column:36}},11:{start:{line:29,column:6},end:{line:61,column:7}},12:{start:{line:31,column:8},end:{line:55,column:21}},13:{start:{line:34,column:30},end:{line:36,column:13}},14:{start:{line:35,column:14},end:{line:35,column:62}},15:{start:{line:37,column:29},end:{line:37,column:68}},16:{start:{line:38,column:23},end:{line:38,column:68}},17:{start:{line:39,column:12},end:{line:45,column:13}},18:{start:{line:40,column:14},end:{line:40,column:28}},19:{start:{line:41,column:14},end:{line:43,column:15}},20:{start:{line:42,column:16},end:{line:42,column:70}},21:{start:{line:44,column:14},end:{line:44,column:42}},22:{start:{line:47,column:12},end:{line:52,column:13}},23:{start:{line:48,column:30},end:{line:50,column:33}},24:{start:{line:51,column:14},end:{line:51,column:42}},25:{start:{line:53,column:12},end:{line:53,column:23}},26:{start:{line:57,column:8},end:{line:60,column:21}},27:{start:{line:58,column:28},end:{line:58,column:52}},28:{start:{line:59,column:25},end:{line:59,column:51}},29:{start:{line:62,column:6},end:{line:62,column:17}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:12,column:16},end:{line:12,column:17}},loc:{start:{line:12,column:32},end:{line:14,column:5}},line:12},1:{name:"(anonymous_1)",decl:{start:{line:17,column:25},end:{line:17,column:26}},loc:{start:{line:17,column:43},end:{line:63,column:5}},line:17},2:{name:"(anonymous_2)",decl:{start:{line:32,column:15},end:{line:32,column:16}},loc:{start:{line:32,column:37},end:{line:54,column:11}},line:32},3:{name:"(anonymous_3)",decl:{start:{line:34,column:44},end:{line:34,column:45}},loc:{start:{line:35,column:14},end:{line:35,column:62}},line:35},4:{name:"(anonymous_4)",decl:{start:{line:41,column:42},end:{line:41,column:43}},loc:{start:{line:42,column:16},end:{line:42,column:70}},line:42},5:{name:"(anonymous_5)",decl:{start:{line:58,column:18},end:{line:58,column:19}},loc:{start:{line:58,column:28},end:{line:58,column:52}},line:58},6:{name:"(anonymous_6)",decl:{start:{line:59,column:15},end:{line:59,column:16}},loc:{start:{line:59,column:25},end:{line:59,column:51}},line:59}},branchMap:{0:{loc:{start:{line:19,column:6},end:{line:28,column:7}},type:"if",locations:[{start:{line:19,column:6},end:{line:28,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:19},1:{loc:{start:{line:29,column:6},end:{line:61,column:7}},type:"if",locations:[{start:{line:29,column:6},end:{line:61,column:7}},{start:{line:56,column:13},end:{line:61,column:7}}],line:29},2:{loc:{start:{line:39,column:12},end:{line:45,column:13}},type:"if",locations:[{start:{line:39,column:12},end:{line:45,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:39},3:{loc:{start:{line:47,column:12},end:{line:52,column:13}},type:"if",locations:[{start:{line:47,column:12},end:{line:52,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:47}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,sources:["DumpComponent.vue"],names:[],mappings:";AAiCA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"DumpComponent.vue",sourceRoot:"src/tools/DataViewer",sourcesContent:["\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <history-component\n ref=\"history\"\n :config=\"currentConfig\"\n :packets=\"currentPackets\"\n :calculatePacketText=\"calculatePacketText\"\n @config=\"(config) => (currentConfig = config)\"\n ></history-component>\n</template>\n\n<script>\nimport HistoryComponent from '@openc3/tool-common/src/components/dataviewer/HistoryComponent'\nimport Component from '@openc3/tool-common/src/components/dataviewer/Component'\n\nexport default {\n mixins: [Component],\n components: {\n HistoryComponent,\n },\n watch: {\n // Hook the HistoryComponent's receive method to our latestData being updated\n latestData: function (data) {\n this.$refs['history'].receive(data)\n },\n },\n methods: {\n calculatePacketText: function (packet) {\n let text = ''\n if (this.currentConfig.showTimestamp) {\n const milliseconds = packet.__time / 1000000\n const receivedSeconds = (milliseconds / 1000).toFixed(7)\n const receivedDate = new Date(milliseconds).toISOString()\n let timestamp = '********************************************\\n'\n timestamp += `* Received seconds: ${receivedSeconds}\\n`\n timestamp += `* Received time: ${receivedDate}\\n`\n timestamp += '********************************************\\n'\n text = `${timestamp}${text}`\n }\n if ('buffer' in packet) {\n // Split its buffer into lines of the selected length\n text += _.chunk([...packet.buffer], this.currentConfig.bytesPerLine)\n .map((lineBytes, index) => {\n // Map each line into ASCII or hex values\n let mappedBytes = lineBytes.map((byte) =>\n byte.charCodeAt(0).toString(16).padStart(2, '0'),\n )\n let lineLength = this.currentConfig.bytesPerLine * 3 - 1\n let line = mappedBytes.join(' ').padEnd(lineLength, ' ')\n if (this.currentConfig.showAscii) {\n line += ' '\n mappedBytes = lineBytes.map((byte) =>\n byte.replaceAll(/\\n/g, '\\\\n').replaceAll(/\\r/g, '\\\\r'),\n )\n line += mappedBytes.join('')\n }\n // Prepend the line address if needed\n if (this.currentConfig.showLineAddress) {\n const address = (index * this.currentConfig.bytesPerLine)\n .toString(16)\n .padStart(8, '0')\n line = `${address}: ${line}`\n }\n return line\n })\n .join('\\n') // end of one line\n } else {\n text += Object.keys(packet)\n .filter((item) => item.slice(0, 2) != '__')\n .map((item) => `${item}: ${packet[item]}`)\n .join('\\n')\n }\n return text\n },\n },\n}\n<\/script>\n"]},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c7d6c674fa23b8e86b3f3eebeeae52b012b0eb47"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return ye=function(){return a},a}ye();const ke={mixins:[ie],components:{HistoryComponent:_e},watch:{latestData:function(e){ye().f[0]++,ye().s[0]++,this.$refs["history"].receive(e)}},methods:{calculatePacketText:function(e){ye().f[1]++;let n=(ye().s[1]++,"");if(ye().s[2]++,this.currentConfig.showTimestamp){ye().b[0][0]++;const t=(ye().s[3]++,e.__time/1e6),l=(ye().s[4]++,(t/1e3).toFixed(7)),o=(ye().s[5]++,new Date(t).toISOString());let i=(ye().s[6]++,"********************************************\n");ye().s[7]++,i+=`* Received seconds: ${l}\n`,ye().s[8]++,i+=`* Received time: ${o}\n`,ye().s[9]++,i+="********************************************\n",ye().s[10]++,n=`${i}${n}`}else ye().b[0][1]++;return ye().s[11]++,"buffer"in e?(ye().b[1][0]++,ye().s[12]++,n+=_.chunk([...e.buffer],this.currentConfig.bytesPerLine).map(((e,n)=>{ye().f[2]++;let t=(ye().s[13]++,e.map((e=>(ye().f[3]++,ye().s[14]++,e.charCodeAt(0).toString(16).padStart(2,"0"))))),l=(ye().s[15]++,3*this.currentConfig.bytesPerLine-1),o=(ye().s[16]++,t.join(" ").padEnd(l," "));if(ye().s[17]++,this.currentConfig.showAscii?(ye().b[2][0]++,ye().s[18]++,o+=" ",ye().s[19]++,t=e.map((e=>(ye().f[4]++,ye().s[20]++,e.replaceAll(/\n/g,"\\n").replaceAll(/\r/g,"\\r")))),ye().s[21]++,o+=t.join("")):ye().b[2][1]++,ye().s[22]++,this.currentConfig.showLineAddress){ye().b[3][0]++;const e=(ye().s[23]++,(n*this.currentConfig.bytesPerLine).toString(16).padStart(8,"0"));ye().s[24]++,o=`${e}: ${o}`}else ye().b[3][1]++;return ye().s[25]++,o})).join("\n")):(ye().b[1][1]++,ye().s[26]++,n+=Object.keys(e).filter((e=>(ye().f[5]++,ye().s[27]++,"__"!=e.slice(0,2)))).map((n=>(ye().f[6]++,ye().s[28]++,`${n}: ${e[n]}`))).join("\n")),ye().s[29]++,n}}},we=ke;var Te=(0,T.Z)(we,de,Ae,!1,null,null,null);const xe=Te.exports;function Ne(){var e="/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DataViewer.vue",n="7c4898469910ee702797fcbe869d9eb9cdb0d264",t=new Function("return this")(),l="__coverage__",o={path:"/openc3/plugins/packages/openc3-cosmos-tool-dataviewer/src/tools/DataViewer/DataViewer.vue",statementMap:{0:{start:{line:27,column:4},end:{line:93,column:5}},1:{start:{line:44,column:29},end:{line:44,column:50}},2:{start:{line:59,column:16},end:{line:59,column:38}},3:{start:{line:66,column:16},end:{line:66,column:38}},4:{start:{line:73,column:16},end:{line:73,column:38}},5:{start:{line:97,column:6},end:{line:103,column:7}},6:{start:{line:106,column:6},end:{line:108,column:8}},7:{start:{line:107,column:8},end:{line:107,column:26}},8:{start:{line:113,column:6},end:{line:113,column:23}},9:{start:{line:119,column:6},end:{line:121,column:7}},10:{start:{line:120,column:8},end:{line:120,column:20}},11:{start:{line:126,column:4},end:{line:144,column:6}},12:{start:{line:127,column:6},end:{line:143,column:8}},13:{start:{line:129,column:22},end:{line:129,column:56}},14:{start:{line:130,column:8},end:{line:142,column:9}},15:{start:{line:131,column:10},end:{line:141,column:12}},16:{start:{line:132,column:24},end:{line:132,column:43}},17:{start:{line:133,column:12},end:{line:136,column:13}},18:{start:{line:134,column:14},end:{line:134,column:50}},19:{start:{line:135,column:14},end:{line:135,column:68}},20:{start:{line:137,column:12},end:{line:140,column:14}},21:{start:{line:145,column:4},end:{line:145,column:20}},22:{start:{line:148,column:27},end:{line:148,column:72}},23:{start:{line:150,column:4},end:{line:156,column:5}},24:{start:{line:151,column:6},end:{line:151,column:27}},25:{start:{line:152,column:6},end:{line:152,column:60}},26:{start:{line:153,column:11},end:{line:156,column:5}},27:{start:{line:154,column:6},end:{line:154,column:27}},28:{start:{line:155,column:6},end:{line:155,column:44}},29:{start:{line:159,column:4},end:{line:161,column:5}},30:{start:{line:160,column:6},end:{line:160,column:37}},31:{start:{line:162,column:4},end:{line:162,column:27}},32:{start:{line:166,column:6},end:{line:166,column:75}},33:{start:{line:169,column:6},end:{line:169,column:53}},34:{start:{line:169,column:27},end:{line:169,column:53}},35:{start:{line:172,column:6},end:{line:172,column:28}},36:{start:{line:174,column:6},end:{line:178,column:7}},37:{start:{line:175,column:8},end:{line:175,column:62}},38:{start:{line:176,column:8},end:{line:176,column:27}},39:{start:{line:177,column:8},end:{line:177,column:14}},40:{start:{line:180,column:6},end:{line:184,column:7}},41:{start:{line:181,column:8},end:{line:181,column:71}},42:{start:{line:182,column:8},end:{line:182,column:27}},43:{start:{line:183,column:8},end:{line:183,column:14}},44:{start:{line:186,column:6},end:{line:194,column:7}},45:{start:{line:187,column:8},end:{line:192,column:24}},46:{start:{line:193,column:8},end:{line:193,column:27}},47:{start:{line:195,column:6},end:{line:195,column:25}},48:{start:{line:196,column:6},end:{line:196,column:37}},49:{start:{line:199,column:6},end:{line:199,column:26}},50:{start:{line:200,column:6},end:{line:200,column:42}},51:{start:{line:203,column:6},end:{line:225,column:10}},52:{start:{line:205,column:30},end:{line:205,column:49}},53:{start:{line:207,column:12},end:{line:207,column:32}},54:{start:{line:208,column:12},end:{line:208,column:42}},55:{start:{line:211,column:12},end:{line:211,column:23}},56:{start:{line:212,column:12},end:{line:212,column:33}},57:{start:{line:213,column:12},end:{line:213,column:72}},58:{start:{line:214,column:12},end:{line:214,column:31}},59:{start:{line:215,column:12},end:{line:215,column:41}},60:{start:{line:218,column:12},end:{line:218,column:68}},61:{start:{line:219,column:12},end:{line:219,column:31}},62:{start:{line:223,column:10},end:{line:223,column:42}},63:{start:{line:224,column:10},end:{line:224,column:59}},64:{start:{line:224,column:28},end:{line:224,column:59}},65:{start:{line:228,column:6},end:{line:228,column:42}},66:{start:{line:230,column:25},end:{line:237,column:12}},67:{start:{line:231,column:8},end:{line:235,column:9}},68:{start:{line:232,column:10},end:{line:232,column:42}},69:{start:{line:234,column:10},end:{line:234,column:40}},70:{start:{line:236,column:8},end:{line:236,column:21}},71:{start:{line:238,column:6},end:{line:241,column:8}},72:{start:{line:240,column:8},end:{line:240,column:57}},73:{start:{line:242,column:6},end:{line:256,column:7}},74:{start:{line:244,column:10},end:{line:246,column:11}},75:{start:{line:245,column:12},end:{line:245,column:34}},76:{start:{line:247,column:10},end:{line:254,column:12}},77:{start:{line:248,column:12},end:{line:253,column:14}},78:{start:{line:259,column:6},end:{line:259,column:42}},79:{start:{line:260,column:6},end:{line:266,column:7}},80:{start:{line:261,column:8},end:{line:265,column:10}},81:{start:{line:269,column:6},end:{line:269,column:29}},82:{start:{line:270,column:6},end:{line:274,column:7}},83:{start:{line:271,column:8},end:{line:271,column:40}},84:{start:{line:272,column:8},end:{line:272,column:25}},85:{start:{line:273,column:8},end:{line:273,column:14}},86:{start:{line:275,column:6},end:{line:278,column:7}},87:{start:{line:276,column:8},end:{line:276,column:19}},88:{start:{line:277,column:8},end:{line:277,column:14}},89:{start:{line:279,column:29},end:{line:286,column:12}},90:{start:{line:280,column:8},end:{line:284,column:9}},91:{start:{line:281,column:10},end:{line:281,column:46}},92:{start:{line:283,column:10},end:{line:283,column:44}},93:{start:{line:285,column:8},end:{line:285,column:21}},94:{start:{line:287,column:6},end:{line:295,column:8}},95:{start:{line:288,column:8},end:{line:294,column:10}},96:{start:{line:289,column:27},end:{line:289,column:55}},97:{start:{line:290,column:10},end:{line:290,column:49}},98:{start:{line:291,column:10},end:{line:293,column:11}},99:{start:{line:292,column:12},end:{line:292,column:70}},100:{start:{line:296,column:6},end:{line:296,column:56}},101:{start:{line:299,column:16},end:{line:299,column:34}},102:{start:{line:300,column:6},end:{line:304,column:7}},103:{start:{line:301,column:8},end:{line:301,column:20}},104:{start:{line:303,column:8},end:{line:303,column:20}},105:{start:{line:305,column:6},end:{line:305,column:59}},106:{start:{line:306,column:6},end:{line:306,column:65}},107:{start:{line:306,column:35},end:{line:306,column:65}},108:{start:{line:307,column:6},end:{line:307,column:16}},109:{start:{line:310,column:23},end:{line:310,column:52}},110:{start:{line:311,column:16},end:{line:311,column:89}},111:{start:{line:312,column:6},end:{line:312,column:65}},112:{start:{line:312,column:35},end:{line:312,column:65}},113:{start:{line:313,column:6},end:{line:313,column:16}},114:{start:{line:316,column:6},end:{line:326,column:8}},115:{start:{line:317,column:8},end:{line:317,column:19}},116:{start:{line:318,column:8},end:{line:318,column:33}},117:{start:{line:319,column:8},end:{line:319,column:28}},118:{start:{line:323,column:8},end:{line:325,column:9}},119:{start:{line:324,column:10},end:{line:324,column:22}},120:{start:{line:329,column:6},end:{line:329,column:44}},121:{start:{line:332,column:6},end:{line:332,column:28}},122:{start:{line:333,column:6},end:{line:333,column:40}},123:{start:{line:336,column:6},end:{line:336,column:32}},124:{start:{line:337,column:6},end:{line:337,column:26}},125:{start:{line:340,column:6},end:{line:340,column:25}},126:{start:{line:341,column:6},end:{line:341,column:28}},127:{start:{line:342,column:6},end:{line:342,column:30}},128:{start:{line:343,column:6},end:{line:343,column:35}},129:{start:{line:344,column:6},end:{line:344,column:35}},130:{start:{line:345,column:6},end:{line:347,column:8}},131:{start:{line:346,column:8},end:{line:346,column:31}},132:{start:{line:350,column:6},end:{line:350,column:61}},133:{start:{line:351,column:6},end:{line:351,column:31}},134:{start:{line:354,column:6},end:{line:354,column:61}},135:{start:{line:355,column:6},end:{line:355,column:32}},136:{start:{line:358,column:6},end:{line:362,column:7}},137:{start:{line:366,column:17},end:{line:366,column:38}},138:{start:{line:367,column:22},end:{line:367,column:43}},139:{start:{line:368,column:6},end:{line:375,column:7}},140:{start:{line:370,column:8},end:{line:370,column:33}},141:{start:{line:372,column:10},end:{line:373,column:54}},142:{start:{line:374,column:8},end:{line:374,column:35}},143:{start:{line:376,column:6},end:{line:385,column:8}},144:{start:{line:386,column:6},end:{line:386,column:20}},145:{start:{line:387,column:6},end:{line:387,column:47}},146:{start:{line:389,column:6},end:{line:391,column:7}},147:{start:{line:390,column:8},end:{line:390,column:52}},148:{start:{line:392,column:6},end:{line:392,column:31}},149:{start:{line:395,column:6},end:{line:395,column:41}},150:{start:{line:399,column:25},end:{line:399,column:27}},151:{start:{line:400,column:6},end:{line:404,column:8}},152:{start:{line:401,column:8},end:{line:403,column:9}},153:{start:{line:402,column:10},end:{line:402,column:77}},154:{start:{line:406,column:21},end:{line:408,column:7}},155:{start:{line:407,column:20},end:{line:407,column:71}},156:{start:{line:409,column:6},end:{line:411,column:7}},157:{start:{line:410,column:8},end:{line:410,column:52}},158:{start:{line:412,column:6},end:{line:412,column:42}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:26,column:2},end:{line:26,column:3}},loc:{start:{line:26,column:9},end:{line:94,column:3}},line:26},1:{name:"(anonymous_1)",decl:{start:{line:44,column:18},end:{line:44,column:19}},loc:{start:{line:44,column:29},end:{line:44,column:50}},line:44},2:{name:"(anonymous_2)",decl:{start:{line:58,column:23},end:{line:58,column:24}},loc:{start:{line:58,column:29},end:{line:60,column:15}},line:58},3:{name:"(anonymous_3)",decl:{start:{line:65,column:23},end:{line:65,column:24}},loc:{start:{line:65,column:29},end:{line:67,column:15}},line:65},4:{name:"(anonymous_4)",decl:{start:{line:72,column:23},end:{line:72,column:24}},loc:{start:{line:72,column:29},end:{line:74,column:15}},line:72},5:{name:"(anonymous_5)",decl:{start:{line:96,column:18},end:{line:96,column:19}},loc:{start:{line:96,column:30},end:{line:104,column:5}},line:96},6:{name:"(anonymous_6)",decl:{start:{line:105,column:16},end:{line:105,column:17}},loc:{start:{line:105,column:28},end:{line:109,column:5}},line:105},7:{name:"(anonymous_7)",decl:{start:{line:106,column:38},end:{line:106,column:39}},loc:{start:{line:106,column:47},end:{line:108,column:7}},line:106},8:{name:"(anonymous_8)",decl:{start:{line:112,column:26},end:{line:112,column:27}},loc:{start:{line:112,column:38},end:{line:114,column:5}},line:112},9:{name:"(anonymous_9)",decl:{start:{line:118,column:14},end:{line:118,column:15}},loc:{start:{line:118,column:35},end:{line:122,column:5}},line:118},10:{name:"(anonymous_10)",decl:{start:{line:124,column:2},end:{line:124,column:3}},loc:{start:{line:124,column:12},end:{line:146,column:3}},line:124},11:{name:"(anonymous_11)",decl:{start:{line:126,column:40},end:{line:126,column:41}},loc:{start:{line:126,column:54},end:{line:144,column:5}},line:126},12:{name:"(anonymous_12)",decl:{start:{line:127,column:28},end:{line:127,column:29}},loc:{start:{line:127,column:40},end:{line:143,column:7}},line:127},13:{name:"(anonymous_13)",decl:{start:{line:131,column:56},end:{line:131,column:57}},loc:{start:{line:131,column:70},end:{line:141,column:11}},line:131},14:{name:"(anonymous_14)",decl:{start:{line:147,column:11},end:{line:147,column:12}},loc:{start:{line:147,column:23},end:{line:157,column:3}},line:147},15:{name:"(anonymous_15)",decl:{start:{line:158,column:13},end:{line:158,column:14}},loc:{start:{line:158,column:25},end:{line:163,column:3}},line:158},16:{name:"(anonymous_16)",decl:{start:{line:165,column:17},end:{line:165,column:18}},loc:{start:{line:165,column:35},end:{line:167,column:5}},line:165},17:{name:"(anonymous_17)",decl:{start:{line:168,column:16},end:{line:168,column:17}},loc:{start:{line:168,column:28},end:{line:170,column:5}},line:168},18:{name:"(anonymous_18)",decl:{start:{line:171,column:11},end:{line:171,column:12}},loc:{start:{line:171,column:23},end:{line:197,column:5}},line:171},19:{name:"(anonymous_19)",decl:{start:{line:198,column:10},end:{line:198,column:11}},loc:{start:{line:198,column:22},end:{line:201,column:5}},line:198},20:{name:"(anonymous_20)",decl:{start:{line:202,column:15},end:{line:202,column:16}},loc:{start:{line:202,column:27},end:{line:226,column:5}},line:202},21:{name:"(anonymous_21)",decl:{start:{line:205,column:20},end:{line:205,column:21}},loc:{start:{line:205,column:30},end:{line:205,column:49}},line:205},22:{name:"(anonymous_22)",decl:{start:{line:206,column:21},end:{line:206,column:22}},loc:{start:{line:206,column:27},end:{line:209,column:11}},line:206},23:{name:"(anonymous_23)",decl:{start:{line:210,column:24},end:{line:210,column:25}},loc:{start:{line:210,column:30},end:{line:216,column:11}},line:210},24:{name:"(anonymous_24)",decl:{start:{line:217,column:20},end:{line:217,column:21}},loc:{start:{line:217,column:26},end:{line:220,column:11}},line:217},25:{name:"(anonymous_25)",decl:{start:{line:222,column:14},end:{line:222,column:15}},loc:{start:{line:222,column:32},end:{line:225,column:9}},line:222},26:{name:"(anonymous_26)",decl:{start:{line:227,column:30},end:{line:227,column:31}},loc:{start:{line:227,column:49},end:{line:257,column:5}},line:227},27:{name:"(anonymous_27)",decl:{start:{line:230,column:40},end:{line:230,column:41}},loc:{start:{line:230,column:60},end:{line:237,column:7}},line:230},28:{name:"(anonymous_28)",decl:{start:{line:238,column:38},end:{line:238,column:39}},loc:{start:{line:238,column:48},end:{line:241,column:7}},line:238},29:{name:"(anonymous_29)",decl:{start:{line:243,column:8},end:{line:243,column:9}},loc:{start:{line:243,column:23},end:{line:255,column:9}},line:243},30:{name:"(anonymous_30)",decl:{start:{line:247,column:42},end:{line:247,column:43}},loc:{start:{line:247,column:52},end:{line:254,column:11}},line:247},31:{name:"(anonymous_31)",decl:{start:{line:258,column:35},end:{line:258,column:36}},loc:{start:{line:258,column:54},end:{line:267,column:5}},line:258},32:{name:"(anonymous_32)",decl:{start:{line:268,column:14},end:{line:268,column:15}},loc:{start:{line:268,column:32},end:{line:297,column:5}},line:268},33:{name:"(anonymous_33)",decl:{start:{line:279,column:43},end:{line:279,column:44}},loc:{start:{line:279,column:63},end:{line:286,column:7}},line:279},34:{name:"(anonymous_34)",decl:{start:{line:287,column:31},end:{line:287,column:32}},loc:{start:{line:287,column:43},end:{line:295,column:7}},line:287},35:{name:"(anonymous_35)",decl:{start:{line:288,column:28},end:{line:288,column:29}},loc:{start:{line:288,column:46},end:{line:294,column:9}},line:288},36:{name:"(anonymous_36)",decl:{start:{line:298,column:15},end:{line:298,column:16}},loc:{start:{line:298,column:33},end:{line:308,column:5}},line:298},37:{name:"(anonymous_37)",decl:{start:{line:309,column:21},end:{line:309,column:22}},loc:{start:{line:309,column:39},end:{line:314,column:5}},line:309},38:{name:"(anonymous_38)",decl:{start:{line:315,column:23},end:{line:315,column:24}},loc:{start:{line:315,column:55},end:{line:327,column:5}},line:315},39:{name:"(anonymous_39)",decl:{start:{line:316,column:40},end:{line:316,column:41}},loc:{start:{line:316,column:52},end:{line:326,column:7}},line:316},40:{name:"(anonymous_40)",decl:{start:{line:328,column:23},end:{line:328,column:24}},loc:{start:{line:328,column:39},end:{line:330,column:5}},line:328},41:{name:"(anonymous_41)",decl:{start:{line:331,column:12},end:{line:331,column:13}},loc:{start:{line:331,column:24},end:{line:334,column:5}},line:331},42:{name:"(anonymous_42)",decl:{start:{line:335,column:21},end:{line:335,column:22}},loc:{start:{line:335,column:33},end:{line:338,column:5}},line:335},43:{name:"(anonymous_43)",decl:{start:{line:339,column:13},end:{line:339,column:14}},loc:{start:{line:339,column:37},end:{line:348,column:5}},line:339},44:{name:"(anonymous_44)",decl:{start:{line:345,column:21},end:{line:345,column:22}},loc:{start:{line:345,column:27},end:{line:347,column:7}},line:345},45:{name:"(anonymous_45)",decl:{start:{line:349,column:23},end:{line:349,column:24}},loc:{start:{line:349,column:35},end:{line:352,column:5}},line:349},46:{name:"(anonymous_46)",decl:{start:{line:353,column:15},end:{line:353,column:16}},loc:{start:{line:353,column:27},end:{line:356,column:5}},line:353},47:{name:"(anonymous_47)",decl:{start:{line:357,column:20},end:{line:357,column:21}},loc:{start:{line:357,column:37},end:{line:363,column:5}},line:357},48:{name:"(anonymous_48)",decl:{start:{line:364,column:18},end:{line:364,column:19}},loc:{start:{line:364,column:35},end:{line:393,column:5}},line:364},49:{name:"(anonymous_49)",decl:{start:{line:394,column:24},end:{line:394,column:25}},loc:{start:{line:394,column:36},end:{line:396,column:5}},line:394},50:{name:"(anonymous_50)",decl:{start:{line:397,column:21},end:{line:397,column:22}},loc:{start:{line:397,column:41},end:{line:413,column:5}},line:397},51:{name:"(anonymous_51)",decl:{start:{line:400,column:31},end:{line:400,column:32}},loc:{start:{line:400,column:43},end:{line:404,column:7}},line:400},52:{name:"(anonymous_52)",decl:{start:{line:407,column:8},end:{line:407,column:9}},loc:{start:{line:407,column:20},end:{line:407,column:71}},line:407}},branchMap:{0:{loc:{start:{line:44,column:29},end:{line:44,column:50}},type:"binary-expr",locations:[{start:{line:44,column:29},end:{line:44,column:36}},{start:{line:44,column:40},end:{line:44,column:50}}],line:44},1:{loc:{start:{line:100,column:18},end:{line:102,column:16}},type:"cond-expr",locations:[{start:{line:101,column:12},end:{line:101,column:77}},{start:{line:102,column:12},end:{line:102,column:16}}],line:100},2:{loc:{start:{line:119,column:6},end:{line:121,column:7}},type:"if",locations:[{start:{line:119,column:6},end:{line:121,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:119},3:{loc:{start:{line:119,column:10},end:{line:119,column:43}},type:"binary-expr",locations:[{start:{line:119,column:10},end:{line:119,column:25}},{start:{line:119,column:29},end:{line:119,column:43}}],line:119},4:{loc:{start:{line:130,column:8},end:{line:142,column:9}},type:"if",locations:[{start:{line:130,column:8},end:{line:142,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:130},5:{loc:{start:{line:133,column:12},end:{line:136,column:13}},type:"if",locations:[{start:{line:133,column:12},end:{line:136,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:133},6:{loc:{start:{line:150,column:4},end:{line:156,column:5}},type:"if",locations:[{start:{line:150,column:4},end:{line:156,column:5}},{start:{line:153,column:11},end:{line:156,column:5}}],line:150},7:{loc:{start:{line:150,column:8},end:{line:150,column:53}},type:"binary-expr",locations:[{start:{line:150,column:8},end:{line:150,column:25}},{start:{line:150,column:29},end:{line:150,column:53}}],line:150},8:{loc:{start:{line:153,column:11},end:{line:156,column:5}},type:"if",locations:[{start:{line:153,column:11},end:{line:156,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:153},9:{loc:{start:{line:159,column:4},end:{line:161,column:5}},type:"if",locations:[{start:{line:159,column:4},end:{line:161,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:159},10:{loc:{start:{line:169,column:6},end:{line:169,column:53}},type:"if",locations:[{start:{line:169,column:6},end:{line:169,column:53}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:169},11:{loc:{start:{line:174,column:6},end:{line:178,column:7}},type:"if",locations:[{start:{line:174,column:6},end:{line:178,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:174},12:{loc:{start:{line:180,column:6},end:{line:184,column:7}},type:"if",locations:[{start:{line:180,column:6},end:{line:184,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:180},13:{loc:{start:{line:186,column:6},end:{line:194,column:7}},type:"if",locations:[{start:{line:186,column:6},end:{line:194,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:186},14:{loc:{start:{line:224,column:10},end:{line:224,column:59}},type:"if",locations:[{start:{line:224,column:10},end:{line:224,column:59}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:224},15:{loc:{start:{line:228,column:16},end:{line:228,column:42}},type:"binary-expr",locations:[{start:{line:228,column:16},end:{line:228,column:23}},{start:{line:228,column:27},end:{line:228,column:42}}],line:228},16:{loc:{start:{line:231,column:8},end:{line:235,column:9}},type:"if",locations:[{start:{line:231,column:8},end:{line:235,column:9}},{start:{line:233,column:15},end:{line:235,column:9}}],line:231},17:{loc:{start:{line:244,column:10},end:{line:246,column:11}},type:"if",locations:[{start:{line:244,column:10},end:{line:246,column:11}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:244},18:{loc:{start:{line:259,column:16},end:{line:259,column:42}},type:"binary-expr",locations:[{start:{line:259,column:16},end:{line:259,column:23}},{start:{line:259,column:27},end:{line:259,column:42}}],line:259},19:{loc:{start:{line:260,column:6},end:{line:266,column:7}},type:"if",locations:[{start:{line:260,column:6},end:{line:266,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:260},20:{loc:{start:{line:270,column:6},end:{line:274,column:7}},type:"if",locations:[{start:{line:270,column:6},end:{line:274,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:270},21:{loc:{start:{line:275,column:6},end:{line:278,column:7}},type:"if",locations:[{start:{line:275,column:6},end:{line:278,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:275},22:{loc:{start:{line:280,column:8},end:{line:284,column:9}},type:"if",locations:[{start:{line:280,column:8},end:{line:284,column:9}},{start:{line:282,column:15},end:{line:284,column:9}}],line:280},23:{loc:{start:{line:291,column:10},end:{line:293,column:11}},type:"if",locations:[{start:{line:291,column:10},end:{line:293,column:11}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:291},24:{loc:{start:{line:300,column:6},end:{line:304,column:7}},type:"if",locations:[{start:{line:300,column:6},end:{line:304,column:7}},{start:{line:302,column:13},end:{line:304,column:7}}],line:300},25:{loc:{start:{line:306,column:6},end:{line:306,column:65}},type:"if",locations:[{start:{line:306,column:6},end:{line:306,column:65}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:306},26:{loc:{start:{line:312,column:6},end:{line:312,column:65}},type:"if",locations:[{start:{line:312,column:6},end:{line:312,column:65}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:312},27:{loc:{start:{line:315,column:39},end:{line:315,column:53}},type:"default-arg",locations:[{start:{line:315,column:48},end:{line:315,column:53}}],line:315},28:{loc:{start:{line:323,column:8},end:{line:325,column:9}},type:"if",locations:[{start:{line:323,column:8},end:{line:325,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:323},29:{loc:{start:{line:368,column:6},end:{line:375,column:7}},type:"if",locations:[{start:{line:368,column:6},end:{line:375,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:368},30:{loc:{start:{line:389,column:6},end:{line:391,column:7}},type:"if",locations:[{start:{line:389,column:6},end:{line:391,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:389},31:{loc:{start:{line:401,column:8},end:{line:403,column:9}},type:"if",locations:[{start:{line:401,column:8},end:{line:403,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:401},32:{loc:{start:{line:409,column:6},end:{line:411,column:7}},type:"if",locations:[{start:{line:409,column:6},end:{line:411,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:409}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0,77:0,78:0,79:0,80:0,81:0,82:0,83:0,84:0,85:0,86:0,87:0,88:0,89:0,90:0,91:0,92:0,93:0,94:0,95:0,96:0,97:0,98:0,99:0,100:0,101:0,102:0,103:0,104:0,105:0,106:0,107:0,108:0,109:0,110:0,111:0,112:0,113:0,114:0,115:0,116:0,117:0,118:0,119:0,120:0,121:0,122:0,123:0,124:0,125:0,126:0,127:0,128:0,129:0,130:0,131:0,132:0,133:0,134:0,135:0,136:0,137:0,138:0,139:0,140:0,141:0,142:0,143:0,144:0,145:0,146:0,147:0,148:0,149:0,150:0,151:0,152:0,153:0,154:0,155:0,156:0,157:0,158:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0],26:[0,0],27:[0],28:[0,0],29:[0,0],30:[0,0],31:[0,0],32:[0,0]},inputSourceMap:{version:3,sources:["DataViewer.vue"],names:[],mappings:";AA2OA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA",file:"DataViewer.vue",sourceRoot:"src/tools/DataViewer",sourcesContent:['\x3c!--\n# Copyright 2022 Ball Aerospace & Technologies Corp.\n# All Rights Reserved.\n#\n# This program is free software; you can modify and/or redistribute it\n# under the terms of the GNU Affero General Public License\n# as published by the Free Software Foundation; version 3 with\n# attribution addendums as found in the LICENSE.txt\n#\n# This program is distributed in the hope that it will be useful,\n# but WITHOUT ANY WARRANTY; without even the implied warranty of\n# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n# GNU Affero General Public License for more details.\n\n# Modified by OpenC3, Inc.\n# All changes Copyright 2022, OpenC3, Inc.\n# All Rights Reserved\n#\n# This file may also be used under the terms of a commercial license\n# if purchased from OpenC3, Inc.\n--\x3e\n\n<template>\n <div>\n <top-bar :menus="menus" :title="title" />\n <v-card>\n <v-container>\n <v-row dense>\n <v-col>\n <v-text-field\n v-model="startDate"\n label="Start Date"\n type="date"\n :rules="[rules.required]"\n data-test="start-date"\n />\n </v-col>\n <v-col>\n <v-text-field\n v-model="startTime"\n label="Start Time"\n type="time"\n step="1"\n :rules="[rules.required]"\n data-test="start-time"\n />\n </v-col>\n <v-col>\n <v-text-field\n v-model="endDate"\n label="End Date"\n type="date"\n :rules="endTime ? [rules.required] : []"\n data-test="end-date"\n />\n </v-col>\n <v-col>\n <v-text-field\n v-model="endTime"\n label="End Time"\n type="time"\n step="1"\n :rules="endDate ? [rules.required] : []"\n data-test="end-time"\n />\n </v-col>\n <v-col cols="auto" class="pt-4">\n <v-btn\n v-if="running"\n color="primary"\n width="100"\n data-test="stop-button"\n @click="stop"\n >\n Stop\n </v-btn>\n <v-btn\n v-else\n :disabled="!canStart"\n color="primary"\n width="100"\n class="pulse-button"\n data-test="start-button"\n @click="start"\n >\n Start\n </v-btn>\n </v-col>\n </v-row>\n <div class="mb-3" v-show="warning || error || connectionFailure">\n <v-alert type="warning" v-model="warning" dismissible>\n {{ warningText }}\n </v-alert>\n <v-alert type="error" v-model="error" dismissible>\n {{ errorText }}\n </v-alert>\n <v-alert type="error" v-model="connectionFailure">\n OpenC3 backend connection failed.\n </v-alert>\n </div>\n </v-container>\n <v-tabs ref="tabs" v-model="curTab">\n <v-tab\n v-for="(tab, index) in config.tabs"\n :key="index"\n @contextmenu="(event) => tabMenu(event, index)"\n data-test="tab"\n >\n {{ tab.tabName }}\n </v-tab>\n <v-btn\n class="mt-2 ml-2"\n @click="addTab"\n :class="config.tabs.length === 0 ? \'pulse-button\' : \'\'"\n icon\n data-test="new-tab"\n >\n <v-icon>mdi-tab-plus</v-icon>\n </v-btn>\n </v-tabs>\n <v-tabs-items v-model="curTab">\n <v-tab-item v-for="(tab, index) in config.tabs" :key="tab.ref" eager>\n <keep-alive>\n <v-card flat>\n <v-divider />\n <v-card-title class="pa-3">\n <span v-text="tab.name" />\n <v-spacer />\n <v-btn\n @click="() => deleteComponent(index)"\n icon\n data-test="delete-component"\n >\n <v-icon color="red">mdi-delete</v-icon>\n </v-btn>\n </v-card-title>\n <component\n v-on="$listeners"\n :is="tab.type"\n :name="tab.component"\n :ref="tab.ref"\n :config="tab.config"\n :packets="tab.packets"\n @config="(config) => (tab.config = config)"\n />\n <v-card-text v-if="receivedPackets.length === 0">\n No data! Make sure to hit the START button!\n </v-card-text>\n </v-card></keep-alive\n >\n </v-tab-item>\n </v-tabs-items>\n <v-card v-if="!config.tabs.length">\n <v-card-title>You\'re not viewing any packets</v-card-title>\n <v-card-text>Click the new tab icon to start.</v-card-text>\n </v-card>\n </v-card>\n \x3c!-- Dialogs for opening and saving configs --\x3e\n <open-config-dialog\n v-if="openConfig"\n v-model="openConfig"\n :configKey="configKey"\n @success="openConfiguration"\n />\n <save-config-dialog\n v-if="saveConfig"\n v-model="saveConfig"\n :configKey="configKey"\n @success="saveConfiguration"\n />\n \x3c!-- Dialog for renaming a new tab --\x3e\n <v-dialog v-model="tabNameDialog" width="600">\n <v-card>\n <v-system-bar>\n <v-spacer />\n <span> DataViewer: Rename Tab</span>\n <v-spacer />\n </v-system-bar>\n <v-card-text>\n <v-text-field\n v-model="newTabName"\n label="Tab name"\n data-test="rename-tab-input"\n />\n </v-card-text>\n <v-card-actions>\n <v-spacer />\n <v-btn\n outlined\n class="mx-2"\n data-test="cancel-rename"\n @click="cancelTabRename"\n >\n Cancel\n </v-btn>\n <v-btn\n color="primary"\n class="mx-2"\n data-test="rename"\n :disabled="!newTabName"\n @click="renameTab"\n >\n Rename\n </v-btn>\n </v-card-actions>\n </v-card>\n </v-dialog>\n \x3c!-- Menu for right clicking on a tab --\x3e\n <v-menu\n v-model="showTabMenu"\n :position-x="tabMenuX"\n :position-y="tabMenuY"\n absolute\n offset-y\n >\n <v-list>\n <v-list-item data-test="context-menu-rename">\n <v-list-item-title style="cursor: pointer" @click="openTabNameDialog">\n Rename\n </v-list-item-title>\n </v-list-item>\n </v-list>\n </v-menu>\n \x3c!-- Dialog for adding a new component to a tab --\x3e\n <add-component-dialog\n :components="components"\n v-if="showAddComponentDialog"\n v-model="showAddComponentDialog"\n @add="addComponent"\n @cancel="cancelAddComponent"\n />\n </div>\n</template>\n\n<script>\nimport { format } from \'date-fns\'\nimport Api from \'@openc3/tool-common/src/services/api\'\nimport Config from \'@openc3/tool-common/src/components/config/Config\'\nimport OpenConfigDialog from \'@openc3/tool-common/src/components/config/OpenConfigDialog\'\nimport SaveConfigDialog from \'@openc3/tool-common/src/components/config/SaveConfigDialog\'\nimport Cable from \'@openc3/tool-common/src/services/cable.js\'\nimport TopBar from \'@openc3/tool-common/src/components/TopBar\'\n\nimport AddComponentDialog from \'@/tools/DataViewer/AddComponentDialog\'\n// DynamicComponent is how we load custom user components\nimport DynamicComponent from \'@/tools/DataViewer/DynamicComponent\'\n// Import the built-in DataViewer components\nimport DumpComponent from \'@/tools/DataViewer/DumpComponent\'\n\nexport default {\n components: {\n AddComponentDialog,\n OpenConfigDialog,\n SaveConfigDialog,\n DynamicComponent,\n DumpComponent,\n TopBar,\n },\n mixins: [Config],\n data() {\n return {\n title: \'COSMOS Data Viewer\',\n configKey: \'data_viewer\',\n // Initialize with all built-in components\n components: [{ label: \'COSMOS Raw/Decom\', value: \'DumpComponent\' }],\n counter: 0,\n componentType: null,\n componentName: null,\n openConfig: false,\n saveConfig: false,\n cable: new Cable(),\n subscription: null,\n startDate: format(new Date(), \'yyyy-MM-dd\'),\n startTime: format(new Date(), \'HH:mm:ss\'),\n endDate: \'\',\n endTime: \'\',\n rules: {\n required: (value) => !!value || \'Required\',\n },\n autoStart: false,\n canStart: false,\n running: false,\n curTab: null,\n receivedPackets: {},\n menus: [\n {\n label: \'File\',\n items: [\n {\n label: \'Open Configuration\',\n icon: \'mdi-folder-open\',\n command: () => {\n this.openConfig = true\n },\n },\n {\n label: \'Save Configuration\',\n icon: \'mdi-content-save\',\n command: () => {\n this.saveConfig = true\n },\n },\n {\n label: \'Reset Configuration\',\n icon: \'mdi-monitor-shimmer\',\n command: () => {\n this.resetConfigBase()\n },\n },\n ],\n },\n ],\n warning: false,\n warningText: \'\',\n error: false,\n errorText: \'\',\n connectionFailure: false,\n config: {\n tabs: [],\n },\n tabNameDialog: false,\n newTabName: \'\',\n showTabMenu: false,\n tabMenuX: 0,\n tabMenuY: 0,\n showAddComponentDialog: false,\n }\n },\n computed: {\n startEndTime: function () {\n return {\n start_time:\n new Date(this.startDate + \' \' + this.startTime).getTime() * 1_000_000,\n end_time: this.endDate\n ? new Date(this.endDate + \' \' + this.endTime).getTime() * 1_000_000\n : null,\n }\n },\n allPackets: function () {\n return this.config.tabs.flatMap((tab) => {\n return tab.packets\n })\n },\n },\n watch: {\n \'config.tabs.length\': function () {\n this.resizeTabs()\n },\n // canStart is set by the subscription when it connects.\n // We set autoStart to true during mounted() when loading from\n // a route or a previous saved configuration.\n canStart: function (newVal, _) {\n if (newVal === true && this.autoStart) {\n this.start()\n }\n },\n },\n created() {\n // Determine if there are any user added widgets\n Api.get(\'/openc3-api/widgets\').then((response) => {\n response.data.forEach((widget) => {\n // Only list the ones following the naming convention DataviewerxxxxxWidget\n const found = widget.match(/DATAVIEWER([A-Z]+)/)\n if (found) {\n Api.get(`/openc3-api/widgets/${widget}`).then((response) => {\n let label = response.data.label\n if (label === null) {\n label = response.data.name.slice(10)\n label = label.charAt(0) + label.slice(1).toLowerCase()\n }\n this.components.push({\n label: label,\n value: found[0],\n })\n })\n }\n })\n })\n this.subscribe()\n },\n mounted: function () {\n const previousConfig = localStorage[`lastconfig__${this.configKey}`]\n // Called like /tools/dataviewer?config=config\n if (this.$route.query && this.$route.query.config) {\n this.autoStart = true\n this.openConfiguration(this.$route.query.config, true) // routed\n } else if (previousConfig) {\n this.autoStart = true\n this.openConfiguration(previousConfig)\n }\n },\n destroyed: function () {\n if (this.subscription) {\n this.subscription.unsubscribe()\n }\n this.cable.disconnect()\n },\n methods: {\n packetTitle: function (packet) {\n return `${packet.targetName} ${packet.packetName} [ ${packet.mode} ]`\n },\n resizeTabs: function () {\n if (this.$refs.tabs) this.$refs.tabs.onResize()\n },\n start: function () {\n this.autoStart = false\n // Check for a future start time\n if (new Date(this.startDate + \' \' + this.startTime) > Date.now()) {\n this.warningText = \'Start date/time is in the future!\'\n this.warning = true\n return\n }\n // Check for an empty time period\n if (this.startEndTime.start_time === this.startEndTime.end_time) {\n this.warningText = \'Start date/time is equal to end date/time!\'\n this.warning = true\n return\n }\n // Check for a future End Time\n if (new Date(this.endDate + \' \' + this.endTime) > Date.now()) {\n this.warningText =\n \'Note: End date/time is greater than current date/time. Data will continue to stream in real-time until \' +\n this.endDate +\n \' \' +\n this.endTime +\n \' is reached.\'\n this.warning = true\n }\n this.running = true\n this.addPacketsToSubscription()\n },\n stop: function () {\n this.running = false\n this.removePacketsFromSubscription()\n },\n subscribe: function () {\n this.cable\n .createSubscription(\'StreamingChannel\', window.openc3Scope, {\n received: (data) => this.received(data),\n connected: () => {\n this.canStart = true\n this.connectionFailure = false\n },\n disconnected: () => {\n this.stop()\n this.canStart = false\n this.warningText = \'OpenC3 backend connection disconnected.\'\n this.warning = true\n this.connectionFailure = true\n },\n rejected: () => {\n this.warningText = \'OpenC3 backend connection rejected.\'\n this.warning = true\n },\n })\n .then((subscription) => {\n this.subscription = subscription\n if (this.running) this.addPacketsToSubscription()\n })\n },\n addPacketsToSubscription: function (packets) {\n packets = packets || this.allPackets\n // Group by mode\n const modeGroups = packets.reduce((groups, packet) => {\n if (groups[packet.mode]) {\n groups[packet.mode].push(packet)\n } else {\n groups[packet.mode] = [packet]\n }\n return groups\n }, {})\n Object.keys(modeGroups).forEach((mode) => {\n // This eliminates duplicates by converted to Set and back to Array\n modeGroups[mode] = [...new Set(modeGroups[mode])]\n })\n OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then(\n (refreshed) => {\n if (refreshed) {\n OpenC3Auth.setTokens()\n }\n Object.keys(modeGroups).forEach((mode) => {\n this.subscription.perform(\'add\', {\n scope: window.openc3Scope,\n token: localStorage.openc3Token,\n packets: modeGroups[mode].map(this.subscriptionKey),\n ...this.startEndTime,\n })\n })\n },\n )\n },\n removePacketsFromSubscription: function (packets) {\n packets = packets || this.allPackets\n if (packets.length > 0) {\n this.subscription.perform(\'remove\', {\n scope: window.openc3Scope,\n token: localStorage.openc3Token,\n packets: packets.map(this.subscriptionKey),\n })\n }\n },\n received: function (parsed) {\n this.cable.recordPing()\n if (parsed[\'error\']) {\n this.errorText = parsed[\'error\']\n this.error = true\n return\n }\n if (!parsed.length) {\n this.stop()\n return\n }\n const groupedPackets = parsed.reduce((groups, packet) => {\n if (groups[packet.__packet]) {\n groups[packet.__packet].push(packet)\n } else {\n groups[packet.__packet] = [packet]\n }\n return groups\n }, {})\n this.config.tabs.forEach((tab, i) => {\n tab.packets.forEach((packetConfig) => {\n let packetName = this.packetKey(packetConfig)\n this.receivedPackets[packetName] = true\n if (groupedPackets[packetName]) {\n this.$refs[tab.ref][0].receive(groupedPackets[packetName])\n }\n })\n })\n this.receivedPackets = { ...this.receivedPackets }\n },\n packetKey: function (packet) {\n let key = packet.mode + \'__\'\n if (packet.cmdOrTlm === \'TLM\') {\n key += \'TLM\'\n } else {\n key += \'CMD\'\n }\n key += `__${packet.targetName}__${packet.packetName}`\n if (packet.mode === \'DECOM\') key += `__${packet.valueType}`\n return key\n },\n subscriptionKey: function (packet) {\n const cmdOrTlm = packet.cmdOrTlm.toUpperCase()\n let key = `${packet.mode}__${cmdOrTlm}__${packet.targetName}__${packet.packetName}`\n if (packet.mode === \'DECOM\') key += `__${packet.valueType}`\n return key\n },\n openConfiguration: function (name, routed = false) {\n this.openConfigBase(name, routed, (config) => {\n this.stop()\n this.receivedPackets = {}\n this.config = config\n // Only call start() if autoStart is false like during a reload.\n // Otherwise we might call start before the subscription is valid.\n // See watch on canStart for more info.\n if (this.autoStart === false) {\n this.start()\n }\n })\n },\n saveConfiguration: function (name) {\n this.saveConfigBase(name, this.config)\n },\n addTab: function () {\n this.cancelTabRename()\n this.showAddComponentDialog = true\n },\n cancelTabRename: function () {\n this.tabNameDialog = false\n this.newTabName = \'\'\n },\n tabMenu: function (event, index) {\n this.curTab = index\n event.preventDefault()\n this.showTabMenu = false\n this.tabMenuX = event.clientX\n this.tabMenuY = event.clientY\n this.$nextTick(() => {\n this.showTabMenu = true\n })\n },\n openTabNameDialog: function () {\n this.newTabName = this.config.tabs[this.curTab].tabName\n this.tabNameDialog = true\n },\n renameTab: function () {\n this.config.tabs[this.curTab].tabName = this.newTabName\n this.tabNameDialog = false\n },\n packetSelected: function (event) {\n this.newPacket = {\n target: event.targetName,\n packet: event.packetName,\n cmdOrTlm: this.newPacketCmdOrTlm,\n }\n },\n addComponent: function (event) {\n // Built-in components are just themselves\n let type = event.component.value\n let component = event.component.value\n if (event.component.value.includes(\'DATAVIEWER\')) {\n // Dynamic widgets use the DynamicComponent\n type = \'DynamicComponent\'\n let name =\n event.component.value.charAt(0).toUpperCase() +\n event.component.value.slice(1).toLowerCase()\n component = `${name}Widget`\n }\n this.config.tabs.push({\n name: event.component.label,\n // Most tabs only have 1 packet so it\'s a good way to name them\n tabName: this.packetTitle(event.packets[0]),\n packets: [...event.packets], // Make a copy\n type: type,\n component: component,\n config: {}, // Set an empty config object\n ref: `component${this.counter}`,\n })\n this.counter++\n this.curTab = this.config.tabs.length - 1\n\n if (this.running) {\n this.addPacketsToSubscription(event.packets)\n }\n this.cancelAddComponent()\n },\n cancelAddComponent: function () {\n this.showAddComponentDialog = false\n },\n deleteComponent: function (tabIndex) {\n // Get the list of packets the other tabs are using\n let packetsInUse = []\n this.config.tabs.forEach((tab, i) => {\n if (i !== tabIndex) {\n packetsInUse = packetsInUse.concat(tab.packets.map(this.packetKey))\n }\n })\n // Filter out any packets that are in use\n let filtered = this.config.tabs[tabIndex].packets.filter(\n (packet) => packetsInUse.indexOf(this.packetKey(packet)) === -1,\n )\n if (filtered.length > 0) {\n this.removePacketsFromSubscription(filtered)\n }\n this.config.tabs.splice(tabIndex, 1)\n },\n },\n}\n<\/script>\n\n<style scoped>\n/* Add some juice to the START button to indicate it needs to be pressed */\n.pulse-button {\n animation: pulse 2s infinite;\n}\n@keyframes pulse {\n 0% {\n -webkit-box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);\n }\n 70% {\n -webkit-box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);\n }\n 100% {\n -webkit-box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);\n }\n}\n\n.text-component-missing-name {\n font-family: \'Courier New\', Courier, monospace;\n}\n\n.v-tabs-items {\n overflow: visible;\n}\n</style>\n']},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"7c4898469910ee702797fcbe869d9eb9cdb0d264"},i=t[l]||(t[l]={});i[e]&&i[e].hash===n||(i[e]=o);var a=i[e];return Ne=function(){return a},a}Ne();const De={components:{AddComponentDialog:ne,OpenConfigDialog:N,SaveConfigDialog:I,DynamicComponent:ue,DumpComponent:xe,TopBar:K},mixins:[g],data(){return Ne().f[0]++,Ne().s[0]++,{title:"COSMOS Data Viewer",configKey:"data_viewer",components:[{label:"COSMOS Raw/Decom",value:"DumpComponent"}],counter:0,componentType:null,componentName:null,openConfig:!1,saveConfig:!1,cable:new M,subscription:null,startDate:(0,a.Z)(new Date,"yyyy-MM-dd"),startTime:(0,a.Z)(new Date,"HH:mm:ss"),endDate:"",endTime:"",rules:{required:e=>(Ne().f[1]++,Ne().s[1]++,Ne().b[0][0]++,!!e||(Ne().b[0][1]++,"Required"))},autoStart:!1,canStart:!1,running:!1,curTab:null,receivedPackets:{},menus:[{label:"File",items:[{label:"Open Configuration",icon:"mdi-folder-open",command:()=>{Ne().f[2]++,Ne().s[2]++,this.openConfig=!0}},{label:"Save Configuration",icon:"mdi-content-save",command:()=>{Ne().f[3]++,Ne().s[3]++,this.saveConfig=!0}},{label:"Reset Configuration",icon:"mdi-monitor-shimmer",command:()=>{Ne().f[4]++,Ne().s[4]++,this.resetConfigBase()}}]}],warning:!1,warningText:"",error:!1,errorText:"",connectionFailure:!1,config:{tabs:[]},tabNameDialog:!1,newTabName:"",showTabMenu:!1,tabMenuX:0,tabMenuY:0,showAddComponentDialog:!1}},computed:{startEndTime:function(){return Ne().f[5]++,Ne().s[5]++,{start_time:1e6*new Date(this.startDate+" "+this.startTime).getTime(),end_time:this.endDate?(Ne().b[1][0]++,1e6*new Date(this.endDate+" "+this.endTime).getTime()):(Ne().b[1][1]++,null)}},allPackets:function(){return Ne().f[6]++,Ne().s[6]++,this.config.tabs.flatMap((e=>(Ne().f[7]++,Ne().s[7]++,e.packets)))}},watch:{"config.tabs.length":function(){Ne().f[8]++,Ne().s[8]++,this.resizeTabs()},canStart:function(e,n){Ne().f[9]++,Ne().s[9]++,Ne().b[3][0]++,!0===e&&(Ne().b[3][1]++,this.autoStart)?(Ne().b[2][0]++,Ne().s[10]++,this.start()):Ne().b[2][1]++}},created(){Ne().f[10]++,Ne().s[11]++,f.get("/openc3-api/widgets").then((e=>{Ne().f[11]++,Ne().s[12]++,e.data.forEach((e=>{Ne().f[12]++;const n=(Ne().s[13]++,e.match(/DATAVIEWER([A-Z]+)/));Ne().s[14]++,n?(Ne().b[4][0]++,Ne().s[15]++,f.get(`/openc3-api/widgets/${e}`).then((e=>{Ne().f[13]++;let t=(Ne().s[16]++,e.data.label);Ne().s[17]++,null===t?(Ne().b[5][0]++,Ne().s[18]++,t=e.data.name.slice(10),Ne().s[19]++,t=t.charAt(0)+t.slice(1).toLowerCase()):Ne().b[5][1]++,Ne().s[20]++,this.components.push({label:t,value:n[0]})}))):Ne().b[4][1]++}))})),Ne().s[21]++,this.subscribe()},mounted:function(){Ne().f[14]++;const e=(Ne().s[22]++,localStorage[`lastconfig__${this.configKey}`]);Ne().s[23]++,Ne().b[7][0]++,this.$route.query&&(Ne().b[7][1]++,this.$route.query.config)?(Ne().b[6][0]++,Ne().s[24]++,this.autoStart=!0,Ne().s[25]++,this.openConfiguration(this.$route.query.config,!0)):(Ne().b[6][1]++,Ne().s[26]++,e?(Ne().b[8][0]++,Ne().s[27]++,this.autoStart=!0,Ne().s[28]++,this.openConfiguration(e)):Ne().b[8][1]++)},destroyed:function(){Ne().f[15]++,Ne().s[29]++,this.subscription?(Ne().b[9][0]++,Ne().s[30]++,this.subscription.unsubscribe()):Ne().b[9][1]++,Ne().s[31]++,this.cable.disconnect()},methods:{packetTitle:function(e){return Ne().f[16]++,Ne().s[32]++,`${e.targetName} ${e.packetName} [ ${e.mode} ]`},resizeTabs:function(){Ne().f[17]++,Ne().s[33]++,this.$refs.tabs?(Ne().b[10][0]++,Ne().s[34]++,this.$refs.tabs.onResize()):Ne().b[10][1]++},start:function(){return Ne().f[18]++,Ne().s[35]++,this.autoStart=!1,Ne().s[36]++,new Date(this.startDate+" "+this.startTime)>Date.now()?(Ne().b[11][0]++,Ne().s[37]++,this.warningText="Start date/time is in the future!",Ne().s[38]++,this.warning=!0,void Ne().s[39]++):(Ne().b[11][1]++,Ne().s[40]++,this.startEndTime.start_time===this.startEndTime.end_time?(Ne().b[12][0]++,Ne().s[41]++,this.warningText="Start date/time is equal to end date/time!",Ne().s[42]++,this.warning=!0,void Ne().s[43]++):(Ne().b[12][1]++,Ne().s[44]++,new Date(this.endDate+" "+this.endTime)>Date.now()?(Ne().b[13][0]++,Ne().s[45]++,this.warningText="Note: End date/time is greater than current date/time. Data will continue to stream in real-time until "+this.endDate+" "+this.endTime+" is reached.",Ne().s[46]++,this.warning=!0):Ne().b[13][1]++,Ne().s[47]++,this.running=!0,Ne().s[48]++,void this.addPacketsToSubscription()))},stop:function(){Ne().f[19]++,Ne().s[49]++,this.running=!1,Ne().s[50]++,this.removePacketsFromSubscription()},subscribe:function(){Ne().f[20]++,Ne().s[51]++,this.cable.createSubscription("StreamingChannel",window.openc3Scope,{received:e=>(Ne().f[21]++,Ne().s[52]++,this.received(e)),connected:()=>{Ne().f[22]++,Ne().s[53]++,this.canStart=!0,Ne().s[54]++,this.connectionFailure=!1},disconnected:()=>{Ne().f[23]++,Ne().s[55]++,this.stop(),Ne().s[56]++,this.canStart=!1,Ne().s[57]++,this.warningText="OpenC3 backend connection disconnected.",Ne().s[58]++,this.warning=!0,Ne().s[59]++,this.connectionFailure=!0},rejected:()=>{Ne().f[24]++,Ne().s[60]++,this.warningText="OpenC3 backend connection rejected.",Ne().s[61]++,this.warning=!0}}).then((e=>{Ne().f[25]++,Ne().s[62]++,this.subscription=e,Ne().s[63]++,this.running?(Ne().b[14][0]++,Ne().s[64]++,this.addPacketsToSubscription()):Ne().b[14][1]++}))},addPacketsToSubscription:function(e){Ne().f[26]++,Ne().s[65]++,Ne().b[15][0]++,e=e||(Ne().b[15][1]++,this.allPackets);const n=(Ne().s[66]++,e.reduce(((e,n)=>(Ne().f[27]++,Ne().s[67]++,e[n.mode]?(Ne().b[16][0]++,Ne().s[68]++,e[n.mode].push(n)):(Ne().b[16][1]++,Ne().s[69]++,e[n.mode]=[n]),Ne().s[70]++,e)),{}));Ne().s[71]++,Object.keys(n).forEach((e=>{Ne().f[28]++,Ne().s[72]++,n[e]=[...new Set(n[e])]})),Ne().s[73]++,OpenC3Auth.updateToken(OpenC3Auth.defaultMinValidity).then((e=>{Ne().f[29]++,Ne().s[74]++,e?(Ne().b[17][0]++,Ne().s[75]++,OpenC3Auth.setTokens()):Ne().b[17][1]++,Ne().s[76]++,Object.keys(n).forEach((e=>{Ne().f[30]++,Ne().s[77]++,this.subscription.perform("add",{scope:window.openc3Scope,token:localStorage.openc3Token,packets:n[e].map(this.subscriptionKey),...this.startEndTime})}))}))},removePacketsFromSubscription:function(e){Ne().f[31]++,Ne().s[78]++,Ne().b[18][0]++,e=e||(Ne().b[18][1]++,this.allPackets),Ne().s[79]++,e.length>0?(Ne().b[19][0]++,Ne().s[80]++,this.subscription.perform("remove",{scope:window.openc3Scope,token:localStorage.openc3Token,packets:e.map(this.subscriptionKey)})):Ne().b[19][1]++},received:function(e){if(Ne().f[32]++,Ne().s[81]++,this.cable.recordPing(),Ne().s[82]++,e["error"])return Ne().b[20][0]++,Ne().s[83]++,this.errorText=e["error"],Ne().s[84]++,this.error=!0,void Ne().s[85]++;if(Ne().b[20][1]++,Ne().s[86]++,!e.length)return Ne().b[21][0]++,Ne().s[87]++,this.stop(),void Ne().s[88]++;Ne().b[21][1]++;const n=(Ne().s[89]++,e.reduce(((e,n)=>(Ne().f[33]++,Ne().s[90]++,e[n.__packet]?(Ne().b[22][0]++,Ne().s[91]++,e[n.__packet].push(n)):(Ne().b[22][1]++,Ne().s[92]++,e[n.__packet]=[n]),Ne().s[93]++,e)),{}));Ne().s[94]++,this.config.tabs.forEach(((e,t)=>{Ne().f[34]++,Ne().s[95]++,e.packets.forEach((t=>{Ne().f[35]++;let l=(Ne().s[96]++,this.packetKey(t));Ne().s[97]++,this.receivedPackets[l]=!0,Ne().s[98]++,n[l]?(Ne().b[23][0]++,Ne().s[99]++,this.$refs[e.ref][0].receive(n[l])):Ne().b[23][1]++}))})),Ne().s[100]++,this.receivedPackets={...this.receivedPackets}},packetKey:function(e){Ne().f[36]++;let n=(Ne().s[101]++,e.mode+"__");return Ne().s[102]++,"TLM"===e.cmdOrTlm?(Ne().b[24][0]++,Ne().s[103]++,n+="TLM"):(Ne().b[24][1]++,Ne().s[104]++,n+="CMD"),Ne().s[105]++,n+=`__${e.targetName}__${e.packetName}`,Ne().s[106]++,"DECOM"===e.mode?(Ne().b[25][0]++,Ne().s[107]++,n+=`__${e.valueType}`):Ne().b[25][1]++,Ne().s[108]++,n},subscriptionKey:function(e){Ne().f[37]++;const n=(Ne().s[109]++,e.cmdOrTlm.toUpperCase());let t=(Ne().s[110]++,`${e.mode}__${n}__${e.targetName}__${e.packetName}`);return Ne().s[111]++,"DECOM"===e.mode?(Ne().b[26][0]++,Ne().s[112]++,t+=`__${e.valueType}`):Ne().b[26][1]++,Ne().s[113]++,t},openConfiguration:function(e,n=(Ne().b[27][0]++,!1)){Ne().f[38]++,Ne().s[114]++,this.openConfigBase(e,n,(e=>{Ne().f[39]++,Ne().s[115]++,this.stop(),Ne().s[116]++,this.receivedPackets={},Ne().s[117]++,this.config=e,Ne().s[118]++,!1===this.autoStart?(Ne().b[28][0]++,Ne().s[119]++,this.start()):Ne().b[28][1]++}))},saveConfiguration:function(e){Ne().f[40]++,Ne().s[120]++,this.saveConfigBase(e,this.config)},addTab:function(){Ne().f[41]++,Ne().s[121]++,this.cancelTabRename(),Ne().s[122]++,this.showAddComponentDialog=!0},cancelTabRename:function(){Ne().f[42]++,Ne().s[123]++,this.tabNameDialog=!1,Ne().s[124]++,this.newTabName=""},tabMenu:function(e,n){Ne().f[43]++,Ne().s[125]++,this.curTab=n,Ne().s[126]++,e.preventDefault(),Ne().s[127]++,this.showTabMenu=!1,Ne().s[128]++,this.tabMenuX=e.clientX,Ne().s[129]++,this.tabMenuY=e.clientY,Ne().s[130]++,this.$nextTick((()=>{Ne().f[44]++,Ne().s[131]++,this.showTabMenu=!0}))},openTabNameDialog:function(){Ne().f[45]++,Ne().s[132]++,this.newTabName=this.config.tabs[this.curTab].tabName,Ne().s[133]++,this.tabNameDialog=!0},renameTab:function(){Ne().f[46]++,Ne().s[134]++,this.config.tabs[this.curTab].tabName=this.newTabName,Ne().s[135]++,this.tabNameDialog=!1},packetSelected:function(e){Ne().f[47]++,Ne().s[136]++,this.newPacket={target:e.targetName,packet:e.packetName,cmdOrTlm:this.newPacketCmdOrTlm}},addComponent:function(e){Ne().f[48]++;let n=(Ne().s[137]++,e.component.value),t=(Ne().s[138]++,e.component.value);if(Ne().s[139]++,e.component.value.includes("DATAVIEWER")){Ne().b[29][0]++,Ne().s[140]++,n="DynamicComponent";let l=(Ne().s[141]++,e.component.value.charAt(0).toUpperCase()+e.component.value.slice(1).toLowerCase());Ne().s[142]++,t=`${l}Widget`}else Ne().b[29][1]++;Ne().s[143]++,this.config.tabs.push({name:e.component.label,tabName:this.packetTitle(e.packets[0]),packets:[...e.packets],type:n,component:t,config:{},ref:`component${this.counter}`}),Ne().s[144]++,this.counter++,Ne().s[145]++,this.curTab=this.config.tabs.length-1,Ne().s[146]++,this.running?(Ne().b[30][0]++,Ne().s[147]++,this.addPacketsToSubscription(e.packets)):Ne().b[30][1]++,Ne().s[148]++,this.cancelAddComponent()},cancelAddComponent:function(){Ne().f[49]++,Ne().s[149]++,this.showAddComponentDialog=!1},deleteComponent:function(e){Ne().f[50]++;let n=(Ne().s[150]++,[]);Ne().s[151]++,this.config.tabs.forEach(((t,l)=>{Ne().f[51]++,Ne().s[152]++,l!==e?(Ne().b[31][0]++,Ne().s[153]++,n=n.concat(t.packets.map(this.packetKey))):Ne().b[31][1]++}));let t=(Ne().s[154]++,this.config.tabs[e].packets.filter((e=>(Ne().f[52]++,Ne().s[155]++,-1===n.indexOf(this.packetKey(e))))));Ne().s[156]++,t.length>0?(Ne().b[32][0]++,Ne().s[157]++,this.removePacketsFromSubscription(t)):Ne().b[32][1]++,Ne().s[158]++,this.config.tabs.splice(e,1)}}},Se=De;t(7904);var Pe=(0,T.Z)(Se,o,i,!1,null,"2428cfbe",null);const Oe=Pe.exports},7165:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>c});var l=t(9601),o=t.n(l),i=t(2609),a=t.n(i),s=a()(o());s.push([e.id,".pulse-button[data-v-2428cfbe]{animation:pulse-2428cfbe 2s infinite}@keyframes pulse-2428cfbe{0%{-webkit-box-shadow:0 0 0 0 hsla(0,0%,100%,.4)}70%{-webkit-box-shadow:0 0 0 10px hsla(0,0%,100%,0)}to{-webkit-box-shadow:0 0 0 0 hsla(0,0%,100%,0)}}.text-component-missing-name[data-v-2428cfbe]{font-family:Courier New,Courier,monospace}.v-tabs-items[data-v-2428cfbe]{overflow:visible}",""]);const c=s},2409:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>c});var l=t(9601),o=t.n(l),i=t(2609),a=t.n(i),s=a()(o());s.push([e.id,".row+.row{margin-top:0}",""]);const c=s},7219:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>c});var l=t(9601),o=t.n(l),i=t(2609),a=t.n(i),s=a()(o());s.push([e.id,".v-list[data-v-11569d60] .v-label{margin-left:5px}.v-list-item__icon[data-v-11569d60]{margin-right:15px!important}.v-list-item__title[data-v-11569d60]{color:#fff}",""]);const c=s},4758:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>c});var l=t(9601),o=t.n(l),i=t(2609),a=t.n(i),s=a()(o());s.push([e.id,".text-area-container[data-v-625a8260]{position:relative;height:60vh}.text-area-container .v-textarea[data-v-625a8260]{font-family:Courier New,Courier,monospace}.text-area-container .floating-buttons[data-v-625a8260]{position:absolute;top:12px;right:24px}.text-area-container[data-v-625a8260] textarea{height:60vh}.pulse[data-v-625a8260]{animation:pulse-625a8260 2s infinite}@keyframes pulse-625a8260{0%{opacity:1}50%{opacity:.5}}",""]);const c=s},7904:(e,n,t)=>{var l=t(7165);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[e.id,l,""]]),l.locals&&(e.exports=l.locals);var o=t(3514).Z;o("405e5612",l,!0,{sourceMap:!1,shadowMode:!1})},985:(e,n,t)=>{var l=t(2409);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[e.id,l,""]]),l.locals&&(e.exports=l.locals);var o=t(3514).Z;o("a3c4944a",l,!0,{sourceMap:!1,shadowMode:!1})},2416:(e,n,t)=>{var l=t(7219);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[e.id,l,""]]),l.locals&&(e.exports=l.locals);var o=t(3514).Z;o("325f248f",l,!0,{sourceMap:!1,shadowMode:!1})},5442:(e,n,t)=>{var l=t(4758);l.__esModule&&(l=l.default),"string"===typeof l&&(l=[[e.id,l,""]]),l.locals&&(e.exports=l.locals);var o=t(3514).Z;o("79aa23fc",l,!0,{sourceMap:!1,shadowMode:!1})}}]);
|
2
|
-
//# sourceMappingURL=325.js.map
|