PageSourceSearch

https://meetborderless.com/build/assets/index-B2KUuQgI.js

js meetborderless.com collected 2026-10-09 22:41:46 UTC 6,637 bytes, 1 lines download raw bytes

1import{j as e}from"./app-C1iegf7Q.js";import{b as x,H as u,L as i,f as p}from"./inertia-BpyZy4w-.js";import{A as g}from"./attention-queue-TvkG8LXl.js";import{a as j}from"./admin-layout-BhXWbUlP.js";import{j as m}from"./journey-labels-D75PCX0v.js";import{S as y}from"./search-BY9GDMxP.js";import{S as N}from"./send-COySMMwK.js";/* empty css            */import"./app-logo-Dz0wogSq.js";import"./logo-light-DU4bWymm.js";import"./flash-toast-C6O0iVL1.js";import"./createLucideIcon-wqc1LSWg.js";import"./info-D2ZN_yLm.js";import"./triangle-alert-C7AVwNi-.js";import"./circle-x-Bp6Mbpgt.js";import"./circle-check-BMWvzPMx.js";import"./x-DQSeRCcH.js";import"./arrow-left-DCX0fhKH.js";import"./menu-BR3Nc3Gr.js";import"./users-BCcupCXV.js";import"./folder-open-I72SPUVk.js";import"./pound-sterling-D16GLaAZ.js";import"./book-open-DVFlG_9t.js";const k={discovery:"Discovery",planning:"Planning",drafting:"Drafting",signoff:"Sign-off"};function Q({attention:n,cases:a,filters:s}){const l=!!(s.journey||s.stage||s.status||s.open),[r,o]=x.useState(s.tab==="all"||l?"all":"attention"),[d,c]=x.useState(s.search??""),h=t=>{t.preventDefault(),p.get("/admin/cases",{search:d||void 0,tab:"all"},{preserveState:!0,replace:!0})};return e.jsxs(j,{children:[e.jsx(u,{title:"Cases · Admin"}),e.jsxs("div",{className:"px-6 py-8 max-w-5xl",children:[e.jsxs("div",{className:"mb-6",children:[e.jsx("h1",{className:"text-xl font-semibold text-ink",children:"Cases"}),e.jsx("p",{className:"mt-1 text-sm text-ink-3",children:"Follow-ups first, then every case. Open one to assign, sign off, or confirm payment."})]}),e.jsxs("div",{className:"mb-5 flex gap-1 border-b border-line",children:[e.jsxs("button",{type:"button",onClick:()=>o("attention"),className:`-mb-px border-b-2 px-3 py-2 text-sm font-medium ${r==="attention"?"border-ink text-ink":"border-transparent text-ink-3 hover:text-ink-2"}`,children:["Needs attention",n.length>0&&e.jsx("span",{className:"ml-1.5 rounded-tag bg-red/10 px-1.5 py-0.5 text-2xs font-semibold text-red",children:n.length})]}),e.jsxs("button",{type:"button",onClick:()=>o("all"),className:`-mb-px border-b-2 px-3 py-2 text-sm font-medium ${r==="all"?"border-ink text-ink":"border-transparent text-ink-3 hover:text-ink-2"}`,children:["All cases",e.jsx("span",{className:"ml-1.5 text-2xs text-ink-3",children:a.total})]})]}),r==="attention"?e.jsx(g,{items:n}):e.jsxs("div",{children:[e.jsxs("form",{onSubmit:h,className:"mb-4 flex items-center gap-2",children:[e.jsxs("div",{className:"relative flex-1 max-w-sm",children:[e.jsx(y,{className:"absolute left-2.5 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-ink-3"}),e.jsx("input",{value:d,onChange:t=>c(t.target.value),placeholder:"Search by name or email",className:"w-full rounded-md border border-line bg-white py-1.5 pl-8 pr-3 text-sm text-ink placeholder:text-ink-3 focus:border-line-strong focus:outline-none"})]}),e.jsx("button",{type:"submit",className:"rounded-md border border-line bg-white px-3 py-1.5 text-sm text-ink-2 hover:border-line-strong",children:"Search"}),e.jsxs(i,{href:`/admin/broadcasts/create?audience=cases&case_status=active${s.journey?`&journeys=${encodeURIComponent(s.journey)}`:""}`,className:"ml-auto flex items-center gap-1.5 rounded-md bg-ink px-3 py-1.5 text-sm text-white hover:bg-ink-2",children:[e.jsx(N,{className:"h-3.5 w-3.5"}),"Message these clients"]})]}),l&&e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-1.5",children:[e.jsx("span",{className:"text-2xs font-bold uppercase tracking-eyebrow text-ink-3",children:"Showing"}),s.journey&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-2 py-0.5 text-xs text-ink-2",children:m(s.journey==="founder"?"innovator_founder":s.journey)}),s.stage&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-2 py-0.5 text-xs text-ink-2",children:k[s.stage]??s.stage}),s.status&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-2 py-0.5 text-xs text-ink-2",children:s.status}),s.open&&!s.stage&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-2 py-0.5 text-xs text-ink-2",children:"Still open"}),e.jsx(i,{href:"/admin/cases?tab=all",className:"text-xs text-ink-3 hover:text-ink",children:"Clear"})]}),e.jsx("div",{className:"overflow-hidden rounded-card border border-line bg-white",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"border-b border-line text-left text-2xs uppercase tracking-eyebrow text-ink-3",children:[e.jsx("th",{className:"px-4 py-2.5 font-semibold",children:"Applicant"}),e.jsx("th",{className:"px-4 py-2.5 font-semibold",children:"Journey"}),e.jsx("th",{className:"px-4 py-2.5 font-semibold",children:"Plan"}),e.jsx("th",{className:"px-4 py-2.5 font-semibold",children:"Specialist"}),e.jsx("th",{className:"px-4 py-2.5 font-semibold",children:"Opened"})]})}),e.jsxs("tbody",{children:[a.data.map(t=>e.jsxs("tr",{className:"cursor-pointer border-b border-line last:border-0 hover:bg-bg",onClick:()=>p.get(`/admin/cases/${t.uuid}`),children:[e.jsxs("td",{className:"px-4 py-2.5",children:[e.jsx("div",{className:"font-medium text-ink",children:t.applicant.name}),e.jsx("div",{className:"text-xs text-ink-3",children:t.applicant.email})]}),e.jsx("td",{className:"px-4 py-2.5 text-ink-2",children:m(t.journey_type)}),e.jsx("td",{className:"px-4 py-2.5",children:e.jsxs("div",{className:"flex items-center gap-1.5",children:[t.plan_involvement==="self"&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-1.5 py-0.5 text-2xs text-ink-2",children:"Self-paced"}),t.plan_involvement==="backed"&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-1.5 py-0.5 text-2xs text-ink-2",children:"Specialist-backed"}),t.plan_involvement==="led"&&e.jsx("span",{className:"rounded-tag bg-bg-2 px-1.5 py-0.5 text-2xs text-ink-2",children:"Specialist-led"}),!t.is_paid&&e.jsx("span",{className:"rounded-tag bg-amber/12 px-1.5 py-0.5 text-2xs font-medium text-amber-ink",children:"Unpaid"})]})}),e.jsx("td",{className:"px-4 py-2.5",children:t.specialist?e.jsx("span",{className:"text-ink-2",children:t.specialist.name}):e.jsx("span",{className:"text-red",children:"Unassigned"})}),e.jsx("td",{className:"px-4 py-2.5 text-ink-3",children:t.created_at})]},t.uuid)),a.data.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"px-4 py-8 text-center text-ink-3",children:"No cases match."})})]})]})}),a.links.length>3&&e.jsx("div",{className:"mt-4 flex flex-wrap gap-1",children:a.links.map((t,b)=>e.jsx(i,{href:t.url??"#",preserveState:!0,className:`rounded-md px-2.5 py-1 text-xs ${t.active?"bg-ink text-white":t.url?"text-ink-2 hover:bg-bg":"text-ink-3"}`,dangerouslySetInnerHTML:{__html:t.label}},b))})]})]})]})}export{Q 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.