import{C as k}from"./Card-DfZZ6dJd.js";import{_ as w}from"./ConnectionAvatar-pck8SCUy.js";import{d as f,o as t,n as o,w as n,a,cw as N,M as v,l as u,s as d,t as s,cv as P,z as $,B as h,g as y,c as p,F as m,r as _,i as g,f as C,cu as x,Q as B,v as c,cC as E,ct as T}from"./index-Jv7TaKWs.js";import{_ as b}from"./NodeAvatar-CMw5GNkR.js";const z={class:"d-flex justify-center align-center text-grey"},L=f({__name:"ConnectionViewer",props:{connection:{}},setup(l){return(e,V)=>(t(),o(x,{elevation:"0",rounded:"0"},{default:n(()=>[a(N,{class:"expansion-panel-title"},{default:n(()=>[a(v,{"no-gutters":""},{default:n(()=>[a(w,{connection:e.connection},null,8,["connection"]),a(u),d("div",z,s(e.connection.rule.value),1),a(u)]),_:1})]),_:1}),a(P,{class:"pa-0"},{default:n(()=>[a($,{class:"ma-0",variant:"flat"},{default:n(()=>[a(h,null,{default:n(()=>[a(y,null,{default:n(()=>[(t(!0),p(m,null,_(e.connection.params,(i,r)=>(t(),o(g,{key:r},{default:n(()=>[C(s(i.id),1)]),_:2},1024))),128))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}))}}),F={class:"text-medium-emphasis"},S=f({__name:"NodeParamViewer",props:["options","value"],setup(l){return(e,V)=>(t(),o(g,{class:"paramViewer"},{default:n(()=>[a(v,{"no-gutters":""},{default:n(()=>[d("span",F,s(l.options.label),1),a(u),C(" "+s(l.options.id)+": "+s(l.value)+" "+s(l.options.unit),1)]),_:1})]),_:1}))}}),j={class:"d-flex text-button"},A={class:"ma-auto",title:"Node model"},D={class:"my-auto",title:"Population size"},R=f({__name:"NodeViewer",props:{node:{}},setup(l){return(e,V)=>e.node?(t(),o(k,{key:0,color:e.node.view.color,class:"node my-1",rounded:"1",variant:"outlined"},{default:n(()=>[a(B,null,{default:n(()=>[d("div",j,[a(b,{node:e.node,size:"48px",title:"Graphical representation"},null,8,["node"]),d("div",A,s(e.node.modelId),1),d("div",D,s(e.node.size),1)])]),_:1}),a(h,{class:"pa-0"},{default:n(()=>[e.node.paramsVisible.length>0?(t(),o(y,{key:0},{default:n(()=>[(t(!0),p(m,null,_(e.node.paramsVisible,(i,r)=>(t(),o(S,{key:r,options:e.node.params[i].options,value:e.node.params[i].value},null,8,["options","value"]))),128))]),_:1})):c("",!0)]),_:1}),e.node.connections.length>0?(t(),o(E,{key:0,class:"pa-0",style:{"min-height":"40px"}},{default:n(()=>[(t(),o(T,{key:e.node.connections.length,multiple:"",variant:"accordion"},{default:n(()=>[(t(!0),p(m,null,_(e.node.connections,(i,r)=>(t(),o(L,{key:r,connection:i},null,8,["connection"]))),128))]),_:1}))]),_:1})):c("",!0)]),_:1},8,["color"])):c("",!0)}});export{R as _};
