1import{r,j as e,v as j,s as d}from"./index-CGIDmj67.js";import{T as f,a as b,b as u,c as m}from"./tabs-FhChMlIY.js";import{E as N,T as a}from"./E2FieldLabel-vHxY3phK.js";import"./index-Pj26H1in.js";const _=()=>{const[l,p]=r.useState([]),[n,h]=r.useState([]),[x,g]=r.useState(!0);if(r.useEffect(()=>{(async()=>{const[{data:t},{data:s}]=await Promise.all([d.from("e2_review_queue").select("*").eq("entity_type","segment").order("priority",{ascending:!1}).limit(100),d.from("e2_review_queue").select("*").eq("entity_type","clip").order("priority",{ascending:!1}).limit(100)]);p(t||[]),h(s||[]),g(!1)})()},[]),x)return e.jsx("div",{className:"flex justify-center py-12",children:e.jsx(j,{className:"w-6 h-6 animate-spin"})});const c=(i,t)=>i.length===0?e.jsxs("p",{className:"text-muted-foreground p-8 text-center",children:["No ",t,"s in review queue."]}):e.jsx("div",{className:"bg-card border border-border overflow-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"border-b border-border text-left text-muted-foreground",children:[e.jsx(a,{className:"p-3",tooltip:`Internal ID of the ${t} flagged for review.`,children:"Entity ID"}),e.jsx(a,{className:"p-3",tooltip:"Why this item entered the queue â low score, sensitive content, name detected, force-through pending, etc.",children:"Reason"}),e.jsx(a,{className:"p-3",tooltip:"Higher = handle sooner. Set by engine policy or admin escalation.",children:"Priority"}),e.jsx(a,{className:"p-3",tooltip:"pending = awaiting decision. approved/rejected = resolved.",children:"Status"}),e.jsx("th",{className:"p-3",children:"Created"})]})}),e.jsx("tbody",{children:i.map(s=>{var o;return e.jsxs("tr",{className:"border-b border-border hover:bg-muted/30",children:[e.jsxs("td",{className:"p-3 font-mono text-xs",children:[(o=s.entity_id)==null?void 0:o.slice(0,8),"â¦"]}),e.jsx("td",{className:"p-3",children:s.queue_reason||"â"}),e.jsx("td",{className:"p-3",children:s.priority}),e.jsx("td",{className:"p-3",children:s.status}),e.jsx("td",{className:"p-3 text-xs",children:s.created_at?new Date(s.created_at).toLocaleDateString():"â"})]},s.id)})})]})});return e.jsx(N,{children:e.jsxs("div",{className:"space-y-6",children:[e.jsx("p",{className:"text-muted-foreground text-sm",children:"Approve, reject, or force-through segments and clips"}),e.jsxs(f,{defaultValue:"segments",children:[e.jsxs(b,{children:[e.jsxs(u,{value:"segments",children:["Segments (",l.length,")"]}),e.jsxs(u,{value:"clips",children:["Clips (",n.length,")"]})]}),e.jsx(m,{value:"segments",className:"mt-4",children:c(l,"segment")}),e.jsx(m,{value:"clips",className:"mt-4",children:c(n,"clip")})]})]})})};export{_ as default};
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.