1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6322],{19888:(e,t,r)=>{r.d(t,{C:()=>c});var a=r(37876),s=r(14232),n=r(87621),o=r(75917),l=r(45544),d=r(65870);r(77041),r(92188),r(59829);var i=r(48971);function c(e){let{value:t="",onChange:r,onBlur:c,placeholder:m="Company name or website",className:u="",error:p=!1,inputProps:f}=e,[x,h]=(0,s.useState)(""),[g,y]=(0,s.useState)(!1),w=(0,s.useRef)(null),N=(0,s.useRef)(null),[v,j]=(0,s.useState)([]),b=(0,o.d)(x,500),[k,B]=(0,s.useState)(!1);(0,s.useEffect)(()=>{(async()=>{if((null==b?void 0:b.length)<2)return j([]);B(!0);try{let e=await (0,l.eu)(b);j(e),y(!0)}catch(e){console.error("Error fetching company suggestions:",e),j([]),y(!1)}finally{B(!1)}})()},[b]),(0,s.useEffect)(()=>{let e=e=>{w.current&&!w.current.contains(e.target)&&y(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[]);let C=e=>{h(e.domain),y(!1),r(e.domain)};return(0,a.jsxs)("div",{className:"relative flex-1",ref:w,children:[(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)(i.p,{ref:N,value:x,onChange:e=>{r(e.target.value),h(e.target.value)},className:(0,d.cn)("pl-8",u,p?"border-red-500":""),placeholder:m,onFocus:()=>x.trim()&&y(!0),...f}),k&&(0,a.jsx)(n.A,{className:"absolute animate-spin right-3 top-3 text-muted-foreground w-6 h-6"})]}),g&&v.length>0&&(0,a.jsx)("div",{className:"absolute top-full left-0 right-0 mt-1 bg-white border border-gray-200 rounded-lg shadow-lg z-10 max-h-60 overflow-y-auto",children:v.map((e,t)=>(0,a.jsxs)("div",{className:"flex items-center justify-between p-3 hover:bg-gray-50 cursor-pointer border-b border-gray-100 last:border-b-0",onClick:()=>C(e),children:[(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[(0,a.jsx)("div",{className:"h-6 w-6 rounded bg-gray-100 flex items-center justify-center",children:(0,a.jsx)("span",{className:"text-xs font-medium text-gray-600",children:e.logo_url?(0,a.jsx)("img",{src:e.logo_url||"/placeholder.svg",alt:e.name,className:"h-full w-full object-contain"}):(0,a.jsx)("div",{className:"flex h-full w-full items-center justify-center rounded-full bg-gray-200",children:(0,a.jsx)("span",{className:"text-xs font-bold text-gray-500",children:e.name.charAt(0).toUpperCase()})})})}),(0,a.jsx)("span",{className:"font-medium text-sm",children:e.name})]}),(0,a.jsx)("span",{className:"text-sm text-muted-foreground",children:e.domain})]},t))})]})}},40053:(e,t,r)=>{r.d(t,{J:()=>i});var a=r(37876),s=r(14232),n=r(59773),o=r(47137),l=r(65870);let d=(0,o.F)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),i=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.b,{ref:t,className:(0,l.cn)(d(),r),...s})});i.displayName=n.b.displayName},45544:(e,t,r)=>{r.d(t,{R4:()=>a,eu:()=>s,fS:()=>n});let a=async(e,t)=>{let r=await fetch("/api/wp/email-finder",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json","x-captcha-token":t},credentials:"include",body:JSON.stringify(e)});if(!r.ok)throw Error((await r.json()).error||"[EmailFinder] http ".concat(r.status," error"));return await r.json().catch(()=>{})},s=async e=>{let t=await fetch("/api/wp/company-finder?kw=".concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json"},credentials:"include"});return await t.json().catch(()=>{})},n=async(e,t)=>{let r=await fetch("/api/wp/email-verifier",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json","x-captcha-token":t},credentials:"include",body:JSON.stringify({email:e})});if(!r.ok)throw Error((await r.json()).error||"[EmailVerifier] http ".concat(r.status," error"));return await r.json().catch(()=>{})}},92188:(e,t,r)=>{r.d(t,{G7:()=>i,L$:()=>u,fx:()=>p,h_:()=>f,oI:()=>c,uB:()=>d,xL:()=>m});var a=r(37876),s=r(14232),n=r(58687),o=r(65870);r(92161);var l=r(5259);let d=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.uB,{ref:t,className:(0,o.cn)("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",r),...s})});d.displayName=n.uB.displayName;let i=s.forwardRef((e,t)=>
1{let{className:r,...s}=e;return(0,a.jsxs)("div",{className:"flex items-center border-b px-3 border rounded-md","cmdk-input-wrapper":"",children:[(0,a.jsx)(l.$p$,{className:"mr-1 h-4 w-4 shrink-0 opacity-50"}),(0,a.jsx)(n.uB.Input,{ref:t,className:(0,o.cn)("flex h-10 w-full border-0 focus:ring-0 rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",r),...s})]})});i.displayName=n.uB.Input.displayName;let c=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.uB.List,{ref:t,className:(0,o.cn)("max-h-[300px] overflow-y-auto overflow-x-hidden",r),...s})});c.displayName=n.uB.List.displayName;let m=s.forwardRef((e,t)=>(0,a.jsx)(n.uB.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));m.displayName=n.uB.Empty.displayName;let u=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.uB.Group,{ref:t,className:(0,o.cn)("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",r),...s})});u.displayName=n.uB.Group.displayName;let p=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.uB.Separator,{ref:t,className:(0,o.cn)("-mx-1 h-px bg-border",r),...s})});p.displayName=n.uB.Separator.displayName;let f=s.forwardRef((e,t)=>{let{className:r,...s}=e;return(0,a.jsx)(n.uB.Item,{ref:t,className:(0,o.cn)("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",r),...s})});f.displayName=n.uB.Item.displayName},95679:(e,t,r)=>{r.d(t,{C5:()=>h,MJ:()=>x,eI:()=>f,lV:()=>i,zB:()=>m});var a=r(37876),s=r(14232),n=r(82987),o=r(88992),l=r(65870),d=r(40053);let i=o.Op,c=s.createContext({}),m=e=>{let{...t}=e;return(0,a.jsx)(c.Provider,{value:{name:t.name},children:(0,a.jsx)(o.xI,{...t})})},u=()=>{let e=s.useContext(c),t=s.useContext(p),{getFieldState:r,formState:a}=(0,o.xW)(),n=r(e.name,a);if(!e)throw Error("useFormField should be used within <FormField>");let{id:l}=t;return{id:l,name:e.name,formItemId:"".concat(l,"-form-item"),formDescriptionId:"".concat(l,"-form-item-description"),formMessageId:"".concat(l,"-form-item-message"),...n}},p=s.createContext({}),f=s.forwardRef((e,t)=>{let{className:r,...n}=e,o=s.useId();return(0,a.jsx)(p.Provider,{value:{id:o},children:(0,a.jsx)("div",{ref:t,className:(0,l.cn)("space-y-2",r),...n})})});f.displayName="FormItem",s.forwardRef((e,t)=>{let{className:r,...s}=e,{error:n,formItemId:o}=u();return(0,a.jsx)(d.J,{ref:t,className:(0,l.cn)(n&&"text-destructive",r),htmlFor:o,...s})}).displayName="FormLabel";let x=s.forwardRef((e,t)=>{let{...r}=e,{error:s,formItemId:o,formDescriptionId:l,formMessageId:d}=u();return(0,a.jsx)(n.DX,{ref:t,id:o,"aria-describedby":s?"".concat(l," ").concat(d):"".concat(l),"aria-invalid":!!s,...r})});x.displayName="FormControl",s.forwardRef((e,t)=>{let{className:r,...s}=e,{formDescriptionId:n}=u();return(0,a.jsx)("p",{ref:t,id:n,className:(0,l.cn)("text-[0.8rem] text-muted-foreground",r),...s})}).displayName="FormDescription";let h=s.forwardRef((e,t)=>{let{className:r,children:s,...n}=e,{error:o,formMessageId:d}=u(),i=o?String(null==o?void 0:o.message):s;return i?(0,a.jsx)("p",{ref:t,id:d,className:(0,l.cn)("text-[0.8rem] font-medium text-destructive",r),...n,children:i}):null});h.displayName="FormMessage"}}]);
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.