import{d as g,b as u,f as h,o,c as t,F,i as x,n as p,a as l,A as v,C as k,B as y,j as m}from"./_plugin-vue_export-helper-0830d71a.js";const C={style:{"box-sizing":"border-box","box-shadow":"0px 6px 20px 0px #19191a0f"},class:"w-[195px] flex px-3 py-2 bg-[#393B39] gap-2"},_={key:0,class:"flex flex-col gap-0.5"},w=["onClick"],B=l("div",{class:"w-1px bg-[#FFFFFF1A]"},null,-1),T={class:"p-1 flex flex-wrap gap-1.5"},A=["onClick"],K=g({__name:"ExpandShape",props:{selectedToolKey:null,tools:null},emits:["onClickTool"],setup(n){const r=n,a=u();h(()=>{a.value=r.tools.find(s=>s.key===r.selectedToolKey)});function b(s){a.value&&(a.value.style.strokeColor=s)}const f=u([{text:"#000000",background:"#F94737"},{text:"#000000",background:"#F6C846"},{text:"#000000",background:"#60BA5A"},{text:"#000000",background:"#426BEB"},{text:"#FFFFFF",background:"#000000"},{text:"#FFFFFF",background:"#90959D"},{text:"#000000",background:"#FFFFFF"}]);return(s,z)=>(o(),t("div",C,[n.tools?(o(),t("div",_,[(o(!0),t(F,null,x(n.tools,e=>(o(),t("div",{key:e.key,class:p(["group relative w-8 h-8 rounded-md",n.selectedToolKey===e.key?["bg-[#212121]"]:["hover:bg-[#FFFFFF1A]"]])},[l("div",{class:"w-full h-full flex justify-center items-center",onClick:c=>s.$emit("onClickTool",e)},[(o(),v(y(e.configuration.icon),{style:k({height:(e.configuration.iconHeight??20)*.75+"px"})},null,8,["style"]))],8,w)],2))),128))])):m("",!0),B,l("div",T,[(o(!0),t(F,null,x(f.value,(e,c)=>{var d,i;return o(),t("div",{key:c},[l("div",{class:"relative w-6 h-6 rounded-sm flex justify-center items-center text-xs cursor-pointer",style:k({backgroundColor:e.background}),onClick:E=>b(e.background)},[l("div",{class:p(["absolute top-[-2px] left-[-2px] border-1 border-solid z-2 rounded-sm",((i=(d=a.value)==null?void 0:d.style)==null?void 0:i.strokeColor)===e.background?["border-[#7856FF]"]:["border-transparent hover:border-white"]]),style:{width:"calc(100% + 2px)",height:"calc(100% + 2px)"}},null,2)],12,A)])}),128))])]))}});export{K as default};
