PageSourceSearch

https://pokee.ai/_next/static/chunks/86482.0bdec7518b9b40be.js

js pokee.ai collected 2026-09-24 21:52:20 UTC 8,195 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[86482],{46292:(e,t,a)=>{a.d(t,{t:()=>r});let r=async(e,t)=>{let a=(()=>{let e=document.cookie.match(/(^|;\s*)__csrf=([^;]*)/);return e?decodeURIComponent(e[2]):""})(),r=new Headers(null==t?void 0:t.headers);a&&r.set("X-CSRF-Token",a);let l=await fetch(e,{...t,headers:r});if(403===l.status)try{let e=await l.clone().json();if((null==e?void 0:e.error)==="CSRF token validation failed"){let e="/sign-in?redirect_url=".concat(encodeURIComponent(window.location.href));return window.location.href=e,new Promise(()=>{})}}catch(e){}return l}},48033:(e,t,a)=>{a.d(t,{S:()=>l});let r=new Set(["pokee.ai","dev.pokee.ai","localhost"]),l=e=>{if(!e)return null;let t=decodeURIComponent(e);if(t.startsWith("//")||"/"===t)return null;if(t.startsWith("/")&&!t.startsWith("//"))return/\\/.test(t)?null:t;try{let e=new URL(t);if("http:"!==e.protocol&&"https:"!==e.protocol)return null;let a=e.hostname;if(!r.has(a))return null;return e.pathname+e.search+e.hash}catch(e){return null}}},77979:(e,t,a)=>{a.d(t,{cn:()=>i});var r=a(2821),l=a(75889);function i(){for(var e=arguments.length,t=Array(e),a=0;a<e;a++)t[a]=arguments[a];return(0,l.QP)((0,r.$)(t))}},86292:(e,t,a)=>{a.d(t,{S:()=>l});var r=a(30926);let l=(0,r.createServerReference)("787a6f662a39d6951257e6f36023e53034315d4ce6",r.callServer,void 0,r.findSourceMapURL,"writeOnboardingSurveyToDB")},86482:(e,t,a)=>{a.r(t),a.d(t,{default:()=>_});var r=a(95155),l=a(94018),i=a(26497),s=a(49050),n=a(5917),o=a(15239),d=a(20063),c=a(51567),u=a(18955),p=a(12115),m=a(77979),h=a(46292),x=a(86292),b=a(48033),g=a(50457);let y=[{id:"founder",label:"Founder / Executive"},{id:"business",label:"Business / Operations"},{id:"marketing",label:"Marketing / Social Media"},{id:"developer",label:"Developer / Engineer"},{id:"researcher",label:"Researcher / Analyst"},{id:"it_security",label:"IT / Data / Security"},{id:"creator",label:"Content Creator"},{id:"student",label:"Student"},{id:"other",label:"Other"}],f=[{id:"myself",label:"Just for myself"},{id:"team",label:"With my team"},{id:"company",label:"Evaluating for my company"}],k=[{id:"1-10",label:"1-10"},{id:"11-50",label:"11-50"},{id:"51-500",label:"51-500"},{id:"500+",label:"500+"}];g.nP5,g._eB,g.VS1,g.CZR,g.MDe,g.unz,g.Vif,g.D6W,g.rcE,g.toy,g.d58,g.KVB,g.vIh,g.lhl,g.f7_,g.JaC,g.i4$,g.UYi,g.$lo,g.zEg,g.LF7,g.fG9,g.U_4,g.SrF,g.k4g,g.yTU,g.ogR,g.lLb;let v=["Google Search","LinkedIn","X/Twitter","Rednote","Instagram","Youtube","TikTok","Pinterest","Reddit","Friend or Colleague","Blog or Article","Other"];g.nP5,g._eB,g.VS1,g.CZR,g.MDe,g.unz,g.Vif,g.D6W,g.rcE,g.toy,g.KVB,g.lhl,g.d58,g.vIh,g.f7_,g.JaC,g.UKz,g.zR6,g.SrF,g.i4$,g.UYi,g.$lo,g.T8Q;let j=e=>"flex items-center gap-2.5 rounded-xl border px-4 py-3 text-left text-sm font-medium transition-all ".concat(e?"border-purple-400 bg-purple-50 text-purple-700 dark:border-purple-500 dark:bg-purple-950/40 dark:text-purple-300":"border-gray-200 bg-white text-gray-700 hover:border-gray-300 hover:bg-gray-50 dark:border-pokee-gray dark:bg-pokee-black dark:text-gray-300 dark:hover:border-gray-600 dark:hover:bg-pokee-dark-h
1over");function _(){let e=(0,d.useRouter)(),t=(0,d.useSearchParams)(),a=(0,c.Ym)(),g=(0,u.c)("Onboarding"),{user:_}=(0,l.Jd)(),[w,N]=(0,p.useState)(""),[S,C]=(0,p.useState)(""),[R,z]=(0,p.useState)(""),[O,E]=(0,p.useState)(""),[F,P]=(0,p.useState)(""),[T,U]=(0,p.useState)(!1),A="team"===S||"company"===S,D="Other"===O?F.trim()?"Other: ".concat(F.trim()):"":O,I=(()=>{try{return(0,b.S)(t.get("redirect_url"))}catch(e){return null}})(),B=async()=>{var t;if(!_||!S)return;U(!0);let r={role:w||"other",use_cases:[],tools:[],communication_style:"balanced",usage_context:S,company_size:A?R:"",completed_at:Date.now()};D&&(null==(t=_.primaryEmailAddress)?void 0:t.emailAddress)&&(0,x.S)(_.id,_.primaryEmailAddress.emailAddress,D,Date.now()).catch(e=>console.error("[onboarding] Failed to save survey:",e)),(0,h.t)("/api/onboarding-profile",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({userId:_.id,role:r.role,usage_context:r.usage_context,company_size:r.company_size,use_cases:r.use_cases,referral_source:D})}).catch(e=>console.error("[onboarding] Failed to sync profile:",e));try{await _.update({unsafeMetadata:{..._.unsafeMetadata,onboarding:r}})}catch(e){console.error("[onboarding] Failed to save preferences:",e),U(!1)}e.push(null!=I?I:"/".concat(a,"/pokeeclaw"))};return(0,r.jsx)("div",{className:"font-gabarito flex min-h-screen flex-col bg-white dark:bg-pokee-black",children:(0,r.jsxs)("div",{className:"mx-auto flex w-full max-w-3xl flex-1 flex-col px-4 py-8 md:px-8 md:py-12",children:[(0,r.jsxs)("div",{className:"flex flex-col items-center space-y-3 pb-8 text-center",children:[(0,r.jsx)(o.default,{src:"/pokee-circle.png",alt:"Pokee",width:56,height:56,className:"size-14",priority:!0}),(0,r.jsx)("h1",{className:"text-2xl font-medium tracking-tight text-gray-900 dark:text-white md:text-3xl",children:g("welcome")}),(0,r.jsx)("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:g("welcome_role_subtitle")})]}),(0,r.jsxs)("section",{className:"pb-8","aria-labelledby":"onboarding-role-title",children:[(0,r.jsx)("h2",{id:"onboarding-role-title",className:"pb-3 text-sm font-medium text-gray-700 dark:text-gray-300",children:g("role_title")}),(0,r.jsx)("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:y.map(e=>(0,r.jsxs)("button",{type:"button",onClick:()=>N(w===e.id?"":e.id),"aria-pressed":w===e.id,className:j(w===e.id),children:[w===e.id&&(0,r.jsx)(n.A,{className:"size-4 shrink-0 text-purple-600 dark:text-purple-400"}),(0,r.jsx)("span",{children:g("roles.".concat(e.id))})]},e.id))})]}),(0,r.jsxs)("section",{className:"pb-8","aria-labelledby":"onboarding-usage-title",children:[(0,r.jsx)("h2",{id:"onboarding-usage-title",className:"pb-3 text-sm font-medium text-gray-700 dark:text-gray-300",children:g("usage_title")}),(0,r.jsx)("div",{className:"flex flex-col gap-3",children:f.map(e=>(0,r.jsxs)("button",{type:"button",onClick:()=>C(e.id),"aria-pressed":S===e.id,className:j(S===e.id),children:[S===e.id&&(0,r.jsx)(n.A,{className:"size-4 shrink-0 text-purple-600 dark:text-purple-400"}),(0,r.jsx)("span",{children:g("usage.".concat(e.id))})]},e.id))}),(0,r.jsx)(i.N,{initial:!1,children:A&&(0,r.jsxs)(s.P.div,{initial:{opacity:0,y:6},animate:{opacity:1,y:0},exit:{opacity:0,y:6},transition:{duration:.2},className:"pt-4",children:[(0,r.jsx)("p",{className:"pb-2 text-sm font-medium text-gray-700 dark:text-gray-300",children:g("size_label")}),(0,r.jsx)("div",{className:"grid grid-cols-4 gap-2",children:k.map(e=>(0,r.jsx)("button",{type:"button",onClick:()=>z(R===e.id?"":e.id),"aria-pressed":R===e.id,className:"".concat(j(R===e.id)," justify-center"),children:(0,r.jsx)("span",{children:e.label})},e.id))})]},"company-size")})]}),(0,r.jsxs)("section",{className:"pb-8","aria-labelledby":"onboarding-referral-title",children:[(0,r.jsx)("h2",{id:"onboarding-referral-title",className:"pb-3 text-sm font-medium text-gray-700 dark:text-gray-300",children:g("referral_source")}),(0,r.jsx)("div",{className:"grid grid-cols-2 gap-2 sm:grid-cols-4",children:v.map(e=>(0,r.jsx)("button",{type:"button",onClick:()=>{E(O===e?"":e),"Other"!==e&&P("")},"aria-pressed":O===e,className:(0,m.cn)(j(O===e),"justify-center px-3 py-2.5"),
1children:(0,r.jsx)("span",{children:e})},e))}),"Other"===O&&(0,r.jsx)("input",{type:"text",value:F,onChange:e=>P(e.target.value),placeholder:"Please specify...","aria-label":"Other source",className:"mt-3 w-full rounded-xl border border-gray-200 bg-white px-4 py-2.5 text-sm text-gray-900 transition-colors focus:border-purple-400 focus:outline-none dark:border-pokee-gray dark:bg-pokee-black dark:text-white dark:focus:border-purple-500"})]}),(0,r.jsx)("div",{className:"mt-auto flex justify-end",children:(0,r.jsx)("button",{type:"button",onClick:B,disabled:!(S&&!T),className:"flex h-10 items-center gap-1 rounded-xl bg-black px-6 text-sm font-medium text-white shadow-sm transition-transform hover:scale-105 active:scale-95 disabled:pointer-events-none disabled:opacity-50 dark:bg-white dark:text-black",children:T?g("setting_up"):g("start")})})]})})}}}]);

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.