import{_ as p,d,aO as f,w as m,x as _,r as h,o,G as C,C as v,c,F as b,D as g,B as R,L as k,u as x}from"./index.1d1a5ecb.js";import{h as y}from"./index.8301d9e2.js";const L=["onClick"],w=d({__name:"role-list",props:{currentRole:{type:Object,required:!0}},emits:["changeCurrentRole"],setup(l,{emit:t}){const i=f(),s=m([]);async function u(){const{code:n,data:a,message:r}=await y({size:100});i({code:n,message:r,handler:()=>{s.value=a.list,t("changeCurrentRole",x(s)[0])}})}return _(()=>u()),(n,a)=>{const r=h("ElScrollbar");return o(),C(r,{class:"border-r border-#dcdfe6"},{default:v(()=>[(o(!0),c(b,null,g(s.value,e=>(o(),c("div",{class:R(["px-1 py-0.5 m-1.5 hover:color-blue hover:bg-#f7f7f7 cursor-pointer duration-200",l.currentRole.id===e.id&&"color-blue bg-#f7f7f7"]),key:e.id,onClick:()=>t("changeCurrentRole",e)},k(e.role_name),11,L))),128))]),_:1})}}});var E=p(w,[["__file","C:/Users/63107/Desktop/projects/accout-vue3-ui/src/views/interest/processPermission/components/role-list.vue"]]);export{E as default};
