@shumai-one/shumai 0.4.7 → 0.4.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/{chunk-6rjkbwz6.js → chunk-07pgpftg.js} +7 -7
- package/bin/{chunk-wvq717b5.js → chunk-0b5s5ge0.js} +2 -2
- package/bin/{chunk-zz0522zr.js → chunk-0jaj2807.js} +3 -3
- package/bin/{chunk-5qkwpy8c.js → chunk-1qk4e3j9.js} +2 -2
- package/bin/{chunk-3b6h719s.js → chunk-1y7nvhgx.js} +2 -2
- package/bin/{chunk-yqvhgtez.js → chunk-1ymyhrh2.js} +2 -2
- package/bin/{chunk-j41mya13.js → chunk-1zpsbvq9.js} +2 -2
- package/bin/{chunk-vdnmq163.js → chunk-251rat7t.js} +1 -1
- package/bin/{chunk-p5fwjk5c.js → chunk-29wjvgwv.js} +1 -1
- package/bin/{chunk-fk712d68.js → chunk-2ftmxhr5.js} +1 -1
- package/bin/{chunk-fvgb6rps.js → chunk-2y7y60pc.js} +2 -2
- package/bin/{chunk-rkqpnyzx.js → chunk-3rjdkmhb.js} +1 -1
- package/bin/{chunk-q6jsw0rr.js → chunk-43dzhk24.js} +48 -48
- package/bin/{chunk-3g5pyw2e.js → chunk-45mheqnm.js} +2 -2
- package/bin/{chunk-b3aqmcps.js → chunk-4sq35ks7.js} +2 -2
- package/bin/{chunk-fhazy8f9.js → chunk-4tm9cw4v.js} +1 -1
- package/bin/{chunk-kg2c445x.js → chunk-4tpkx2ft.js} +1 -1
- package/bin/chunk-55n569j1.js +1 -0
- package/bin/{chunk-887pj9xd.js → chunk-5pcv139g.js} +2 -2
- package/bin/{chunk-8gna37dd.js → chunk-65ets3f0.js} +1 -1
- package/bin/{chunk-8ystwvdt.js → chunk-67ewr4j4.js} +1 -1
- package/bin/{chunk-xca338dw.js → chunk-6h76kqv2.js} +3 -3
- package/bin/chunk-6jaf9hxa.js +1 -0
- package/bin/{chunk-k810fstm.js → chunk-6t5r26bm.js} +1 -1
- package/bin/{chunk-camzbwqh.js → chunk-6vst0k0k.js} +1 -1
- package/bin/{chunk-an6nsq1t.js → chunk-6xqpbkb6.js} +1 -1
- package/bin/{chunk-radcwage.js → chunk-75x3b8ds.js} +2 -2
- package/bin/chunk-7hxd4st0.js +1 -0
- package/bin/{chunk-3h9c5ak3.js → chunk-7nv7r7zx.js} +1 -1
- package/bin/{chunk-s41mgkse.js → chunk-7rvyq5gr.js} +1 -1
- package/bin/{chunk-m638fg4n.js → chunk-9ht2kr33.js} +5 -5
- package/bin/chunk-9kb55e6b.js +1 -0
- package/bin/{chunk-h3wr8nnk.js → chunk-9v10mkts.js} +1 -1
- package/bin/{chunk-05tnmf8h.js → chunk-afsm0ct9.js} +2 -2
- package/bin/{chunk-njabdtvb.js → chunk-b93qxjts.js} +2 -2
- package/bin/{chunk-xzyfnfck.js → chunk-b9p9yhky.js} +2 -2
- package/bin/{chunk-v1sgrg0r.js → chunk-bbk5v964.js} +1 -1
- package/bin/{chunk-rdscv38p.js → chunk-bcjkapyp.js} +1 -1
- package/bin/{chunk-4a88wwg2.js → chunk-bcqhjbpy.js} +1 -1
- package/bin/{chunk-zcdqsp1e.js → chunk-bxksbrcm.js} +1 -1
- package/bin/chunk-c1a1srsw.js +2 -0
- package/bin/chunk-c7yxnyep.js +1 -0
- package/bin/{chunk-8b1w6bj9.js → chunk-czwpfv0w.js} +1 -1
- package/bin/{chunk-ebx3bd4c.js → chunk-d9dmr2vc.js} +1 -1
- package/bin/chunk-da4fd4f8.js +2 -0
- package/bin/{chunk-kq2qbwx1.js → chunk-dk2trprj.js} +1 -1
- package/bin/{chunk-m2h7a172.js → chunk-dmewtzbe.js} +1 -1
- package/bin/{chunk-pa1fmskf.js → chunk-dp1mrw7m.js} +1 -1
- package/bin/{chunk-dyq6h9ha.js → chunk-dpn61sht.js} +1 -1
- package/bin/{chunk-781990k7.js → chunk-drpdjxmw.js} +1 -1
- package/bin/{chunk-b0rjvx5g.js → chunk-e333evwr.js} +2 -2
- package/bin/{chunk-gf4n4ahk.js → chunk-e3qxpswy.js} +1 -1
- package/bin/chunk-faaqparg.js +2 -0
- package/bin/{chunk-4jgq9m51.js → chunk-fezar34g.js} +2 -2
- package/bin/{chunk-pcspeqwq.js → chunk-fnca3xqw.js} +2 -2
- package/bin/{chunk-6kdf411z.js → chunk-frma9pgq.js} +1 -1
- package/bin/chunk-g82qnxw6.js +2 -0
- package/bin/{chunk-4f5pnnah.js → chunk-gj3vrbkx.js} +12 -12
- package/bin/{chunk-mm1a0zja.js → chunk-hed37kyr.js} +1 -1
- package/bin/{chunk-nnq8g9yy.js → chunk-ht64xpjp.js} +3 -3
- package/bin/{chunk-nn5hyf6f.js → chunk-j3qz3wa3.js} +1 -1
- package/bin/chunk-j6ptdqp9.js +2 -0
- package/bin/{chunk-9va1mzeq.js → chunk-j95fjg69.js} +1 -1
- package/bin/{chunk-q1d7x1cc.js → chunk-jgnp68ez.js} +1 -1
- package/bin/{chunk-0ygtayqf.js → chunk-jhxcm88f.js} +1 -1
- package/bin/{chunk-ccvjwhqq.js → chunk-jwhgybtg.js} +1 -1
- package/bin/chunk-kdg245g7.js +1 -0
- package/bin/{chunk-8sf106rq.js → chunk-mcq3pe4v.js} +1 -1
- package/bin/chunk-mg4p33eg.js +2 -0
- package/bin/{chunk-z9jpgxf1.js → chunk-mn9ax7qa.js} +1 -1
- package/bin/chunk-mrdznst9.js +1 -0
- package/bin/chunk-msg8j3hj.css +1 -0
- package/bin/{chunk-1ntn42d2.js → chunk-n4f1he1g.js} +3 -3
- package/bin/{chunk-twyxs4z2.js → chunk-nradb5py.js} +1 -1
- package/bin/chunk-nsvfcp3f.js +1 -0
- package/bin/{chunk-9v6eqa3n.js → chunk-nx782n1x.js} +2 -2
- package/bin/{chunk-3m5kwcj7.js → chunk-p4hwyysm.js} +1 -1
- package/bin/{chunk-dkzyv61a.js → chunk-p706vjvr.js} +2 -2
- package/bin/{chunk-jde9r5mj.js → chunk-pbmkewt5.js} +1 -1
- package/bin/{chunk-3tyk9xgf.js → chunk-pbq64m5k.js} +2 -2
- package/bin/{chunk-njqf50vw.js → chunk-pg5mayjc.js} +1 -1
- package/bin/{chunk-rbagbd0e.js → chunk-pq3pyrvy.js} +1 -1
- package/bin/{chunk-e17daz1x.js → chunk-qje7g7t7.js} +1 -1
- package/bin/{chunk-r55htzxr.js → chunk-qn37fsy3.js} +1 -1
- package/bin/{chunk-3r5yc5wm.js → chunk-qrmkkxjh.js} +4 -4
- package/bin/chunk-qw4v0qdg.js +1 -0
- package/bin/{chunk-zr11zfwc.js → chunk-qw76wcrb.js} +1 -1
- package/bin/{chunk-ebf1r872.js → chunk-r8ss8xm1.js} +4 -4
- package/bin/{chunk-s63vj79f.js → chunk-rvj965cr.js} +1 -1
- package/bin/{chunk-4m8gk79m.js → chunk-rzannb5e.js} +2 -2
- package/bin/{chunk-yr03tf5r.js → chunk-s26a26h3.js} +1 -1
- package/bin/{chunk-jt04mf5s.js → chunk-sf9ezxgy.js} +1 -1
- package/bin/{chunk-hye75kp0.js → chunk-t2sqtc9p.js} +2 -2
- package/bin/{chunk-k3qypq3x.js → chunk-tf3hke5h.js} +1 -1
- package/bin/{chunk-vx66rms0.js → chunk-tjhbr5ks.js} +1 -1
- package/bin/chunk-twwpbp8d.js +2 -0
- package/bin/{chunk-xznabrt2.js → chunk-twx715xf.js} +1 -1
- package/bin/{chunk-zmjtv19e.js → chunk-tycap2k9.js} +1 -1
- package/bin/chunk-v3yfee88.js +2 -0
- package/bin/{chunk-typ46eqd.js → chunk-v6tjp5qt.js} +4 -4
- package/bin/{chunk-ycw3rwhx.js → chunk-vfv27kve.js} +3 -3
- package/bin/chunk-vq24vj88.js +1 -0
- package/bin/{chunk-53vtc74g.js → chunk-w53gqdnw.js} +2 -2
- package/bin/{chunk-q45n02fs.js → chunk-wdbew0hx.js} +1 -1
- package/bin/{chunk-11c93g1m.js → chunk-wqqdy0xb.js} +2 -2
- package/bin/{chunk-s30fjvzs.js → chunk-ws216bmf.js} +1 -1
- package/bin/{chunk-5v4s2kp4.js → chunk-x33bf3ay.js} +1 -1
- package/bin/{chunk-5rk7dyx9.js → chunk-x79scans.js} +51 -51
- package/bin/chunk-xktxk53n.js +1 -0
- package/bin/{chunk-rkafv27g.js → chunk-xmn5v64e.js} +1 -1
- package/bin/{chunk-zbt4h7n0.js → chunk-y4pe65d1.js} +1 -1
- package/bin/{chunk-ny7qjn6s.js → chunk-ybnykjsg.js} +1 -1
- package/bin/{chunk-3p1bb08a.js → chunk-yeb5bcxz.js} +1 -1
- package/bin/{chunk-ayq8dskd.js → chunk-yvz2b957.js} +1 -1
- package/bin/{chunk-t3t7dcfq.js → chunk-ze3msq86.js} +1 -1
- package/bin/{chunk-5wp37g6w.js → chunk-zhx4vsgt.js} +2 -2
- package/bin/shumai-app.html +1 -1
- package/bin/shumai-app.js +258 -257
- package/package.json +7 -7
- package/bin/chunk-0xsgx9ep.js +0 -1
- package/bin/chunk-1ajgdv26.js +0 -1
- package/bin/chunk-30dsxm8s.js +0 -1
- package/bin/chunk-58e1a3re.js +0 -2
- package/bin/chunk-6ksrrayx.css +0 -1
- package/bin/chunk-bgm76rzj.js +0 -1
- package/bin/chunk-btmxr226.js +0 -1
- package/bin/chunk-ee3mrvqp.js +0 -2
- package/bin/chunk-fg6zf2gb.js +0 -2
- package/bin/chunk-g9gmht89.js +0 -2
- package/bin/chunk-htpjtarr.js +0 -2
- package/bin/chunk-j547gtag.js +0 -2
- package/bin/chunk-jf4kcad0.js +0 -1
- package/bin/chunk-k5hnrtrt.js +0 -1
- package/bin/chunk-qjzyze00.js +0 -1
- package/bin/chunk-rfhmk32e.js +0 -1
- package/bin/chunk-xbge27m4.js +0 -1
- package/bin/chunk-xcsz1wp7.js +0 -1
- package/bin/chunk-zb0az2tq.js +0 -2
- package/bin/chunk-zej27b5c.js +0 -2
package/bin/chunk-bgm76rzj.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,Ue,A,lt,wt,Vp}from"./chunk-q6jsw0rr.js";import"./chunk-5rk7dyx9.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-r55htzxr.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-xznabrt2.js";import{Gn}from"./chunk-kq2qbwx1.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();function i(){let{projectId:o}=l.useParams(),{teamId:r,ensureTeamIdForProject:a}=lt();h(()=>{a(o)},[o,a]);let{data:s}=rr(Vp(o)),e=s?.rootFolder,{data:n}=Z({queryKey:["folders",e],queryFn:()=>(async()=>await(await A.api.folders[":folderId"].$get({param:{folderId:e}})).json())(),enabled:!!e});if(!r||!e||!n)return t(wt,{});return t(Gn,{teamId:r,projectId:o,projectName:s.name??"",assetId:"recents",rootFolderId:e})}var l=Ue("/projects/$projectId/recents")({component:i});export{l as Route};
|
package/bin/chunk-btmxr226.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,Ue,A,lt,wt,Gp}from"./chunk-q6jsw0rr.js";import"./chunk-5rk7dyx9.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-r55htzxr.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-xznabrt2.js";import{Gn}from"./chunk-kq2qbwx1.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();function l(){let{projectId:o}=c.useParams(),{teamId:r,ensureTeamIdForProject:a}=lt();h(()=>{a(o)},[o,a]);let{data:s}=rr(Gp(o)),e=s?.rootFolder,{data:i}=Z({queryKey:["folders",e],queryFn:async()=>{let n=await A.api.folders[":folderId"].$get({param:{folderId:e}});if(!n.ok)throw Error("failed to fetch folder");return await n.json()},enabled:!!e});if(!r||!e||!i)return t(wt,{});return t(Gn,{teamId:r,projectId:o,projectName:s.name??"",assetId:e,rootFolderId:e})}var c=Ue("/projects/$projectId/")({component:l});export{c as Route};
|
package/bin/chunk-ee3mrvqp.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{P,h,D,b,u,S,L,t,o,K,Z,B,ft,A,I,wr,F,Do,ke,ve,rn,bt,vt,er,we,Re,C,E,he,Ja,ge,Ae,W,Vr,Vt,fs,ps,ms,yf,Ne,ld,it,Fc,Lc,mr,dd,_b,Ob,Ri,qf,Wf,Kh,Wh,xl,ug,cp,Oo,Fo,Od,Je,Xe,et,tt,rt,nt,ot,st,ue,ie,me,Ge,le,H,ce,Pt,Nt,k,xo,So,Qr,kn,be,Ur,Kd}from"./chunk-q6jsw0rr.js";import{Ea,Ca,Or,lu,cu,es,ts,ys,vs}from"./chunk-5rk7dyx9.js";import{Ui,au}from"./chunk-xca338dw.js";import{qs}from"./chunk-zz0522zr.js";var ct=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],Ze=I("pencil",ct);S();S();function Qe({teamId:d,projectId:s,file:r,onSaveField:l,members:z,onCommentSelect:f,hideAnnotationControl:V=!1,readOnly:w=!1,publicFields:y,isPublic:m=!1,shareId:N,currentTime:q,onTyping:te,selectedCommentId:p,heightPercent:j,onHeightPercentChange:Q}){let{canEdit:O}=Pt(s),{fields:c,setFields:J}=Or(),se=K(),{ref:re,inView:fe}=Nt(),[a,M]=u(null),[U,ne]=u(!1),[Te,ze]=u(null),G=b(!1),Ve=b(0),Y=b(j),je=(e)=>{G.current=!0,Ve.current=e.clientY,Y.current=j,e.target.setPointerCapture?.(e.pointerId)},Me=P((e)=>{if(!G.current)return;let v=(Ve.current-e.clientY)/window.innerHeight*100,oe=Math.min(85,Math.max(10,Y.current+v));Q(oe)},[Q]),De=(e)=>{G.current=!1;try{e.target.releasePointerCapture?.(e.pointerId)}catch{}},{data:ee}=Z({queryKey:["fields",s],queryFn:async()=>{let e=await A.api.projects[":projectId"].fields.$get({param:{projectId:s}});if(!e.ok)throw Error("Failed to fetch fields");return await e.json()},enabled:!!s&&!y}),T=es(r);h(()=>{if(y)J(y,s);else if(ee)J(ee,s)},[ee,y,s,J]);let{data:xe,fetchNextPage:X,hasNextPage:Ie}=ft({queryKey:m?["shares",N,"files",r?.id,"comments"]:["files",r?.id,"comments"],queryFn:async({pageParam:e})=>{if(m){let i=localStorage.getItem(`share_pwd_${N}`)||"",v=await A.api.shares[":shareId"].files[":fileId"].comments.$get({param:{shareId:N,fileId:r.id},query:{after:e}},{headers:{"x-share-password":i}});if(!v.ok)throw Error("Failed to fetch comments");return await v.json()}else{let i=await A.api.files[":fileId"].comments.$get({param:{fileId:r.id},query:{after:e}});if(!i.ok)throw Error("Failed to fetch comments");return await i.json()}},enabled:!!r?.id&&(!m||!!N),initialPageParam:"",refetchInterval:2000,getNextPageParam:(e)=>e.pageInfo?.cursor||void 0}),{mutate:Pe}=B({mutationFn:async({text:e,attachmentIds:i,annotations:v,replyToId:oe,guestUserId:ye,second:Ce})=>{if(m){let de=localStorage.getItem(`share_pwd_${N}`)||"",Be=await A.api.shares[":shareId"].files[":fileId"].comments.$post({param:{shareId:N,fileId:r.id},json:{message:e,attachmentIds:i,replyToId:oe??void 0,annotations:v,second:Ce??void 0}},{headers:{"x-share-password":de,...ye?{"x-guest-user-id":ye}:{}}});if(!Be.ok)throw Error("Failed to create comment");return await Be.json()}else{let de=await A.api.files[":fileId"].comments.$post({param:{fileId:r.id},json:{message:e,attachmentIds:i,replyToId:oe??void 0,annotations:v,second:Ce??void 0}});if(!de.ok)throw Error("Failed to create comment");return await de.json()}},onSuccess:()=>{se.invalidateQueries({queryKey:m?["shares",N,"files",r?.id,"comments"]:["files",r?.id,"comments"]})},onError:()=>{k.error(Ob?.()||"Failed to post comment")}}),Se=xe?.pages?.[0]?.pageInfo?.total??xe?.pages.reduce((e,i)=>e+(i.data?.length||0),0)??0;h(()=>{if(fe&&Ie)X()},[fe,X,Ie]);let _=D(()=>(r?.fieldValues||[]).reduce((e,i)=>(e[i.fieldId]=i,e),{}),[r?.fieldValues]),ae=D(()=>[...c].sort((e,i)=>{let v=e.config?.name?.toLowerCase()||"",oe=i.config?.name?.toLowerCase()||"";if(v<oe)return-1;if(v>oe)return 1;return 0}),[c]),Ee=xe?.pages.flatMap((e)=>e.data??[])??[],_e=(e,i,v=[],oe,ye)=>{if(!e.trim()&&i.length===0&&v.length===0)return;let Ce=oe||a?.id||null;if(m){let de=localStorage.getItem(`guest_user_id_${N}`);if(!de)ze({text:e,attachmentIds:i,annotations:v,replyToId:Ce,second:ye}),ne(!0);else Pe({text:e,attachmentIds:i,annotations:v,replyToId:Ce,guestUserId:de,second:ye})}else Pe({text:e,attachmentIds:i,annotations:v,replyToId:Ce,second:ye});M(null)},Oe=(e)=>{if(Te)Pe({...Te,guestUserId:e}),ze(null),M(null)},Fe=(e)=>{let i=z.find((v)=>v.id===e);if(i)return i;return{id:"unknown",name:"Unknown",role:"unknown"}},Le=j<=15;return o("div",{style:{height:`${j}dvh`},className:"shrink-0 flex flex-col bg-background border-t border-border shadow-2xl rounded-t-2xl overflow-hidden select-none z-20","data-testid":"mobile-bottom-sheet",children:[t("div",{onPointerDown:je,onPointerMove:Me,onPointerUp:De,onPointerCancel:De,className:"w-full pt-2 pb-1.5 flex flex-col items-center justify-center cursor-grab active:cursor-grabbing touch-none shrink-0","aria-label":"Drag to resize bottom sheet",children:t("div",{className:"w-10 h-1 rounded-full bg-muted-foreground/30 hover:bg-muted-foreground/50 transition-colors"})}),o(xo,{defaultValue:"comments",className:"flex-1 flex flex-col min-h-0 px-2 pb-1 overflow-hidden",children:[o(So,{className:"w-full shrink-0 h-9 bg-muted/60 p-1",children:[o(Qr,{value:"comments",className:"flex-1 text-xs font-semibold py-1",children:[ld()," ",Se>0&&`(${Se})`]}),t(Qr,{value:"fields",className:"flex-1 text-xs font-semibold py-1",children:Ri()})]}),o(kn,{value:"comments",className:C("flex-1 flex flex-col overflow-hidden min-h-0 mt-2",Le&&"hidden"),children:[t("div",{className:"flex items-center justify-between px-2 pb-1.5 shrink-0 border-b border-border/50",children:o("span",{className:"text-xs font-bold text-foreground",children:[yf?.()||"All comments",Se>0?` (${Se})`:""]})}),t(ce,{className:"flex-1 min-h-0 px-2 py-2 [&>div>div]:block!",children:Ee.length===0?t("div",{className:"py-8 text-center text-xs text-muted-foreground",children:Wh()}):o("div",{className:"space-y-3",children:[Ee.map((e)=>o("div",{children:[t(Ui,{teamId:d,message:e,getUser:Fe,onReply:M,hasReplies:!!e.replies?.length,formatTimestamp:T?.commentsConfig?.formatTimestamp,frameRate:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.frameRate||30:void 0,startTimecode:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.startTimecode:void 0,isSelected:p===e.id,onSelect:()=>{f?.(e)},readOnly:w,isPublic:m}),e.replies?.map((i,v)=>t("div",{children:t(Ui,{teamId:d,isReply:!0,message:i,getUser:Fe,onReply:M,hasReplies:!1,isLastReply:v===(e.replies?.length??0)-1,formatTimestamp:T?.commentsConfig?.formatTimestamp,frameRate:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.frameRate||30:void 0,startTimecode:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.startTimecode:void 0,isSelected:p===i.id,onSelect:()=>{f?.(i)},readOnly:w,isPublic:m})},i.id))]},e.id)),t("div",{ref:re})]})}),(!w||m)&&t("div",{className:"mt-auto shrink-0 bg-background border-t border-border pt-1",children:t(au,{isOpen:U,onClose:()=>ne(!1),onSuccess:Oe,children:t(qs,{projectId:s,onSendMessage:_e,replyingTo:a,onCancelReply:()=>M(null),hideAnnotationControl:V,disableMentions:m,currentTime:T?.commentsConfig?.hasTimestamp?q:void 0,formatTimestamp:T?.commentsConfig?.formatTimestamp,frameRate:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.frameRate||30:void 0,startTimecode:T?.commentsConfig?.hasTimestamp?r?.media?.metadata?.startTimecode:void 0,onTyping:te})})})]}),t(kn,{value:"fields",className:C("flex-1 flex flex-col overflow-hidden min-h-0 mt-2",Le&&"hidden"),children:t(ce,{className:"flex-1 px-3 py-2 min-h-0 [&>div>div]:block!",children:ae&&ae.length>0?t("div",{className:"space-y-4 pb-6",children:ae.map((e)=>o("div",{className:"space-y-1.5",children:[t("label",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide",children:e.config?.name}),t("div",{className:"min-h-[32px]",children:t(vs,{fieldId:e.id,config:e.config,value:_[e.id]?.value,onSave:O?(i)=>l(e.id,i):void 0,readOnly:w||e.readOnly||!O})})]},e.id))}):t("div",{className:"py-8 text-center text-xs text-muted-foreground",children:"No custom fields defined"})})})]})]})}function Ye({fileName:d,folderName:s,version:r,versions:l,activeFileId:z,isPublic:f=!1,shareId:V,allowDownload:w=!0,downloadInfo:y,canEdit:m=!1,onBack:N,onPrevFile:q,onNextFile:te,hasPrevFile:p=!1,hasNextFile:j=!1,onSelectVersion:Q,onRename:O,onDelete:c,onLinkedTasks:J,linkedTaskCount:se=0}){let re=async(a)=>{try{let M=f&&V?await A.api.shares[":shareId"].files[":fileId"]["download-url"].$post({param:{shareId:V,fileId:z},json:{key:a}}):await A.api.files["download-url"].$post({json:{key:a,assetId:z}});if(!M.ok)return;let{url:U}=await M.json(),ne=document.createElement("a");ne.href=U,ne.download="",document.body.appendChild(ne),ne.click(),document.body.removeChild(ne)}catch{}},fe=(y?.videoTranscodes?.length??0)>0;return o("header",{className:"flex h-12 w-full items-center justify-between border-b border-border bg-card px-2 py-1.5 shrink-0 select-none z-30",children:[t("div",{className:"flex items-center",children:t(E,{variant:"ghost",size:"icon",onClick:N,className:"h-8 w-8 text-foreground hover:bg-accent cursor-pointer","aria-label":cp(),children:t(rn,{className:"h-5 w-5"})})}),o("div",{className:"flex flex-1 items-center justify-center gap-1 min-w-0 px-1",children:[o("div",{className:"flex items-center min-w-0 max-w-[65vw]",children:[s&&o(L,{children:[t("span",{className:"truncate text-xs font-medium text-muted-foreground max-w-[80px]",children:s}),t("span",{className:"text-muted-foreground mx-1 text-xs",children:"/"})]}),l&&l.length>1?o(he,{modal:!1,children:[t(ge,{asChild:!0,children:o("button",{className:"flex items-center gap-1 min-w-0 truncate text-xs font-medium text-foreground hover:bg-accent rounded px-1 py-0.5 transition-colors cursor-pointer",children:[t("span",{className:"truncate max-w-[120px] font-semibold",children:d}),r!==void 0&&o(be,{variant:"outline",className:"px-1 py-0 text-[10px] shrink-0 font-normal",children:["v",r]}),t(ve,{className:"h-3 w-3 shrink-0 text-muted-foreground"})]})}),o(Ae,{align:"center",className:"w-48 z-40",children:[t(Vr,{className:"text-xs",children:Od()}),l.map((a)=>o(W,{onClick:()=>Q?.(a.id),className:C("flex items-center justify-between text-xs cursor-pointer",a.id===z?"bg-accent font-semibold text-accent-foreground":""),children:[o("span",{children:["v",a.version]}),t("span",{className:"text-[11px] text-muted-foreground truncate max-w-[120px]",children:a.name||d})]},a.id))]})]}):o("div",{className:"flex items-center gap-1 min-w-0 truncate",children:[t("span",{className:"truncate text-xs font-semibold text-foreground max-w-[140px]",children:d}),r!==void 0&&o(be,{variant:"outline",className:"px-1 py-0 text-[10px] shrink-0 font-normal",children:["v",r]})]})]}),(p||j)&&o("div",{className:"flex items-center gap-0.5 shrink-0 bg-muted/60 rounded p-0.5 ml-1",children:[t(E,{variant:"ghost",size:"icon",disabled:!p,onClick:q,className:"h-5 w-5 p-0 text-muted-foreground hover:text-foreground disabled:opacity-30 cursor-pointer",title:ug(),"aria-label":ug(),children:t(rn,{className:"h-3.5 w-3.5"})}),t(E,{variant:"ghost",size:"icon",disabled:!j,onClick:te,className:"h-5 w-5 p-0 text-muted-foreground hover:text-foreground disabled:opacity-30 cursor-pointer",title:Kh(),"aria-label":Kh(),children:t(bt,{className:"h-3.5 w-3.5"})})]})]}),t("div",{className:"flex items-center gap-1",children:o(he,{modal:!1,children:[t(ge,{asChild:!0,children:t(E,{variant:"ghost",size:"icon",className:"h-8 w-8 text-foreground hover:bg-accent cursor-pointer","aria-label":Wf(),children:t(wr,{className:"h-4 w-4"})})}),o(Ae,{align:"end",className:"w-52 z-40",children:[w&&(fe?o(fs,{children:[o(ps,{className:"flex items-center gap-2 text-xs cursor-pointer",children:[t(vt,{className:"h-3.5 w-3.5"}),t("span",{children:mr()})]}),t(Ja,{children:o(ms,{className:"w-48 z-50",children:[t(Vr,{className:"text-xs",children:mr()}),y?.videoTranscodes?.map((a)=>{let M=Math.max(a.width,a.height),U=`${a.height}p`;if(M>=3840)U="2160p";else if(M>=1920)U="1080p";else if(M>=1280)U="720p";else if(M>=960)U="540p";else if(M>=640)U="360p";else if(M>=320)U="180p";return o(W,{onClick:()=>re(a.key),className:"flex items-center justify-between text-xs cursor-pointer",children:[t("span",{children:U}),t("span",{className:"text-[10px] text-muted-foreground",children:"MP4"})]},U)}),y?.originalKey&&o(L,{children:[t(Vt,{}),o(W,{onClick:()=>re(y.originalKey),className:"flex items-center justify-between text-xs cursor-pointer",children:[t("span",{children:xl?.()||"Original"}),t("span",{className:"text-[10px] text-muted-foreground",children:d.split(".").pop()?.toUpperCase()||"RAW"})]})]})]})})]}):o(W,{onClick:()=>y?.originalKey&&re(y.originalKey),disabled:!y?.originalKey,className:"flex items-center gap-2 text-xs cursor-pointer",children:[t(vt,{className:"h-3.5 w-3.5"}),t("span",{children:mr()})]})),l&&l.length>1&&Q&&o(fs,{children:[t(ps,{className:"flex items-center gap-2 text-xs cursor-pointer",children:t("span",{children:Od?.()||"Switch version"})}),t(Ja,{children:o(ms,{className:"w-48 z-50",children:[t(Vr,{className:"text-xs",children:Od?.()||"Switch version"}),l.map((a)=>o(W,{onClick:()=>Q(a.id),className:C("flex items-center justify-between text-xs cursor-pointer",a.id===z?"bg-accent font-semibold text-accent-foreground":""),children:[o("span",{children:["v",a.version]}),t("span",{className:"text-[10px] text-muted-foreground truncate max-w-[120px]",children:a.name||d})]},a.id))]})})]}),J&&o(W,{onClick:J,className:"flex items-center justify-between text-xs cursor-pointer",children:[o("span",{className:"flex items-center gap-2",children:[t(Do,{className:"h-3.5 w-3.5"}),t("span",{children:qf?.()||"Linked Tasks"})]}),se>0&&t("span",{className:"inline-flex items-center justify-center px-1.5 py-0.2 text-[10px] font-semibold rounded-full bg-muted-foreground/15 text-foreground",children:se})]}),m&&O&&o(W,{onClick:O,className:"flex items-center gap-2 text-xs cursor-pointer",children:[t(Ze,{className:"h-3.5 w-3.5"}),t("span",{children:Oo()})]}),m&&c&&o(L,{children:[t(Vt,{}),o(W,{onClick:c,className:"flex items-center gap-2 text-xs text-destructive focus:text-destructive cursor-pointer",children:[t(we,{className:"h-3.5 w-3.5"}),t("span",{children:it()})]})]})]})]})})]})}function Fl({projectId:d,teamId:s="",fileId:r,file:l,projectInfo:z,ancestorFolders:f=[],versions:V,activeFileId:w,startTime:y,isPublic:m=!1,shareId:N,allowDownload:q=!0,publicFields:te,siblingFiles:p=[],onNavigateToFile:j,onNavigateBack:Q,onRenameFile:O,onDeleteFile:c,onSaveField:J,onSelectVersion:se}){let{canEdit:re}=Pt(d),{members:fe}=Ur(),a=b(null),[M,U]=u(50),[ne,Te]=u([]),[ze,G]=u(0),[Ve,Y]=u(null),[je,Me]=u(!1),[De,ee]=u(""),T=b(null),[xe,X]=u(!1),[Ie,Pe]=u(!1),[Se,_]=u(!1),[ae,Ee]=u(!1),{data:_e}=Z({queryKey:["teams",s,"kanban","assets",w,"tasks"],queryFn:async()=>{if(!s||!w||m)return{data:[],total:0};let x=await A.api.teams[":teamId"].kanban.assets[":assetId"].tasks.$get({param:{teamId:s,assetId:w}});if(!x.ok)return{data:[],total:0};return await x.json()},enabled:!!s&&!!w&&!m}),Oe=_e?.total??_e?.data?.length??0,{prevFile:Fe,nextFile:Le}=D(()=>{if(!p||p.length===0)return{prevFile:null,nextFile:null};let x=p.findIndex((pe)=>pe.id===r||pe.id===w);if(x===-1)return{prevFile:null,nextFile:null};return{prevFile:x>0?p[x-1]:null,nextFile:x<p.length-1?p[x+1]:null}},[p,r,w]),e=f.length>0?f[0]?.name:z?.name,v=V?.find((x)=>x.id===w)?.version??(V&&V.length>0?V.length:void 0),oe=D(()=>({originalKey:l.media?.original?.key,videoTranscodes:l.media?.videoTranscodes?.map((x)=>({key:x.key,width:x.width,height:x.height}))}),[l.media]),ye=()=>{Te([]),Y(null)},Ce=(x)=>{Y(x.id||null);let pe=x.annotations;if(pe&&pe.length>0)Te(pe);else Te([]);if(x.second!==null&&x.second!==void 0)a.current?.seekTo(x.second),a.current?.pause();else if(pe&&pe.length>0)a.current?.pause()},de=async(x)=>{if(x?.preventDefault(),!De.trim()||!O)return;try{Pe(!0),await O(De.trim()),Me(!1)}finally{Pe(!1)}},Be=async()=>{if(!c)return;try{X(!0),await c(),_(!1)}finally{X(!1)}};return h(()=>{G(0),Y(null),Te([])},[l?.id]),o("div",{className:"flex h-[100dvh] w-full flex-col bg-background overflow-hidden relative",children:[t(Ye,{fileName:l.name,folderName:e,version:v,versions:V,activeFileId:w,isPublic:m,shareId:N,allowDownload:q,downloadInfo:oe,canEdit:re,onBack:Q,hasPrevFile:!!Fe,hasNextFile:!!Le,onPrevFile:()=>Fe&&j(Fe.id),onNextFile:()=>Le&&j(Le.id),onSelectVersion:se,onRename:()=>{ee(l.name),Me(!0)},onDelete:()=>_(!0),onLinkedTasks:!m?()=>Ee(!0):void 0,linkedTaskCount:Oe}),t("div",{className:"relative flex-1 min-h-0 bg-background overflow-hidden flex flex-col",children:t(ts,{file:l,mediaControllerRef:a,onPlay:ye,onTimeUpdate:G,annotations:ne,startTime:y,shareId:N,allowDownload:q})}),t(Qe,{teamId:s,projectId:d,file:l,onSaveField:J,members:fe,onCommentSelect:Ce,hideAnnotationControl:l.proxyType==="audio",readOnly:m||!re,publicFields:te,isPublic:m,shareId:N,currentTime:ze,onTyping:()=>a.current?.pause(),selectedCommentId:Ve,heightPercent:M,onHeightPercentChange:U}),!m&&ae&&t(Kd,{teamId:s,assetId:w,assetName:l.name,isOpen:ae,onClose:()=>Ee(!1)}),!m&&t(ue,{open:je,onOpenChange:Me,children:t(ie,{children:o("form",{onSubmit:de,children:[t(me,{children:t(le,{children:Oo()})}),t("div",{className:"py-4",children:t(H,{ref:T,value:De,onChange:(x)=>ee(x.target.value),placeholder:dd?.()||"Enter new name",onFocus:()=>{setTimeout(()=>{if(T.current)ys(T.current)},0)},autoFocus:!0})}),o(Ge,{children:[t(E,{type:"button",variant:"outline",onClick:()=>Me(!1),children:Ne()}),o(E,{type:"submit",disabled:Ie||!De.trim(),children:[Ie&&t(F,{className:"mr-2 h-4 w-4 animate-spin"}),Fo()]})]})]})})}),!m&&t(Je,{open:Se,onOpenChange:_,children:o(Xe,{children:[o(et,{children:[t(rt,{children:Lc?.()||"Delete Asset?"}),t(nt,{children:Fc?.()||"Deleted items can be recovered for 30 days before being permanently deleted."})]}),o(tt,{children:[t(st,{children:Ne()}),o(ot,{onClick:Be,disabled:xe,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:[xe&&t(F,{className:"mr-2 h-4 w-4 animate-spin"}),it()]})]})]})})]})}S();function We({activeState:d,activeAsset:s,previewUrl:r,isFullScreen:l,onTogglePlay:z,onToggleLoop:f,onSeek:V,onVolumeChange:w,onToggleMute:y,onChangePlaybackRate:m,onChangeResolution:N,onZoomIn:q,onZoomOut:te,onFit:p,onDownload:j,onToggleFullScreen:Q,allowDownload:O=!0}){if(d?.kind==="video"&&d.video&&s){let c=d.video,J=c.totalFrames/c.frameRate,se=c.currentFrame/c.frameRate,re={isPlaying:c.isPlaying,progress:J>0?se/J*100:0,currentTime:se,duration:J,volume:c.volume,isMuted:c.isMuted,isLooping:c.isLooping,playbackRate:c.playbackRate,isFullScreen:l,showFrames:!1,currentResolution:c.currentResolution},fe=r&&!s.media?.videoPreview?{...s,media:{...s.media,videoPreview:{url:r}}}:s;return t(lu,{state:re,zoom:d.zoom,isControlsVisible:!0,floatOverlayInFullScreen:!1,buffered:c.buffered,data:fe,resolutions:c.resolutions,togglePlay:z,toggleLoop:f,toggleMute:y,handleVolumeChange:w,changePlaybackRate:m,changeResolution:(a)=>N(a.resolution),handleDownload:(a)=>j(a),toggleFullScreen:Q,onZoomChange:(a)=>a>=d.zoom?q():te(),onZoomReset:p,frameRate:c.frameRate,totalFrames:c.totalFrames,currentFrame:c.currentFrame,seekToFrame:V,allowDownload:O})}if(d?.kind==="image")return t(cu,{zoom:d.zoom,onZoomIn:q,onZoomOut:te,onFit:p,onDownload:()=>j(),canDownload:!!s?.media?.original?.key,fullscreen:{isFullScreen:l,onToggle:Q},allowDownload:O});return t("div",{className:"relative z-10 flex items-center justify-end gap-2 border-t border-border bg-card px-4 py-3",children:t("button",{onClick:Q,className:"text-foreground transition-colors hover:text-primary",title:"Fullscreen",children:l?t(Ca,{className:"h-5 w-5"}):t(Ea,{className:"h-5 w-5"})})})}function qe({side:d,fileName:s,version:r,activeVersionId:l,versions:z,isActive:f,onActivate:V,onSwitchVersion:w,onExit:y}){let m=C("flex-shrink-0 rounded p-1 transition-colors hover:bg-muted",f?"text-foreground":"text-muted-foreground hover:text-foreground"),N=t("button",{onClick:y,title:_b(),className:m,children:t(Re,{className:"h-4 w-4"})}),q=o("button",{onClick:V,className:C("flex min-w-0 items-center gap-1 rounded px-2 py-1 text-sm font-medium transition-colors hover:bg-muted",f?"text-foreground":"text-muted-foreground hover:text-foreground"),children:[t("span",{className:"truncate",children:s}),r!==void 0&&o("span",{className:C("flex-shrink-0 rounded border px-1 py-0 text-xs",f?"border-foreground/40":"border-border"),children:["v",r]})]}),te=o(he,{children:[t(ge,{onClick:V,title:Od(),className:m,children:t(ve,{className:"h-4 w-4"})}),t(Ae,{align:d==="left"?"start":"end",className:"w-80 p-1",children:t("div",{className:"flex max-h-96 flex-col gap-1 overflow-y-auto",children:z.map((p)=>{let j=p.id===l;return o(W,{onClick:()=>w(p.id),className:"flex cursor-pointer items-center gap-3 rounded-md px-3 py-2",children:[o("div",{className:"flex min-w-[2rem] flex-shrink-0 items-center justify-center rounded-full bg-muted px-2 py-0.5 text-xs font-semibold text-muted-foreground select-none",children:["v",p.version]}),t("div",{className:"flex h-10 w-16 flex-shrink-0 items-center justify-center overflow-hidden rounded-md border border-border bg-muted",children:p.previewUrl?t("img",{src:p.previewUrl,alt:p.name||void 0,className:"h-full w-full object-cover"}):t(er,{className:"h-4 w-4 text-muted-foreground"})}),o("div",{className:"flex min-w-0 flex-1 flex-col text-left",children:[t("span",{className:"truncate text-sm font-semibold text-foreground",children:p.name}),t("span",{className:"truncate text-xs text-muted-foreground",children:p.creator?.name||"Unknown"})]}),j&&t(ke,{className:"ml-auto h-4 w-4 flex-shrink-0 text-primary"})]},p.id)})})})]});return t("div",{onMouseDown:V,className:C("dark flex h-10 flex-shrink-0 items-center gap-1 border-b bg-background px-2 transition-colors",f?"border-b-2 border-primary":"border-border"),children:d==="left"?o(L,{children:[N,q,te]}):o(L,{children:[q,te,t("div",{className:"ml-auto"}),N]})})}function at(d,s,r){return Z({queryKey:s?["public-share-file",r,d,localStorage.getItem(`share_pwd_${r}`)||""]:["files",d],queryFn:async()=>{if(s){let z=localStorage.getItem(`share_pwd_${r}`)||"",f=await A.api.shares[":shareId"].files[":fileId"].$get({param:{shareId:r,fileId:d}},{headers:{"x-share-password":z}});if(!f.ok)throw Error("Failed to fetch version asset");return await f.json()}let l=await A.api.files[":fileId"].$get({param:{fileId:d}});if(!l.ok)throw Error("Failed to fetch version asset");return await l.json()},enabled:!!d&&(!s||!!r)})}function Ll({isPublic:d=!1,shareId:s,versions:r,leftId:l,rightId:z,activeSide:f,annotations:V,seekRequest:w,onActiveSideChange:y,onSwitchVersion:m,onExit:N,onActiveAssetChange:q,onPlay:te,onTimeUpdate:p,allowDownload:j=!0}){let Q=b(null),O=b(null),c=b(null),[J,se]=u(null),[re,fe]=u(null),[a,M]=u(1),[U,ne]=u(!1),[Te,ze]=u(!1),{data:G,isLoading:Ve}=at(l,d,s),{data:Y,isLoading:je}=at(z,d,s),Me=es(G),De=es(Y),ee=!!G&&!!Y&&Me.id===De.id,T=f==="left"?G:Y,xe=f==="left"?J:re,X=P(()=>f==="left"?O.current:c.current,[f]),Ie=P(()=>f==="left"?c.current:O.current,[f]);h(()=>{q(T??null)},[T,q]),h(()=>{if(!w)return;let n=X();if(n?.seekToSecond(w.second),n?.pause(),ee){let g=Ie();g?.seekToSecond(w.second),g?.pause()}},[w?.nonce]),h(()=>{let n=()=>ze(!!document.fullscreenElement);return document.addEventListener("fullscreenchange",n),()=>document.removeEventListener("fullscreenchange",n)},[]);let Pe=P((n)=>se(n),[]),Se=P((n)=>fe(n),[]),_=P((n)=>{let g=X();if(g)n(g);if(ee){let R=Ie();if(R)n(R)}},[X,Ie,ee]),ae=P(()=>{let n=!xe?.video?.isPlaying;_((g)=>n?g.play():g.pause())},[xe?.video?.isPlaying,_]);h(()=>{let n=(g)=>{let R=document.activeElement;if(R&&(R.tagName==="INPUT"||R.tagName==="TEXTAREA"||R instanceof HTMLElement&&R.isContentEditable))return;let He=g.key===" ",Ue=R&&(R.tagName==="BUTTON"||R.tagName==="A"||R.tagName==="SELECT"||R.tagName==="OPTION"||R.getAttribute("role")==="button"||R.getAttribute("role")==="link"||R.getAttribute("role")==="checkbox"||R.getAttribute("role")==="radio"||R.getAttribute("role")==="menuitem");if(He&&Ue)return;if(g.key===" "||g.key.toLowerCase()==="k")g.preventDefault(),ae()};return window.addEventListener("keydown",n),()=>{window.removeEventListener("keydown",n)}},[ae]);let Ee=P((n)=>_((g)=>g.seekToFrame(n)),[_]),_e=P(()=>X()?.toggleLoop(),[X]),Oe=P((n)=>{M(n),ne(n===0)},[]),Fe=P(()=>ne((n)=>!n),[]),Le=P((n)=>_((g)=>g.setPlaybackRate(n)),[_]),e=P((n)=>X()?.changeResolution(n),[X]),i=P(()=>_((n)=>n.zoomBy(1.2)),[_]),v=P(()=>_((n)=>n.zoomBy(0.8)),[_]),oe=P(()=>_((n)=>n.fit()),[_]),ye=P((n)=>{X()?.download(n)},[X]),Ce=P(()=>{let n=Q.current;if(!n||typeof n.requestFullscreen!=="function")return;if(!document.fullscreenElement)n.requestFullscreen().catch(()=>{});else if(document.exitFullscreen)document.exitFullscreen().catch(()=>{})},[]),de=P((n,g)=>{if(ee)c.current?.panBy(n,g)},[ee]),Be=P((n,g)=>{if(ee)O.current?.panBy(n,g)},[ee]),x=P(()=>ae(),[ae]),pe=P((n)=>r.find((g)=>g.id===n)?.version,[r]),lt=D(()=>T?.media?.videoPreview?.url,[T?.media?.videoPreview?.url]),Ke=(n,g)=>{let He=es(g)?.comparePane;if(!He)return t("div",{className:"flex flex-1 items-center justify-center bg-gray-100 dark:bg-gray-950",children:t("p",{className:"text-muted-foreground",children:"Preview unavailable"})});let Ue=f===n;return t(He,{ref:n==="left"?O:c,file:g,shareId:s,isActive:Ue,annotations:Ue?V:[],onStateChange:n==="left"?Pe:Se,onUserPan:n==="left"?de:Be,onActivate:()=>y(n),muted:Ue?U:!0,volume:a,onPlay:te,onTimeUpdate:p,onRequestTogglePlay:x},g.id)},dt=!!G&&!!Y,mt=Ve||je;return o("div",{ref:Q,className:"flex h-full flex-1 flex-col bg-background",children:[o("div",{className:"flex min-h-0 flex-1",children:[o("div",{className:"flex min-w-0 flex-1 flex-col border-r border-zinc-800",children:[G&&t(qe,{side:"left",fileName:G.name,version:pe(l),activeVersionId:l,versions:r,isActive:f==="left",onActivate:()=>y("left"),onSwitchVersion:(n)=>m("left",n),onExit:N}),t("div",{className:"relative flex min-h-0 flex-1",children:G?Ke("left",G):t("div",{className:"flex flex-1 items-center justify-center",children:t(F,{className:"h-6 w-6 animate-spin text-foreground"})})})]}),o("div",{className:"flex min-w-0 flex-1 flex-col",children:[Y&&t(qe,{side:"right",fileName:Y.name,version:pe(z),activeVersionId:z,versions:r,isActive:f==="right",onActivate:()=>y("right"),onSwitchVersion:(n)=>m("right",n),onExit:N}),t("div",{className:"relative flex min-h-0 flex-1",children:Y?Ke("right",Y):t("div",{className:"flex flex-1 items-center justify-center",children:t(F,{className:"h-6 w-6 animate-spin text-foreground"})})})]})]}),mt&&!dt&&t("div",{className:"absolute inset-0 z-10 flex items-center justify-center bg-background/30",children:t(F,{className:"h-8 w-8 animate-spin text-foreground"})}),t(We,{activeState:xe,activeAsset:T??null,previewUrl:lt,isFullScreen:Te,onTogglePlay:ae,onToggleLoop:_e,onSeek:Ee,onVolumeChange:Oe,onToggleMute:Fe,onChangePlaybackRate:Le,onChangeResolution:e,onZoomIn:i,onZoomOut:v,onFit:oe,onDownload:ye,onToggleFullScreen:Ce,allowDownload:j})]})}
|
|
2
|
-
export{Fl,Ll};
|
package/bin/chunk-fg6zf2gb.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{nf,Pn,ic,lc,cc,uc,_u,yu,im,yA,Ss,jo,zr}from"./chunk-t3t7dcfq.js";export{cc as EncryptJWT,lc as SignJWT,im as UnsecuredJWT,nf as base64url,uc as calculateJwkThumbprint,_u as createLocalJWKSet,yu as createRemoteJWKSet,zr as decodeJwt,jo as decodeProtectedHeader,Ss as importJWK,yA as importPKCS8,ic as jwtDecrypt,Pn as jwtVerify};
|
package/bin/chunk-g9gmht89.js
DELETED
package/bin/chunk-htpjtarr.js
DELETED
package/bin/chunk-j547gtag.js
DELETED
package/bin/chunk-jf4kcad0.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t,Ue}from"./chunk-q6jsw0rr.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-5rk7dyx9.js";import"./chunk-887pj9xd.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-zz0522zr.js";import"./chunk-ee3mrvqp.js";import"./chunk-xznabrt2.js";import{va}from"./chunk-58e1a3re.js";import"./chunk-4m8gk79m.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";function p(){let{shareId:a,fileId:s}=e.useParams(),{start:n,version:o,compare:r,cmpLeft:i,cmpRight:l,cmpActive:c}=e.useSearch();return t(va,{shareId:a,initialFileId:s,startTime:n,versionId:o,compare:r,compareLeftId:i,compareRightId:l,compareActiveSide:c})}var e=Ue("/share/$shareId/files/$fileId")({component:p});export{e as Route};
|
package/bin/chunk-k5hnrtrt.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,Ue,A,lt,wt,Xp}from"./chunk-q6jsw0rr.js";import"./chunk-5rk7dyx9.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-r55htzxr.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-xznabrt2.js";import{Gn}from"./chunk-kq2qbwx1.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();function l(){let{projectId:o,folderId:n}=c.useParams(),{teamId:r,ensureTeamIdForProject:a}=lt();h(()=>{a(o)},[o,a]);let{data:s}=rr(Xp(o)),e=s?.rootFolder,{data:i}=Z({queryKey:["folders",e],queryFn:()=>(async()=>await(await A.api.folders[":folderId"].$get({param:{folderId:e}})).json())(),enabled:!!e});if(!r||!e||!i)return t(wt,{});return t(Gn,{teamId:r,projectId:o,projectName:s.name??"",assetId:n,rootFolderId:e})}var c=Ue("/projects/$projectId/folders/$folderId")({component:l});export{c as Route};
|
package/bin/chunk-qjzyze00.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,Ue,A,lt,wt,tm}from"./chunk-q6jsw0rr.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-xznabrt2.js";import{Zi}from"./chunk-4f5pnnah.js";import"./chunk-an6nsq1t.js";import"./chunk-b0rjvx5g.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-fk712d68.js";import"./chunk-9va1mzeq.js";import"./chunk-8sf106rq.js";S();function p(){let{projectId:e,folderId:d}=s.useParams(),{teamId:r,ensureTeamIdForProject:i}=lt();h(()=>{i(e)},[e,i]);let{data:a}=rr(tm(e)),o=a?.rootFolder,{data:l}=Z({queryKey:["folders",o],queryFn:async()=>{let n=await A.api.folders[":folderId"].$get({param:{folderId:o}});if(!n.ok)throw Error("failed to fetch folder");return await n.json()},enabled:!!o});if(!r||!o||!l)return t(wt,{});return t(Zi,{teamId:r,projectId:e,projectName:a.name??"",assetId:d,rootFolderId:o,isRoot:!1})}var s=Ue("/projects/$projectId/folders/$folderId_/agentsmd")({component:p});export{s as Route};
|
package/bin/chunk-rfhmk32e.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,B,Ue,A,Nh,lt,em,_A}from"./chunk-q6jsw0rr.js";import"./chunk-5rk7dyx9.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-r55htzxr.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-xznabrt2.js";import{Gn}from"./chunk-kq2qbwx1.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();function u(){let{projectId:o,collectionId:r}=y.useParams(),{teamId:s,ensureTeamIdForProject:i}=lt();h(()=>{i(o)},[o,i]);let{data:l}=rr(em(o)),{data:a,refetch:d}=Z({..._A(r)}),{mutate:p}=B({mutationFn:async(n)=>{let c=await A.api.collections[":collectionId"].$patch({param:{collectionId:r},json:n});if(!c.ok)throw Error("Failed to update collection");return await c.json()},onSuccess:()=>{d()}}),e=l?.rootFolder,{data:f}=Z({queryKey:["folders",e],queryFn:async()=>{let n=await A.api.folders[":folderId"].$get({param:{folderId:e}});if(!n.ok)throw Error("Failed to fetch folder");return await n.json()},enabled:!!e});if(!s||!e||!f||!a)return t("div",{children:Nh()});let m=a.filter.sourceFolderId||e;return t(Gn,{teamId:s,projectId:o,projectName:l.name??"",assetId:m,rootFolderId:e,collection:a,onUpdateCollection:p})}var y=Ue("/projects/$projectId/collections/$collectionId")({component:u});export{y as Route};
|
package/bin/chunk-xbge27m4.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,b,u,S,L,t,o,K,Si,Z,B,Me,Un,Ue,A,F,er,C,E,Ne,it,Fc,Lc,zy,dd,ki,Lb,wh,Oo,HE,Fo,Je,Xe,et,tt,rt,nt,ot,st,ue,ie,me,Ge,le,H,lt,Nt,k,on,Ur,$t,lr,gr,Lo,hA}from"./chunk-q6jsw0rr.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import{Wr}from"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import{wa}from"./chunk-rkafv27g.js";import{Xo,Ul,ts,ys}from"./chunk-5rk7dyx9.js";import{Fl,Ll}from"./chunk-ee3mrvqp.js";import"./chunk-j41mya13.js";import{Sa}from"./chunk-xca338dw.js";import{Er}from"./chunk-xznabrt2.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();var kt=({item:n})=>{if(n.preview?.thumbnailUrl)return t("img",{src:n.preview.thumbnailUrl,alt:"Preview",className:"w-full h-full object-cover"});if(n.preview?.proxyType==="audio"||n.proxyType==="audio")return t("div",{className:"w-full h-full flex items-center justify-center bg-muted",children:t(Xo,{className:"w-5 h-5 text-muted-foreground"})});return t("div",{className:"w-full h-full flex items-center justify-center bg-muted",children:t(er,{className:"w-5 h-5 text-muted-foreground"})})},Te=({projectId:n,currentAssetId:s,parentFolderId:w,initialFiles:d,initialNextCursor:D})=>{let{ref:a,inView:N}=Nt({threshold:0,rootMargin:"200px"}),x=b(null),V=b(!0),[c,p]=u(d),[f,U]=u(D),[W,Y]=u(!!D),[q,g]=u(!1);return h(()=>{p(d),U(D),Y(!!D),V.current=!0},[d,D]),h(()=>{(async()=>{if(!f||q||!N||!W)return;g(!0);try{let y=await A.api.folders[":folderId"].search.$post({param:{folderId:w},json:{assetType:"file",after:f,first:200,recursively:!1,conditions:[]}});if(!y.ok)throw Error("Failed to fetch next page");let P=await y.json(),X=P.data||[];p((G)=>[...G,...X]),U(P.pageInfo?.cursor||void 0),Y(!!P.pageInfo?.cursor&&X.length>0)}catch(y){console.error("Error fetching next page:",y)}finally{g(!1)}})()},[N,f,W,q,w]),h(()=>{if(c.some((y)=>y?.id===s)&&x.current)if(V.current)x.current.scrollIntoView({block:"center",inline:"center",behavior:"auto"}),V.current=!1;else x.current.scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})},[c,s]),t("div",{className:"h-24 md:h-full w-full md:w-24 bg-gray-100 dark:bg-gray-950 flex flex-row md:flex-col flex-shrink-0 select-none",children:o("div",{className:"flex-1 overflow-x-auto overflow-y-hidden md:overflow-y-auto md:overflow-x-hidden px-4 md:px-0 py-2 md:py-4 flex flex-row md:flex-col items-center gap-3 no-scrollbar",children:[c.map((m)=>{if(!m)return null;let y=m.id===s;return t("div",{ref:m.id===s?x:null,className:"flex-shrink-0",children:o(Un,{to:"/projects/$projectId/files/$fileId",params:{projectId:n,fileId:m.id},search:{version:void 0},className:C("rounded-lg border overflow-hidden flex items-center justify-center transition-all bg-muted/30 block relative",y?"w-[62px] h-[62px] opacity-100":"w-[52px] h-[52px] opacity-60 hover:opacity-100"),children:[t(kt,{item:m}),m.agent&&t("span",{className:"absolute top-1 right-1 z-10 pointer-events-none select-none rounded bg-black/60 px-1 py-0.5 text-[10px] font-medium leading-none text-white",title:m.agent.name,"data-testid":"carousel-agent-badge",children:"AI"})]})},m.id)}),W&&t("div",{ref:a,className:"px-2 md:px-0 py-2 md:py-4 flex justify-center items-center h-full md:w-full flex-shrink-0",children:q&&t(F,{className:"h-5 w-5 animate-spin text-muted-foreground"})})]})})};S();function At(){let{projectId:n,fileId:s}=$e.useParams(),w=$e.useSearch(),{version:d,start:D}=w,a=d||s,{cmpLeft:N,cmpRight:x}=w,V=w.cmpActive??"left",c=!!w.compare&&!!N&&!!x,p=b(null),{teamId:f,ensureTeamIdForProject:U}=lt(),[W,Y]=u(360),[q,g]=u([]),{fileViewRightSidebarCollapsed:m}=$t(),{isChatbotOpen:y}=lr(),P=gr((e)=>Boolean(e.metadata["appearance.hideAgent"])),[X,G]=u(0),[he,z]=u(null),[ge,Le]=u(null),[Ee,ye]=u(void 0),[_,ne]=u({show:!1,files:[],nextCursor:void 0,folderId:void 0}),Ve=A.api.files[":fileId"].metadata.$patch,{mutate:qe}=B({mutationFn:async(e)=>{let r=await Ve(e);if(!r.ok)throw Error("Failed to patch metadata");return await r.json()}}),J=K(),{members:Pe,fetchProjectMembers:Ie}=Ur(),ze=Lo();h(()=>{U(n)},[n,U]),h(()=>{if(n)Ie(n,!0)},[n,Ie]),h(()=>{if(n&&s)A.api.projects[":projectId"].recents.view.$post({param:{projectId:n},json:{assetId:s}}).catch(()=>{})},[n,s]);let{data:ve,isLoading:_e,isError:Ke,isFetching:Oe}=Z({queryKey:["files",s],queryFn:async()=>{let e=await A.api.files[":fileId"].$get({param:{fileId:s}});if(!e.ok)throw Error("Failed to fetch stack");return await e.json()},enabled:!!f,placeholderData:Si}),{data:He,isLoading:Qe,isError:Be,isFetching:We}=Z({queryKey:["files",d],queryFn:async()=>{let e=await A.api.files[":fileId"].$get({param:{fileId:d}});if(!e.ok)throw Error("Failed to fetch version");return await e.json()},enabled:!!f&&!!d,placeholderData:Si}),{data:Ye}=Z({queryKey:["version_stacks",s,"versions"],queryFn:async()=>{let e=await A.api.version_stacks[":stackId"].versions.$get({param:{stackId:s}});if(!e.ok)throw Error("Failed to fetch versions");return await e.json()},enabled:!!n&&!!s&&(!!d||c)}),{data:R}=Z({queryKey:["projects",n],queryFn:async()=>{let e=await A.api.projects[":projectId"].$get({param:{projectId:n}});if(!e.ok)throw Error("Failed to fetch project");return await e.json()}}),I=Me(),{setProjectState:we,clearProjectState:xe}=on(),Ze=_e||!!d&&Qe,at=Ke||!!d&&Be,ct=Oe||!!d&&We,i=He||ve,j=d?Ye:ve?.versionStack?.versions,l=i?.ancestorFolders?.[0]?.id??R?.rootFolder??"",[re,ee]=u(!1),[te,be]=u(""),se=b(null),ae=b(!1),[dt,ce]=u(!1),ft=A.api.files[":fileId"].$put,{mutate:pt,mutateAsync:ut,isPending:Fe}=B({mutationFn:async(e)=>{let r=await ft(e);if(!r.ok)throw Error("Failed to rename file");return await r.json()},onSuccess:()=>{J.invalidateQueries({queryKey:["files"]}),J.invalidateQueries({queryKey:["version_stacks"]}),k.success(HE?.()||"Renamed successfully"),ee(!1)},onError:()=>{k.error(Lb?.()||"Failed to rename")}}),mt=A.api.files.$delete,{mutate:ht,mutateAsync:gt,isPending:ke}=B({mutationFn:async(e)=>{if(!(await mt(e)).ok)throw Error("Failed to delete file")},onSuccess:()=>{if(J.invalidateQueries({queryKey:["files"]}),J.invalidateQueries({queryKey:["version_stacks"]}),k.success(zy?.()||"Deleted"),ce(!1),l&&l!==R?.rootFolder)I({to:"/projects/$projectId/folders/$folderId",params:{projectId:n,folderId:l}});else I({to:"/projects/$projectId",params:{projectId:n}})},onError:()=>{k.error(ki?.()||"Failed to delete")}}),yt=(e)=>{if(e?.preventDefault(),!te.trim()||!a)return;pt({param:{fileId:a},json:{name:te.trim()}})},It=()=>{if(!a)return;ht({json:{ids:[a]}})};h(()=>{if(i&&R&&f)we({teamId:f,projectId:n,projectName:R.name??"",ancestorFolders:i.ancestorFolders??[],currentAsset:{id:a||s,name:i.name,type:"file",version:j?j.find((e)=>e.id===a)?.version??j.length:void 0,proxyType:i.proxyType},isRootFolder:!1,fileId:s,downloadInfo:{originalKey:i.media?.original?.key,videoTranscodes:i.media?.videoTranscodes?.map((e)=>({key:e.key,width:e.width,height:e.height}))},versions:j,compareMode:c,canCompareVersions:(j?.length??0)>=2,onCompareVersions:()=>{let e=Ul(j);if(!e)return;I({to:"/projects/$projectId/files/$fileId",params:{projectId:n,fileId:s},search:(r)=>({...r,version:void 0,compare:!0,cmpLeft:e.left.id,cmpRight:e.right.id,cmpActive:"left"})})},onFolderClick:(e)=>{I({to:"/projects/$projectId/folders/$folderId",params:{projectId:n,folderId:e}})},onRename:()=>{ae.current=!1,be(i?.name??""),ee(!0)},onDelete:()=>{ce(!0)}});return()=>xe()},[f,n,R,i,j,a,s,c,we,xe,I]),h(()=>{if(!re)return;let e=setTimeout(()=>{ae.current=!0},1000);return()=>clearTimeout(e)},[re]);let vt=()=>{if(ae.current)return;setTimeout(()=>{if(se.current)ys(se.current)},0)};if(h(()=>{if(!l||!a)return;if(_.folderId===l)return;let e=!0;return(async()=>{try{let v="",T=!1,M=[],fe=void 0;for(let De=0;De<5;De++){let Se=await A.api.folders[":folderId"].search.$post({param:{folderId:l},json:{assetType:"file",after:v,first:200,recursively:!1,conditions:[]}});if(!Se.ok)throw Error("Failed to search parent folder for carousel");let Q=await Se.json(),pe=Q.data||[];if(M.push(...pe),pe.some((oe)=>oe.id===a)){if(T=!0,fe=Q.pageInfo?.cursor||void 0,Q.pageInfo?.cursor)try{let oe=await A.api.folders[":folderId"].search.$post({param:{folderId:l},json:{assetType:"file",after:Q.pageInfo.cursor,first:200,recursively:!1,conditions:[]}});if(oe.ok){let Re=await oe.json(),Ft=Re.data||[];M.push(...Ft),fe=Re.pageInfo?.cursor||void 0}}catch{}break}if(!Q.pageInfo?.cursor||pe.length<200)break;v=Q.pageInfo.cursor}if(e)if(T)ne({show:!0,files:M,nextCursor:fe,folderId:l});else ne({show:!1,files:[],nextCursor:void 0,folderId:l})}catch(v){if(console.error(v),e)ne({show:!1,files:[],nextCursor:void 0,folderId:l})}})(),()=>{e=!1}},[l,a,_.folderId]),h(()=>{G(0),z(null),g([])},[i?.id]),h(()=>{z(null),g([])},[ge?.id]),h(()=>{Wr.getState().reset(),Wr.getState().setIsDrawing(!1),g([]),z(null)},[a]),Ze&&!i)return t(hA,{});if(at||!i||!R||!f)return t("div",{children:wh()});let O=c?ge:i,Ae=O?.id??a,je=(e,r)=>{if(!f)return;qe({param:{fileId:Ae},json:[{key:e,value:r}]},{onSuccess:()=>{J.invalidateQueries({queryKey:["files",Ae]})}})},de=(e)=>{I({to:"/projects/$projectId/files/$fileId",params:{projectId:n,fileId:s},search:(r)=>({...r,...e})})},wt=()=>{de({compare:void 0,cmpLeft:void 0,cmpRight:void 0,cmpActive:void 0,version:V==="left"?N:x})},xt=(e)=>{z(e.id||null);let r=e.annotations;if(r&&r.length>0)g(r);else g([]);if(c){if(e.second!==null&&e.second!==void 0)ye({second:e.second,nonce:Date.now()});return}if(e.second!==null&&e.second!==void 0)p.current?.seekTo(e.second),p.current?.pause();else if(r&&r.length>0)p.current?.pause()},bt=(e)=>{z(e.id||null);let v=e.details,T=v?.annotations;if(T&&T.length>0)g(T);else g([]);let M=v?.position?.type==="time"?v.position.seconds:v?.position?.type==="page"?v.position.page:void 0;if(c){if(M!==void 0)ye({second:M,nonce:Date.now()});return}if(M!==void 0)p.current?.seekTo(M),p.current?.pause();else if(T&&T.length>0)p.current?.pause()},Ce=()=>{g([]),z(null)};if(ze&&!c)return t(Fl,{projectId:n,teamId:f,fileId:s,file:i,projectInfo:R,ancestorFolders:i.ancestorFolders??[],parentFolderId:l,versions:j,activeFileId:a,startTime:D,siblingFiles:_.files,onNavigateToFile:(e)=>{I({to:"/projects/$projectId/files/$fileId",params:{projectId:n,fileId:e}})},onNavigateBack:()=>{if(l&&l!==R?.rootFolder)I({to:"/projects/$projectId/folders/$folderId",params:{projectId:n,folderId:l}});else I({to:"/projects/$projectId",params:{projectId:n}})},onSelectVersion:(e)=>{I({to:"/projects/$projectId/files/$fileId",params:{projectId:n,fileId:s},search:(r)=>({...r,version:e})})},onRenameFile:async(e)=>{await ut({param:{fileId:a},json:{name:e}})},onDeleteFile:async()=>{await gt({json:{ids:[a]}})},onSaveField:je});return o("div",{className:"h-full flex flex-1 flex-col bg-background",children:[o("div",{className:"h-full flex flex-1 overflow-hidden",children:[o("div",{className:"flex-1 relative",children:[ct&&!c&&t("div",{className:"absolute inset-0 z-10 flex items-center justify-center bg-background/50",children:t(F,{className:"h-8 w-8 animate-spin text-foreground"})}),c&&N&&x?t(Ll,{versions:j??[],leftId:N,rightId:x,activeSide:V,annotations:q,seekRequest:Ee,onActiveSideChange:(e)=>de({cmpActive:e}),onSwitchVersion:(e,r)=>de(e==="left"?{cmpLeft:r}:{cmpRight:r}),onExit:wt,onActiveAssetChange:Le,onPlay:Ce,onTimeUpdate:G}):t(ts,{file:i,mediaControllerRef:p,onPlay:Ce,onTimeUpdate:G,annotations:q,startTime:D,children:_.show&&t(Te,{projectId:n,currentAssetId:a,parentFolderId:l,initialFiles:_.files,initialNextCursor:_.nextCursor})})]}),(!m||y&&!P)&&o(L,{children:[t(Er,{onResize:(e)=>{Y((r)=>Math.max(300,Math.min(600,r-e)))},className:"hidden md:block"}),t("div",{style:{width:W},className:"flex-shrink-0 bg-background flex flex-col",children:y&&!P?t(wa,{projectId:n,contextAssetId:a,file:O,currentTime:X,frameRate:O?.media?.metadata?.frameRate||30,startTimecode:O?.media?.metadata?.startTimecode,onTyping:()=>{if(c)return;p.current?.pause()},onSelectMessage:bt,selectedMessageId:he}):t(Sa,{teamId:f,projectId:n,file:O,onSaveField:je,members:Pe,onCommentSelect:xt,currentTime:X,onTyping:()=>{if(c)return;p.current?.pause()},selectedCommentId:he,hideAnnotationControl:O?.proxyType==="audio"})})]})]}),t(ue,{open:re,onOpenChange:ee,children:t(ie,{children:o("form",{onSubmit:yt,children:[t(me,{children:t(le,{children:Oo()})}),t("div",{className:"py-4",children:t(H,{ref:se,value:te,onChange:(e)=>be(e.target.value),placeholder:dd?.()||"Enter new name",onFocus:vt,autoFocus:!0})}),o(Ge,{children:[t(E,{type:"button",variant:"outline",onClick:()=>ee(!1),children:Ne()}),o(E,{type:"submit",disabled:Fe||!te.trim(),children:[Fe&&t(F,{className:"mr-2 h-4 w-4 animate-spin"}),Fo()]})]})]})})}),t(Je,{open:dt,onOpenChange:ce,children:o(Xe,{children:[o(et,{children:[t(rt,{children:Lc?.()||"Delete Asset?"}),t(nt,{children:Fc?.()||"Deleted items can be recovered for 30 days before being permanently deleted."})]}),o(tt,{children:[t(st,{children:Ne()}),o(ot,{onClick:It,disabled:ke,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:[ke&&t(F,{className:"mr-2 h-4 w-4 animate-spin"}),it()]})]})]})})]})}var $e=Ue("/projects/$projectId/files/$fileId")({component:At});export{$e as Route};
|
package/bin/chunk-xcsz1wp7.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h,S,t,Z,Ue,A,lt,wt,Qp}from"./chunk-q6jsw0rr.js";import"./chunk-5rk7dyx9.js";import"./chunk-6rjkbwz6.js";import"./chunk-camzbwqh.js";import"./chunk-3p1bb08a.js";import"./chunk-887pj9xd.js";import"./chunk-zz0522zr.js";import"./chunk-rkafv27g.js";import"./chunk-r55htzxr.js";import"./chunk-ayq8dskd.js";import"./chunk-4a88wwg2.js";import"./chunk-j41mya13.js";import"./chunk-xca338dw.js";import"./chunk-xznabrt2.js";import{Gn}from"./chunk-kq2qbwx1.js";import{rr}from"./chunk-zej27b5c.js";import"./chunk-4m8gk79m.js";import"./chunk-9va1mzeq.js";import"./chunk-jt04mf5s.js";import"./chunk-8ystwvdt.js";import"./chunk-8sf106rq.js";import"./chunk-q1d7x1cc.js";import"./chunk-fhazy8f9.js";import"./chunk-0ygtayqf.js";S();function i(){let{projectId:o}=l.useParams(),{teamId:r,ensureTeamIdForProject:a}=lt();h(()=>{a(o)},[o,a]);let{data:n}=rr(Qp(o)),e=n?.rootFolder,{data:s}=Z({queryKey:["folders",e],queryFn:()=>(async()=>await(await A.api.folders[":folderId"].$get({param:{folderId:e}})).json())(),enabled:!!e});if(!r||!e||!s)return t(wt,{});return t(Gn,{teamId:r,projectId:o,projectName:n.name??"",assetId:"recently-deleted",rootFolderId:e})}var l=Ue("/projects/$projectId/recently-deleted")({component:i});export{l as Route};
|
package/bin/chunk-zb0az2tq.js
DELETED
package/bin/chunk-zej27b5c.js
DELETED