PageSourceSearch

https://assets.livid.com/assets/index-W0HVtjOB.js

js livid.com collected 2026-10-02 04:23:30 UTC 20,868 bytes, 2 lines download raw bytes

1import{c as Qe,P as k,Q as p,ao as $,a as we,r as d,j as e,U as C,V as H,W as P,X as q,Y as N,B as l,a7 as ge,a8 as fe,a9 as je,aa as ye,ad as be,ab as ve,ac as Ce,A as Ke,a4 as g}from"./main-BLmo4jD8.js";import{C as L}from"./checkbox-D9VntcyE.js";import{I as Ye}from"./input-D5qW8bOE.js";import{L as w}from"./label-Djup5fa9.js";import{P as se}from"./progress-Cbx0bX2b.js";import{S as F}from"./spinner-B3DsP1Dk.js";import{T as ae,d as te,b as S,e as u,a as ne,c as x}from"./table-DUU0ESsE.js";import{T as Ue}from"./textarea-CNgeKW3o.js";import{A as Xe}from"./AdminLayout-Bmdt4vUM.js";import{L as Ne}from"./loader-circle-XnsuZg02.js";import{S as We}from"./search-BIXviOF3.js";import{R as Je}from"./refresh-cw-2L6_cwIu.js";import{W as Ge}from"./wrench-LuSYUa94.js";import{F as Ze}from"./film-XqB7Wi05.js";import"./index-g4CHVaDv.js";import"./index-zsmo6XAP.js";import"./check-DAMm6KPo.js";import"./index-CrghIArQ.js";import"./breadcrumb-CzYhKU5P.js";import"./chevron-right-CWkAvE-8.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new s.Error().stack;t&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[t]="b11bd0f6-16e2-4bdb-be62-a27dbfcc2399",s._sentryDebugIdIdentifier="sentry-dbid-b11bd0f6-16e2-4bdb-be62-a27dbfcc2399")}catch{}})();const Fe={name:"chart-column",size:24,node:[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],aliases:["bar-chart-3"]};Fe.node;const es=Qe(Fe),ss=async s=>{const{data:t}=await p.post("/v1/admin/codec-fix/apply",{scanId:s.scanId,dryRun:s.dryRun,force:s.force});return t},as=()=>k({mutationFn:ss}),ts=async s=>{const{data:t}=await p.post("/v1/admin/codec-fix/apply-heavy",{scanId:s.scanId,dryRun:s.dryRun,force:s.force});return t},ns=()=>k({mutationFn:ts}),Se="codec-fix-apply",rs=async s=>{const{data:t}=await p.get(`/v1/admin/codec-fix/apply/${s}`);return t},ds=s=>$({queryKey:[Se,s],queryFn:()=>rs(s),enabled:!!s,refetchInterval:t=>{const r=t.state.data;return r&&r.done?!1:2e3}}),ke="codec-fix-heavy",cs=async s=>{const{data:t}=await p.get(`/v1/admin/codec-fix/heavy/${s}`);return t},is=s=>$({queryKey:[ke,s],queryFn:()=>cs(s),enabled:!!s,refetchInterval:t=>{const r=t.state.data;return r&&r.done?!1:3e3}}),ls=async s=>{const{data:t}=await p.post(`/v1/admin/codec-fix/cancel/${s}`);return t},os=()=>{const s=we();return k({mutationFn:ls,onSuccess:(t,r)=>{s.invalidateQueries({queryKey:[Se,r]}),s.invalidateQueries({queryKey:[ke,r]})}})},hs=s=>s.hevc?"transcode":s.brokenRenditions.length>0?"remux":s.masterChanged?"relabel":"none",de="codec-fix-scan",Ie=300*1e3,ms=async s=>{const{data:t}=await p.get(`/v1/admin/codec-fix/scan/${s}`);return t},us=s=>$({queryKey:[de,s],queryFn:()=>ms(s),enabled:!!s,retry:1,refetchInterval:t=>{if(t.state.status==="error")return t.state.error?.response?.status===404?!1:3e4;const r=t.state.data;return r?r.status!=="scanning"?!1:Date.now()-r.updatedAt>Ie?3e4:1500:1500}}),xs=async s=>{const{data:t}=await p.post(`/v1/admin/codec-fix/scan/${s}/cancel`);return t},ps=()=>{const s=we();return k({mutationFn:xs,onSuccess:(t,r)=>{s.invalidateQueries({queryKey:[de,r]})}})},gs=async s=>{const{data:t}=await p.get(`/v1/admin/codec-fix/scan/${s}/impacted`,{params:{from:0}});return t},fs=(s,t)=>$({queryKey:[de,s,"impacted"],queryFn:()=>gs(s),enabled:!!s&&t,staleTime:1/0}),js=async s=>{const{data:t}=await p.post("/v1/admin/codec-fix/regenerate",{ids:s.ids,dryRun:s.dryRun});return t},ys=()=>k({mutationFn:js}),bs=async s=>{const{data:t}=await p.post("/v1/admin/codec-fix/scan",{organizationId:s.organizationId||void 0,scope:s.scope,mode:s.mode});return t},vs=()=>k({mutationFn:bs}),Cs={transcode:"transcode (HEVC→H.264)",remux:"remux",relabel:"relabel",none:"—"},Ns=({at:s})=>{const[t,r]=d.useState(()=>Date.now());d.useEffect(()=>{const o=setInterval(()=>r(Date.now()),3e4);return()=>clearInterval(o)},[]);const A=Math.max(0,Math.round((s-t)/6e4));return e.jsxs("span",{children:[" · next batch in ~",A," min"]})},ws=({a:s})=>{const t=hs(s),r=t==="transcode"?"bg-purple-500/15 text-purple-600":t==="remux"?"bg-amber-500/15 text-amber-600":"bg-blue-500/15 text-blue-600";return e.jsxs("span",{className:`rounded px-1.5 py-0.5 text-[11px] font-medium ${r}`,children:[Cs[t],s.hevc10bit&&t==="transcode"?" · 10-bit":""]})},re=500,Fs=()=>{const[s,t]=d.useState(""),[r,A]=d.useState(!0),[o,ce]=d.useState(null),[B,M]=d.useState(null),[O,ie]=d.useState(null),[Ee,Q]=d.useState(!1),[Re,K]=d.use
1State(!1),[le,De]=d.useState(!1),[Y,Ve]=d.useState(!1),[oe,He]=d.useState(""),[U,Pe]=d.useState(!1),[Ae,Te]=d.useState(()=>Date.now()),j=vs(),n=us(o),I=as(),E=ns(),c=ds(B),i=is(O),T=os(),he=ps(),R=ys(),D=oe.split(/[\s,]+/).map(a=>a.trim()).filter(Boolean),ze=()=>{D.length!==0&&(ce(null),R.mutate({ids:D,dryRun:U},{onSuccess:a=>{M(a.batchId);const f=U?" (dry run)":"";g.success(`Queued ${a.count} job(s) across ${a.videoAssetCount} video(s)${f}`),a.notFound.length>0&&g.warning(`${a.notFound.length} id(s) not found and skipped`)},onError:()=>g.error("Failed to start regenerate")}))},_e=s.trim(),m=n.data?.status==="scanning",X=n.data?.status==="completed",W=n.data?.mode==="audit",h=n.data?.summary,y=n.data?.impactedFound??0,b=fs(o,X&&!W),v=b.data?.impacted??[],z=b.data?.total??v.length,qe=m&&!!n.data&&Ae-n.data.updatedAt>Ie,Le=n.data&&n.data.total>0?Math.round(n.data.scanned/n.data.total*100):0;d.useEffect(()=>{if(!m)return;const a=setInterval(()=>Te(Date.now()),3e4);return()=>clearInterval(a)},[m]);const V=v.filter(a=>!a.hevc&&a.masterChanged),J=v.filter(a=>a.hevc),G=v.filter(a=>!a.hevc&&a.brokenRenditions.length>0),Z=J.length+G.length,me=a=>{M(null),ie(null),j.mutate({organizationId:_e||void 0,scope:r?"all":"external",mode:a},{onSuccess:f=>ce(f.scanId),onError:()=>g.error("Failed to start scan")})},$e=()=>{o&&I.mutate({scanId:o,force:le},{onSuccess:a=>{M(a.batchId),Q(!1),g.success(`Queued ${a.count} master relabel(s)`)},onError:()=>g.error("Failed to start relabel")})},Be=()=>{o&&E.mutate({scanId:o,dryRun:Y},{onSuccess:a=>{ie(a.batchId),K(!1);const f=Y?" (dry run)":"";g.success(`Queued ${a.hevcCount} transcode + ${a.remuxCount} remux, throttled 5 / 20 min${f}`)},onError:()=>g.error("Failed to start heavy fixes")})},ee=c.data?.done,ue=c.data?.status==="failed",xe=c.data?.status==="cancelled",Me=c.data&&c.data.total>0?Math.round((c.data.completed+c.data.failed)/c.data.total*100):0,_=i.data?.done,pe=i.data?.status==="cancelled",Oe=i.data&&i.data.total>0?Math.round(i.data.queued/i.data.total*100):0;return e.jsxs(Xe,{links:[e.jsx(Ke,{to:"/admin/codec-fix",children:"Codec Fix"},"codec-fix")],children:[e.jsx("div",{className:"container p-4 max-w-5xl",children:e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx("h1",{className:"text-2xl font-semibold",children:"Codec Fix"}),e.jsxs("p",{className:"text-muted-foreground",children:["Find externally-uploaded videos with codec problems and fix them. Two lanes: ",e.jsx("strong",{children:"relabel"})," rewrites a stale"," ",e.jsx("code",{children:"master.m3u8"})," ",e.jsx("code",{children:"CODECS"})," string (cheap, no re-encode); the throttled ",e.jsx("strong",{children:"HEVC + remux"})," lane re-encodes HEVC to H.264 (Chrome/Firefox can't decode HEVC) and remuxes broken single-segment rendition playlists."]})]}
1),e.jsxs(C,{children:[e.jsxs(H,{children:[e.jsx(P,{children:"Scan"}),e.jsx(q,{children:"Leave the organization blank to scan all organizations. The scan resolves codecs from each rendition (reads B2), so it is heavier than a metadata check."})]}),e.jsxs(N,{className:"space-y-4",children:[e.jsxs("div",{className:"space-y-2 max-w-md",children:[e.jsx(w,{htmlFor:"org-id",children:"Organization ID (optional)"}),e.jsx(Ye,{id:"org-id",placeholder:"All organizations",value:s,onChange:a=>t(a.target.value),disabled:j.isPending||m})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx(L,{id:"scan-all",checked:r,onCheckedChange:a=>A(a===!0),disabled:j.isPending||m}),e.jsxs(w,{htmlFor:"scan-all",className:"font-normal leading-snug",children:["Scan all B2 videos (recommended)",e.jsx("span",{className:"block text-xs text-muted-foreground",children:"Also checks source-uploads without external metadata — needed to catch HEVC passthrough masters. Uncheck to limit to external-source videos (faster, but misses HEVC passthrough)."})]})]}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx(l,{onClick:()=>me("relabel"),disabled:j.isPending||m,children:j.isPending||m?e.jsxs(e.Fragment,{children:[e.jsx(Ne,{className:"w-4 h-4 mr-2 animate-spin"}),"Scanning..."]}):e.jsxs(e.Fragment,{children:[e.jsx(We,{className:"w-4 h-4 mr-2"}),"Run scan (find fixes)"]})}),e.jsxs(l,{variant:"outline",onClick:()=>me("audit"),disabled:j.isPending||m,children:[e.jsx(es,{className:"w-4 h-4 mr-2"}),"Run census (counts only)"]})]})]})]}
1),e.jsxs(C,{children:[e.jsxs(H,{children:[e.jsx(P,{children:"Test run — regenerate specific videos"}),e.jsxs(q,{children:["Paste Video IDs or Video Asset IDs (one per line, or comma/space-separated). Force-regenerates every rendition"," ",e.jsx("code",{children:"playlist.m3u8"})," and the ",e.jsx("code",{children:"master.m3u8"})," with the new codec mechanism — no matter what, bypassing the scan and all change-detection. No re-encoding."]})]}),e.jsxs(N,{className:"space-y-4",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(w,{htmlFor:"regen-ids",children:"Video / Video Asset IDs"}),e.jsx(Ue,{id:"regen-ids",rows:4,placeholder:`video-id-1
2video-asset-id-2`,value:oe,onChange:a=>He(a.target.value),disabled:R.isPending,className:"font-mono text-xs"}),e.jsxs("p",{className:"text-xs text-muted-foreground",children:[D.length," id(s) detected."]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx(L,{id:"regen-dry-run",checked:U,onCheckedChange:a=>Pe(a===!0),disabled:R.isPending}),e.jsxs(w,{htmlFor:"regen-dry-run",className:"font-normal leading-snug",children:["Dry run (no writes)",e.jsx("span",{className:"block text-xs text-muted-foreground",children:"Computes everything but does not upload playlists or purge the CDN."})]})]}),e.jsx(l,{onClick:ze,disabled:R.isPending||D.length===0,children:R.isPending?e.jsxs(e.Fragment,{children:[e.jsx(Ne,{className:"w-4 h-4 mr-2 animate-spin"}),"Queuing..."]}):e.jsxs(e.Fragment,{children:[e.jsx(Je,{className:"w-4 h-4 mr-2"}),"Force regenerate (",D.length,")"]})})]})]}
2),n.data&&e.jsxs(C,{children:[e.jsxs(H,{children:[e.jsxs(P,{className:"flex items-center gap-2",children:[m&&e.jsx(F,{className:"size-4"}),"Scan results"]}),e.jsx(q,{children:n.data.organizationId?`Organization ${n.data.organizationId}`:"All organizations"})]}),e.jsxs(N,{className:"space-y-4",children:[m&&e.jsxs("div",{className:"space-y-2",children:[e.jsx(se,{className:"h-2",value:Le}),e.jsxs("p",{className:"text-sm text-muted-foreground",children:["Checked ",n.data.scanned," / ",n.data.total," videos ·"," ",y," impacted so far"]}),qe&&e.jsx("p",{className:"text-sm text-amber-600",children:"No progress for a while — the scan may be stalled. Polling has slowed; refresh to keep watching, or stop and start a new scan."}),o&&e.jsx(l,{variant:"outline",size:"sm",onClick:()=>he.mutate(o),disabled:he.isPending,children:"Stop scan"})]}),n.data.status==="failed"&&e.jsxs("div",{className:"p-3 bg-red-500/10 rounded text-sm text-red-600",children:["Scan failed: ",n.data.error??"Unknown error"]}),n.data.status==="cancelled"&&e.jsxs("div",{className:"p-3 bg-amber-500/10 rounded text-sm text-amber-600",children:["Scan cancelled · checked ",n.data.scanned," /"," ",n.data.total," videos · ",y," impacted (partial)"]}),X&&W&&h&&e.jsxs("div",{className:"space-y-3",children:[e.jsxs("p",{className:"text-sm",children:[e.jsx("span",{className:"font-medium",children:h.externalVideos})," ","video(s) audited."]}),e.jsx("div",{className:"border rounded-lg overflow-hidden",children:e.jsxs(ae,{children:[e.jsx(te,{children:e.jsxs(S,{children:[e.jsx(u,{children:"Bucket"}),e.jsx(u,{className:"text-right",children:"Count"})]})}),e.jsx(ne,{children:[["HEVC (any rendition)",h.hevcVideos],["— 10-bit Main 10",h.hevc10bitVideos],["— mislabeled as H.264 (cast-breaking; relabel fixes)",h.mislabeledHevcVideos],["— correctly labeled hvc1 (transcode-only for universal cast)",h.correctlyLabeledHevcVideos],["H.264 / other",h.h264Videos],["Unreadable init",h.unreadableVideos],["Missing / malformed master",h.missingOrMalformedMasterVideos],["Wrong codec string (master ≠ files, any variant)",h.wrongCodecStringVideos],["Broken rendition playlist (needs remux)",h.brokenPlaylistVideos]].map(([a,f])=>e.jsxs(S,{children:[e.jsx(x,{className:"text-xs",children:a}),e.jsx(x,{className:"text-right font-mono",children:f})]},a))})]})})]}),X&&!W&&(b.isError?e.jsxs("div",{className:"flex items-center justify-between gap-2 rounded bg-red-500/10 p-3 text-sm text-red-600",children:[e.jsxs("span",{children:["Couldn't load the impacted list (",y," ","found) — apply still works off the server. Retry to review/apply here."]}),e.jsx(l,{variant:"outline",size:"sm",onClick:()=>b.refetch(),disabled:b.isFetching,children:"Retry"})]}):b.isSuccess?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[e.jsxs("p",{className:"text-sm",children:[e.jsx("span",{className:"font-medium",children:y})," ","impacted video(s) across ",n.data.total," checked —"," ",e.jsxs("span",{className:"text-blue-600",children:[V.length," relabel"]}),","," ",e.jsxs("span",{className:"text-purple-600",children:[J.length," transcode"]}),","," ",e.jsxs("span",{className:"text-amber-600",children:[G.length," remux"]}),".",z<y&&e.jsxs("span",{className:"text-amber-600",children:[" ","List capped at ",z," — apply processes these; re-scan after applying for the rest."]})]}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsxs(l,{onClick:()=>Q(!0),disabled:V.length===0,children:[e.jsx(Ge,{className:"w-4 h-4 mr-2"}),"Relabel masters (",V.length,")"]}),e.jsxs(l,{variant:"secondary",onClick:()=>K(!0),disabled:Z===0,children:[e.jsx(Ze,{className:"w-4 h-4 mr-2"}),"Re-encode HEVC + remux (",Z,")"]})]})]}),v.length>0&&e.jsxs("div",{className:"border rounded-lg overflow-hidden",children:[e.jsxs(ae,{children:[e.jsx(te,{children:e.jsxs(S,{children:[e.jsx(u,{children:"Title"}),e.jsx(u,{children:"Fix"}),e.jsx(u,{children:"Video ID"}),e.jsx(u,{children:"Organization"}),e.jsx(u,{className:"text-right",children:"Renditions"})]})}),e.jsx(ne,{children:v.slice(0,re).map(a=>e.jsxs(S,{children:[e.jsx(x,{className:"font-medium",children:a.title}),e.jsx(x,{children:e.jsx(ws,{a})}),e.jsx(x,{className:"font-mono text-xs",children:a.videoId}),e.jsx(x,{className:"font-mono text-xs",children:a.organizationId}),e.jsx(x,{className:"text-right",children:a.renditionCount})]},a.videoAssetId))})]}),z>re&&e.jsxs("p",{className:"p-2 text-xs text-muted-foreground",children:["Showing first ",re," of"," ",z," — apply still covers the full list."]})]})]}):e.jsxs("p",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[e.jsx(F,{className:"size-4"}),"Loading impacted list… (",y," found)"]}))]})]}),o&&n.isError&&!n.data&&e.jsx(C,{children:e.jsx(N,{className:"p-4 text-sm text-amber-600",children:"Scan not found — it may have expired (finished scans are kept about 2 hours). Start a new scan."})}),c.data&&e.jsxs(C,{children:[e.jsx(H,{children:e.jsxs("div",{className:"flex items-center justify-between gap-2",children:[e.jsxs(P,{className:"flex items-center gap-2",children:[!ee&&e.jsx(F,{className:"size-4"}),ue?"Relabel failed to start":xe?"Relabel cancelled":ee?"Relabel complete":"Relabeling masters"]}),!ee&&B&&e.jsx(l,{variant:"outline",size:"sm",onClick:()=>T.mutate(B),disabled:T.isPending,children:"Cancel"})]})}),e.jsxs(N,{className:"space-y-2",children:[xe&&e.jsx("div",{className:"p-3 bg-muted rounded text-sm text-muted-foreground",children:"Cancelled — no further batches will be queued. Jobs already enqueued finish on their own."}),ue?e.jsx("div",{className:"p-3 bg-red-500/10 rounded text-sm text-red-600",children:"The orchestrator failed. Some masters may not have been relabeled — re-run the fix."}):e.jsxs(e.Fragment,{children:[e.jsx(se,{className:"h-2",value:Me}),e.jsxs("p",{className:"text-sm text-muted-foreground",children:[c.data.completed," completed",c.data.failed>0&&e.jsxs("span",{className:"text-red-600",children:[" ","· ",c.data.failed," failed"]})," ","· ",c.data.pending," remaining · ",c.data.total," ","total"]})]})]})]}
2),i.data&&e.jsxs(C,{children:[e.jsxs(H,{children:[e.jsxs("div",{className:"flex items-center justify-between gap-2",children:[e.jsxs(P,{className:"flex items-center gap-2",children:[!_&&e.jsx(F,{className:"size-4"}),pe?"HEVC + remux: cancelled":_?"HEVC + remux: all queued":"HEVC + remux (throttled)"]}),!_&&O&&e.jsx(l,{variant:"outline",size:"sm",onClick:()=>T.mutate(O),disabled:T.isPending,children:"Cancel"})]}),e.jsx(q,{children:"5 at a time, 20 min between batches. HEVC transcodes run a zero-downtime blue-green re-encode (the old version keeps serving until it completes)."})]}),e.jsxs(N,{className:"space-y-3",children:[pe&&e.jsx("div",{className:"p-3 bg-muted rounded text-sm text-muted-foreground",children:"Cancelled — no further batches will be queued. Transcodes already staged keep running to completion."}),e.jsx(se,{className:"h-2",value:Oe}),e.jsxs("p",{className:"text-sm text-muted-foreground",children:[i.data.queued," / ",i.data.total," queued ·"," ",i.data.pending," remaining",i.data.nextBatchAt&&!_&&e.jsx(Ns,{at:i.data.nextBatchAt})]}),i.data.outcomes.length>0&&e.jsx("div",{className:"border rounded-lg overflow-hidden max-h-80 overflow-y-auto",children:e.jsxs(ae,{children:[e.jsx(te,{children:e.jsxs(S,{children:[e.jsx(u,{children:"Title"}),e.jsx(u,{children:"Action"}),e.jsx(u,{children:"Status"})]})}),e.jsx(ne,{children:i.data.outcomes.map(a=>e.jsxs(S,{children:[e.jsx(x,{className:"font-medium",children:a.title}),e.jsx(x,{className:"text-xs",children:a.action}),e.jsx(x,{className:"text-xs",children:e.jsxs("span",{className:a.status==="failed"?"text-red-600":a.status==="skipped"?"text-muted-foreground":"text-green-600",children:[a.status,a.reason?` (${a.reason})`:""]})})]},`${a.videoAssetId}-${a.action}`))})]})})]})]})]})}),e.jsx(ge,{open:Ee,onOpenChange:Q,children:e.jsxs(fe,{children:[e.jsxs(je,{children:[e.jsxs(ye,{children:["Relabel ",V.length," master playlist(s)?"]}),e.jsxs(be,{children:["Regenerates each non-HEVC ",e.jsx("code",{children:"master.m3u8"})," with accurate codec strings and purges the CDN, in batches of 10. The underlying video files are untouched; no re-encoding. Idempotent and safe to re-run. (HEVC + broken playlists use the separate throttled button.)"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx(L,{id:"apply-force",checked:le,onCheckedChange:a=>De(a===!0),disabled:I.isPending}),e.jsxs(w,{htmlFor:"apply-force",className:"font-normal leading-snug",children:["Re-parse codecs from B2 (ignore cache)",e.jsx("span",{className:"block text-xs text-muted-foreground",children:"Slower, but re-reads each fMP4 instead of trusting the cached codec string. Use if a previous run may have cached a wrong codec."})]})]}),e.jsxs(ve,{children:[e.jsx(Ce,{asChild:!0,disabled:I.isPending,children:e.jsx(l,{variant:"ghost",children:"Cancel"})}),e.jsxs(l,{onClick:$e,disabled:I.isPending,children:[I.isPending&&e.jsx(F,{className:"size-4"}),"Relabel (",V.length,")"]})]})]})}),e.jsx(ge,{open:Re,onOpenChange:K,children:e.jsxs(fe,{children:[e.jsxs(je,{children:[e.jsxs(ye,{children:["Re-encode ",J.length," HEVC + remux ",G.length," ","playlist(s)?"]}),e.jsxs(be,{children:["HEVC videos are re-encoded to H.264 (a new blue-green VideoAsset version — the live one keeps serving until the encode completes). Broken single-segment playlists are remuxed. This runs"," ",e.jsx("strong",{children:"5 at a time with a 20-minute delay between batches"})," ","to protect the encode pipeline, so it can take a while."]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx(L,{id:"heavy-dry-run",checked:Y,onCheckedChange:a=>Ve(a===!0),disabled:E.isPending}),e.jsxs(w,{htmlFor:"heavy-dry-run",className:"font-normal leading-snug",children:["Dry run (no encodes / no writes)",e.jsx("span",{className:"block text-xs text-muted-foreground",children:"Validates each asset and walks the batching cadence without staging versions or enqueuing encodes/remuxes."})]})]}),e.jsxs(ve,{children:[e.jsx(Ce,{asChild:!0,disabled:E.isPending,children:e.jsx(l,{variant:"ghost",children:"Cancel"})}),e.jsxs(l,{onClick:Be,disabled:E.isPending,children:[E.isPending&&e.jsx(F,{className:"size-4"}),"Start (",Z,")"]})]})]})})]})},Ks=()=>e.jsx(Fs,{});export{Ks as component};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.