"use strict";(globalThis.webpackChunk_affine_web=globalThis.webpackChunk_affine_web||[]).push([[6798],{26798:(e,s,a)=>{a.d(s,{w:()=>k});var t=a(36870),c=a(63234),l=a(77846),o=a(69628),b=a(93965),i=a(24312),u=a(10980),d=a(17049),n=a(5863),r=a(86326),h="_1hsobt10";let k=({activeFilter:e})=>{let s=(0,u.h1)(d.j).workspace,a=(0,i.s9)(),[k,w]=(0,r.useState)(e),[m,p]=(0,n.fp)(l.Eb),{jumpToCollections:f,jumpToTags:g,jumpToSubPath:v}=(0,o.P)(),_=(0,r.useCallback)(e=>{switch(e){case"collections":f(s.id);break;case"tags":g(s.id);break;case"docs":v(s.id,b.Tk.ALL)}},[f,v,g,s]);return(0,r.useEffect)(()=>{k!==e&&(w(e),p(e))},[e,m,p,k]),(0,t.jsx)(c.z6,{style:{maxWidth:"100%",width:273},value:k,onChange:_,items:(0,r.useMemo)(()=>[{value:"docs",label:a["com.arms.docs.header"](),testId:"workspace-docs-button",className:h},{value:"collections",label:a["com.arms.collections.header"](),testId:"workspace-collections-button",className:h},{value:"tags",label:a.Tags(),testId:"workspace-tags-button",className:h}],[a])})}}}]); //# sourceMappingURL=chunk.6798.6114fab4.js.map