1import{a as P,r as e,v as E,g as T}from"./chunk-CvM6EP8f.js";function V(){const a=T("_bb_track");if(!a)return null;try{return JSON.parse(a)}catch{return null}}function R(){const{t:a}=P(),[f,m]=e.useState("plate"),[p,S]=e.useState(""),[d,b]=e.useState("");e.useEffect(()=>{const o=new URLSearchParams(window.location.search).get("vin");o&&(b(o),m("vin"))},[]);const[h,g]=e.useState("CA"),[_,i]=e.useState(!1),[v,l]=e.useState("");return{type:f,setType:m,licensePlate:p,setLicensePlate:S,vin:d,setVin:b,state:h,setState:g,loading:_,validationError:v,setValidationError:l,handleSubmit:o=>{o?.preventDefault(),i(!0);let c=f==="plate",t=p.trim(),u=d.trim();if(t.length>7&&t.length>16&&(c=!1,u=t,t=""),!u&&!t){l(c?a("form.plateRequired")||"Please enter your license plate number":a("form.vinRequired")||"Please enter your VIN number"),setTimeout(()=>{i(!1)},1500);return}const y="https://seller.bidbus.com",s=new URLSearchParams;c?(s.set("plate",t),s.set("state",h)):s.set("vin",u);const n=V();if(n)for(const r of Object.keys(n)){if(!E(r))continue;const w=n[r];w&&s.set(r,String(w))}const k=`${y}/vehicles/new?${s.toString()}`;if(typeof window<"u"&&window.mixpanel&&n?.bb_platform){const r=[n.bb_platform,n.bb_ad].filter(Boolean).join("_");window.mixpanel.track("ui:c_goto_offer_from_home_m",{channel:r})}window.location.href=k,i(!1)}}}export{R as u};
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.