import{a0 as x,V as w,ab as C,E as B,bh as L,v as V,a7 as F}from"./antd-B7v2hwFR.js";import{s as _,f as N,a9 as p,a5 as r,aa as t,k as a,a3 as d,a2 as $,F as E,aj as S,u as c,G as T,ad as j}from"./vue-DApy1uhY.js";const D={class:"flex flex-wrap gap-2"},G={class:"flex gap-4 category-other-item"},I={__name:"category",setup(R){const u=_([{name:"全部",key:"all"},...["一","二","三","四","五","六","七","八","九","十","十一","十二"].map((n,l)=>({name:`类目${n}`,key:`category${l+1}`}))]),e=N([]);function f(n){if(n.key==="all"){if(e.value.includes("all")){e.value=[];return}else e.value=u.value.map(l=>l.key);return}e.value.includes(n.key)?(e.value=e.value.filter(l=>l!==n.key),e.value.includes("all")&&(e.value=e.value.filter(l=>l!=="all"))):(e.value=[...e.value,n.key],e.value.length===u.value.length-1&&(e.value=[...e.value,"all"]))}const m=_([{label:"付晓晓",value:"付晓晓"},{label:"周毛毛",value:"周毛毛"}]),v=_([{label:"优秀",value:1},{label:"普通",value:2}]);return(n,l)=>{const k=C,o=w,h=B,i=V,y=L,g=x,b=F;return r(),p(b,{bordered:!1},{default:t(()=>[a(g,null,{default:t(()=>[a(o,{label:"所属类目"},{default:t(()=>[d("div",D,[(r(!0),$(E,null,S(c(u),s=>(r(),p(k,{key:s.key,"cursor-pointer":"",color:c(e).includes(s.key)?"#108ee9":"",onClick:z=>f(s)},{default:t(()=>[T(j(s.name),1)]),_:2},1032,["color","onClick"]))),128))])]),_:1}),a(h,{dashed:""}),a(o,{label:"其他选项"},{default:t(()=>[a(y,null,{default:t(()=>[d("div",G,[a(o,{label:"作者"},{default:t(()=>[a(i,{placeholder:"不限",style:{width:"100px"},options:c(m)},null,8,["options"])]),_:1}),a(o,{label:"好评度"},{default:t(()=>[a(i,{placeholder:"不限",style:{width:"100px"},options:c(v)},null,8,["options"])]),_:1})])]),_:1})]),_:1})]),_:1})]),_:1})}}};export{I as _};
