PageSourceSearch

https://claritypledge.com/assets/p1336-onboarding-prototype-BJoL91Hb.js

js claritypledge.com collected 2026-10-04 08:05:55 UTC 44,637 bytes, 1 lines download raw bytes

1import{j as e,k as Dt,a as Lt,u as Ot,r,S as Je,aR as S,dD as f,aT as $t,_ as Ke,dw as R,aa as Bt,ek as Qe,B as O,af as Mt,ag as Ht,ah as Yt,ai as Wt,aj as zt,cE as pt,cF as Ue,ba as ve,c_ as qt,c$ as Gt,d0 as Vt,d1 as Ft,d8 as Jt,d2 as Kt,el as Qt,t as Ut,cM as Xt,em as Zt}from"./index-CIW48_iC.js";import{M as es}from"./mp4-video-facade-D6jHtcy8.js";import{L as Xe}from"./letter-progress-bar-N6pgTQqs.js";import{StakePage as ts}from"./stake-page-OTDNV4f5.js";import{A as ss,W as mt,T as ns}from"./AddToCalendarMenu-zMciRZAl.js";import{A as as,M as xt}from"./AttendeeAvatarStack-BLyHnR8N.js";import{A as rs}from"./arrow-left-SPVKigz5.js";import{C as is}from"./circle-check-D_0hNxCP.js";import{L as os}from"./link-2-GIoJziNU.js";import"./video-Cs7_d-X3.js";import"./story-video-player-DVVGqirH.js";import"./stories-service-C9Ir1EJ2.js";import"./offline-reads-Bqyz6s4Y.js";import"./use-offline-read-state-DYAM7rLf.js";import"./linked-content-ULTxuHni.js";import"./ear-badge-G7T6dvIQ.js";import"./mobile-tooltip-DEqw3AcN.js";import"./tooltip-C-GtX8Bo.js";import"./ear-3WfrC-H4.js";import"./understood-badge-CCxRHkbw.js";import"./story-quotes-C6PuyIVz.js";import"./index-doYKOn6n.js";import"./position-labels-CQeCGomu.js";import"./circle-help-D5Hec_fc.js";import"./trash-2-BuU6v33D.js";import"./video-summaries-service-BeiCwogd.js";import"./visibility-badge-BNxOMBr0.js";import"./globe-fPtP9QGw.js";import"./use-lazy-story-player-CiCXOIcp.js";import"./group-by-source-epJqzLg7.js";import"./pin-BQO694NT.js";import"./point-card-with-links-CDfs9P96.js";import"./ShareDialog-CKks90RV.js";import"./copy-BZTUMlg8.js";import"./share-2-BvyABoCZ.js";import"./card-action-classes-CSn1B9XS.js";import"./ellipsis-n1o2JB1P.js";import"./pencil-DR2VoUy-.js";import"./external-link-DqruoPSz.js";import"./use-online-write-guard-DVxRbKXF.js";import"./remove-position-dialog-BLMRS7qH.js";import"./seo-B5wf2iAK.js";import"./focus-header-tKaJJzE1.js";import"./bottom-back-button-Ii8QnPOq.js";import"./location-utils-CeMejZAx.js";import"./download-D7qg-nYM.js";import"./person-avatar-DBadG5xj.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};t.SENTRY_RELEASE={id:"0f5b13aa709d44872c7ab6a82bb77dc7ba4052f5"}}catch{}})();try{(function(){var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new t.Error().stack;
1n&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[n]="92155477-26f2-43ab-985b-86435ebc90fa",t._sentryDebugIdIdentifier="sentry-dbid-92155477-26f2-43ab-985b-86435ebc90fa")})()}catch{}const Ze={sent:{label:"Sent",className:"bg-gray-100 text-gray-600"},opened:{label:"Opened",className:"bg-blue-50 text-blue-600"},in_progress:{label:"In Progress",className:"bg-blue-50 text-blue-600"},completed:{label:"Completed",className:"bg-green-50 text-green-700"}};function et({status:t,label:n}){const o=Ze[t]??Ze.sent;return e.jsx("span",{className:`inline-flex items-center px-2.5 py-1 rounded-full text-xs font-medium ${o.className}`,children:n??o.label})}const g={title:"Clarity Night #2",dateLabel:"Tue 6 Oct",timeLabel:"19:00 – 21:30 [mock]",location:"[mock venue]",topic:"AI and your ikigai"},ls="M19.365 9.863c.349 0 .63.285.63.631 0 .345-.281.63-.63.63H17.61v1.125h1.755c.349 0 .63.283.63.63 0 .344-.281.629-.63.629h-2.386c-.345 0-.627-.285-.627-.629V8.108c0-.345.282-.63.63-.63h2.386c.346 0 .627.285.627.63 0 .349-.281.63-.63.63H17.61v1.125h1.755zm-3.855 3.016c0 .27-.174.51-.432.596-.064.021-.133.031-.199.031-.211 0-.391-.09-.51-.25l-2.443-3.317v2.94c0 .344-.279.629-.631.629-.346 0-.626-.285-.626-.629V8.108c0-.27.173-.51.43-.595.06-.023.136-.033.194-.033.195 0 .375.104.495.254l2.462 3.33V8.108c0-.345.282-.63.63-.63.345 0 .63.285.63.63v4.771zm-5.741 0c0 .344-.282.629-.631.629-.345 0-.627-.285-.627-.629V8.108c0-.345.282-.63.63-.63.346 0 .628.285.628.63v4.771zm-2.466.629H4.917c-.345 0-.63-.285-.63-.629V8.108c0-.345.285-.63.63-.63.348 0 .63.285.63.63v4.141h1.756c.348 0 .629.283.629.63 0 .344-.282.629-.629.629M24 10.314C24 4.943 18.615.572 12 .572S0 4.943 0 10.314c0 4.811 4.27 8.842 10.035 9.608.391.082.923.258 1.058.59.12.301.079.766.038 1.08l-.164 1.02c-.045.301-.24 1.186 1.049.645 1.291-.539 6.916-4.078 9.436-6.975C23.176 14.393 24 12.458 24 10.314",ds="M9.101 23.691v-7.98H6.627v-3.667h2.474v-1.58c0-4.085 1.848-5.978 5.858-5.978.401 0 .955.042 1.468.103a8.68 8.68 0 0 1 1.141.195v3.325a8.623 8.623 0 0 0-.653-.036 26.805 26.805 0 0 0-.733-.009c-.707 0-1.259.096-1.675.309a1.686 1.686 0 0 0-.679.622c-.258.42-.374.995-.374 1.752v1.297h3.919l-.386 2.103-.287 1.564h-3.246v8.245C19.396 23.238 24 18.179 24 12.044c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.628 3.874 10.35 9.101 11.647Z",cs=(t,n)=>{const o=encodeURIComponent(t),i=encodeURIComponent(`${n} ${t}`);return[{name:"LINE",glyph:ls,href:`https://line.me/R/msg/text/?${i}`},{name:"WhatsApp",glyph:mt,href:`https://wa.me/?text=${i}`},{name:"Telegram",glyph:ns,href:`https://t.me/share/url?url=${o}&text=${encodeURIComponent(n)}`},{name:"Facebook",glyph:ds,href:`https://www.facebook.com/sharer/sharer.php?u=${o}`}]},tt="/founder-photo.jpg",us="https://chat.whatsapp.com/example-invite-p1336",ft={id:"event-id-p1336",title:g.title,description:"Clarity Night",location:g.location,slug:"clarity-night-2-ai-and-your-ikigai-sinek-tan-naval-watts-and-brooks-2026-10-06-ijjx",startDate:new Date("2026-10-06T19:00:00"),endDate:new Date("2026-10-06T21:30:00")},st=`${window.location.origin}/events/${ft.slug}`,nt="/p1336-clips",at=`v=${Date.now()}`,we={welcome:{name:"why-clarity-night",seconds:139.4,label:"Play the How we are different video",rate:1.15},story:{name:"cognitive-understanding",seconds:84.4,label:"Play the cognitive understanding video",rate:1.15},principle:{name:"principle",seconds:50.03,label:"Play the principle video",rate:1.15},research:{name:"research-recording",seconds:60.13,label:"Play the recording video",rate:1.15}},V=t=>Math.round(we[t].seconds/we[t].rate),hs={welcome:["So when I invited people to this event, I got some rejections, and I asked for feedback. Generally speaking, people don't come to public discussions about global things because they think it's a waste of time.","It's because of these three things. First, people have monologues and don't listen to each other. Second, disagreements split the room, and nobody learns anything. And last but not least, at some point, if events are repeating, people just agree, for example, with the host, or hate the host.","If you say, how come, what is the crux? Why is it that discussions are not meaningful, or unproductive, or not effective, in public discu
1ssions like the one we will have today, or in personal discussions, or professional meetings? I suggest one of the main reasons is a social norm. In many social environments, admitting that you don't understand cognitively, revealing that there is a gap in understanding, is not tolerated, usually punished, because people think: oh, so what are you saying, you're stupid? Or didn't you pay attention?","And if we reflect on how it affects the dynamic of the discussion: if we don't reveal the gap, we cannot bridge the gap. And I suggest that all of the things I said at the beginning, why people have bad discussions, not meaningful discussions, can be traced to this reason. So today, it's part of the experiment, meaning I developed some tools to see if I can help create this environment, where it's rewarding to reveal the gap in cognitive understanding, so we can bridge it and have a more meaningful discussion, so we can learn from each other."],story:["Now, I tell you quickly the story. This is a person I love, and we had a conflict. And I wanted, because of my focus, I wanted to verify that I understand her. So I repeated back, I explained back, I said, is that what you meant? And she told me, yes, that's what I mean. That's what I mean. And after a few days, the conflict escalated and she wrote me, I don't want to speak to you anymore, because I didn't feel understood.","So is it a lie, a memory issue, or a misunderstanding? Empirically, I found that the word understanding has three meanings. One, there are people who will say, you don't understand me until you agree. Okay, this is how you know: when they say you don't understand me, or you understand me, they mean agreement. Other people, they mean you don't feel what I feel. This is emotional understanding.","Cognitive understanding means I repeat back your intended meaning, and then I ask you from zero to 10, how much do you think I understand you? Or you ask me how much I understand you. And if it's 10, if we both say 10, then we verified, we know exactly that I understood you, right? Because we verified. We might still disagree, and I might not feel what you feel, but we know that I have exactly the mental model that you have."],principle:["This is a lot of text, but the text is not the important thing. It's super simple, it has three parts. I will introduce it. It's a Clarity Meeting Principle, I call it that, and then you can either opt in or opt out. Both are completely fine.","So what is it? There is your right, my promise, and the exception. Basically, it says we allow each other to ask one specific question. The other person promises to answer. If you opt in, you promise to answer that question. If you, for some very specific reason, cannot answer, you explain why.","The question is: how much, from 0 to 10, do you think you understand me cognitively?"],research:["So this is optional. If there are volunteers, then I'd like to suggest that I have microphones. Because there will be discussions, and for me it would be helpful for research and development to take the context of your discussion, analyze it with AI, and see if I can improve for the next event, and also personalize the experience for the future, if you opt into this. And if you don't like it, I can always delete the file.","So we will have discussions with each other in pairs. And when you have a discussion, if both of you are part of this, then you are both being recorded, and it's diarized, so we identify you as the speakers. And I will use the context of your discussion, which I cannot hear, I cannot be there, to see if I'm actually succeeding to create these meaningful discussions, or maybe not."]};function ps({clip:t}){const[n,o]=r.useState(!1),i=`transcript-${t}`;return e.jsxs("div",{"data-testid":i,children:[e.jsxs("button",{type:"button",onClick:()=>o(c=>!c),"aria-expanded":n,"aria-controls":`${i}-text`,className:"ml-auto flex h-10 w-fit items-center gap-1 text-sm text-blue-600 hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring dark:text-blue-400",children:[e.jsx(Xt,{className:"h-3.5 w-3.5 shrink-0","aria-hidden":"true"}),n?"Hide the transcript":"Read the transcript"]}),n&&e.jsx("div",{id:`${i}-text`,className:"mt-1 space-y-3 text-base leading-relaxed text-muted-foreground animate-in fade-in duration-300",children:hs[t].map(c=>e.jsx("p",{children:c},c.slice(0,32)))})]})}function te({clip:t,pulse:n=!1,onPlay:o,playRequest:i=0}){const{name:c,label:m,rate:p}=we[t],d=r.useRef(null);return r.useEffect(()=>{var l,y;i>0&&((y=(l=d.current)==null?void 0:l.querySelector("button"))==null||y.click())},[i]),e.jsxs("div",{children:[e.jsx("div",{ref:d,"data-testid":`clip-${t}`,children:e.jsx(es,{look:"story",src:`${nt}/${c}.mp4?${at}`,poster:`${nt}/${c}-poster.jpg?${at}`,posterAlt:t==="story"?"The cognitive understanding video":"Slava speaking at Clarity Night #1",playLabel:m,durationSeconds:V(t),pulse:n,onPlay:o,playbackRate:p})}),e.jsx(ps,{clip:t})]})}const D="ikigai1",be=["Simon Sinek","Garry Tan","Naval Ravikant","Alan Watts","Arthur Brooks"],F="cmp7",se=[F,D],rt=50,L=t=>
1!!t.userPosition||!!pt(t.id);function it({tag:t,points:n,askedIds:o,onPointsChanged:i,onCountChange:c}){const m=new Map(n.map(d=>[d.id,d])),p=o.filter(d=>{const l=m.get(d);return l?L(l):!!pt(d)}).length;return r.useEffect(()=>{c({answered:p,total:o.length})},[p,o.length,c]),e.jsx("div",{onClickCapture:()=>{setTimeout(i,400)},children:e.jsx(ts,{tag:t,embedded:!0,pointsOnly:!0,onlyIds:o,linksInNewTab:!0})})}const Ne=["Anna","Ben","Chiara","Dmitri","Elena","Farid","Greta"].map((t,n)=>({profileId:`profile-id-prepared-${n+1}`,name:t,slug:`prepared-${n+1}`,hasPledged:!1})),ms=12,xs=12,fs=1,gs=Ne.slice(0,5),bs=4,ys=6,ws=Math.max(1,bs),js="privacy AT claritypledge DOT com",vs=[{q:"Who sees the audio recording?",a:"All people who are part of the recorded conversation at the event. The event organiser analyses the conversation transcripts with AI for research, and doesn't listen to the audio."},{q:"Will my partner be recorded too?",a:"Your microphone is a directional lavalier microphone. It picks up mostly you, but it can record some background sound around you."},{q:"Can I ask you to delete my data?",a:e.jsxs(e.Fragment,{children:["Yes. Email us and we delete your recording and transcript."," ",e.jsxs("span",{className:"whitespace-nowrap",children:["(",js,")"]})]})}],Ns="https://github.com/slavochek2/claritypledge/blob/main/docs/research-programme.md",ks="How much do you think you understand Slava's intended meaning behind this principle?",gt=3,ae=["plan","welcome","story","principle","cmp7","stake","research"],E=t=>!!t&&ae.includes(t),b=[{label:"See how this event is different",steps:["welcome"]},{label:"Learn the definition of cognitive understanding",steps:["story"]},{label:"Decide about your participation in a new social norm",steps:["principle"]},{label:"Share your view on the expected benefits",steps:["cmp7"]},{label:"Set your positions on the points we discuss",steps:["stake"]},{label:"Decide if you'd like to volunteer in R&D",steps:["research"]}],ot=(t,n)=>{var o,i;return(o=b[t])!=null&&o.steps.includes("stake")&&n?`Set your positions on ${n} points about “${g.topic}”`:((i=b[t])==null?void 0:i.label)??""},lt=t=>b.findIndex(n=>n.steps.includes(t)),Ss=t=>t?["stake","research"]:ae,ne=20,Cs=200,Is=Zt(gt).map(t=>`${t.heading} ${t.text}`).join(" ").split(/\s+/).filter(Boolean).length;function Es(t,n,o=!1){const i=c=>(n[c]??[]).filter(m=>o||!L(m)).length;switch(t){case"plan":return 0;case"welcome":return V("welcome");case"story":return V("story");case"principle":return V("principle")+Math.round(Is/Cs*60)+2*ne;case"cmp7":return i(F)*ne;case"stake":return i(D)*ne;case"research":return V("research")+ne}}const bt=(t,n,o=!1)=>Math.max(1,Math.round(t.reduce((i,c)=>i+Es(c,n,o),0)/60)),dt=(t,n,o=!1)=>b.filter(i=>i.steps.some(c=>t.includes(c))).reduce((i,c)=>i+bt(c.steps,n,o),0),re="p1336-proto-resume",yt="p1336-proto-shown";function Ps(){try{return JSON.parse(sessionStorage.getItem(yt)??"{}")}catch{return{}}}function Ts(t){try{sessionStorage.setItem(yt,JSON.stringify(t))}catch{}}function Rs(){try{const t=localStorage.getItem(re),n=t?JSON.parse(t):null;return n&&E(n.step)?{...n,furthest:n.furthest??0}:null}catch{return null}}function ye(t){try{t?localStorage.setItem(re,JSON.stringify(t)):localStorage.removeItem(re)}catch{}}const je=`${re}:finished`;function As(){try{return localStorage.getItem(je)==="1"}catch{return!1}}function _s(t){try{t?localStorage.setItem(je,"1"):localStorage.removeItem(je)}catch{}}function ct(){const[t,n]=r.useState(0),o=r.useRef(null),i=r.useCallback(c=>{var m;if((m=o.current)==null||m.disconnect(),o.current=null,!c){n(0);return}if(n(c.getBoundingClientRect().height),typeof ResizeObserver<"u"){const p=new ResizeObserver(([d])=>{d&&n(d.target.getBoundingClientRect().height)});p.observe(c),o.current=p}},[]);return r.useEffect(()=>()=>{var c;return(c=o.current)==null?void 0:c.disconnect()},[]),[i,t]}function k({children:t}){return e.jsx("h1",{className:"text-2xl font-bold leading-tight text-foreground",children:t})}function Ds(){return e.jsxs("p",{className:"flex items-center gap-2 text-sm font-medium text-foreground","data-testid":"event-line",children:[e.jsx(ve,{className:"h-4 w-4 text-muted-foreground","aria-hidden":"true"}),g.title," · ",g.dateLabel]})}function Ls(){return e.jsxs("div",{className:"rounded-lg bg-muted/50 p-3 text-left","data-testid":"event-details",children:[e.jsx("h2",{className:"mb-2 font-semibold",children:g.title}),e.jsxs("div",{className:"space-y-2 text-sm",children:[e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx(ve,{className:"mt-0.5 h-4 w-4 text-muted-foreground"}),e.jsxs("p",{children:[g.dateLabel," ",e.jsxs("span",{className:"text-muted-foreground",children:["· ",g.timeLabel]})]})]}),e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx(xt,{className:"mt-0.5 h-4 w-4 flex-shrink-0 text-muted-foreground"}),e.jsx("span",{children:g.location})]})]})]})}function ut({title:t,testId:n,note:o}){const[i,c]=r.useState(!1),m=async()=>{const d=await Qt(g.title,st);d==="copied"?(c(!0),setTimeout(()=>c(!1),2e3)):d==="failed"&&Ut.error("Could not copy link")},p="inline-flex h-10 w-10 items-center justify-center rounded-full border border-border text-foreground hover:bg-muted";return e.jsxs("section",{className:"space-y-3 rounded-xl border border-border bg-card p-4 text-center shadow-sm","data-testid":n,children:[t,e.jsx(Ls,{}),o,e.jsxs("div",{className:"grid grid-cols-2 gap-2 [&_button]:h-auto [&_button]:min-h-10 [&_button]:whitespace-normal [&_button]:px-2 [&_button]:text-sm","data-testid":`${n}-actions`,children:[e.jsx(ss,{event:ft}),e.jsx(O,{asChild:!0,variant:"outline",className:"h-auto min-h-10 gap-2 whitespace-normal px-2 text-sm",children:e.jsxs("a",{href:us,target:"_blank",rel:"noopener noreferrer","data-testid":"group-chat-link",children:[e.jsx("svg",{viewBox:"0 0 24 24",fill:"
1currentColor",className:"h-4 w-4 flex-shrink-0","aria-hidden":"true",children:e.jsx("path",{d:mt})}),"Join WhatsApp group"]})})]}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"WhatsApp group: last-minute changes, questions, and getting there. If you need a lift, ask in the group."}),e.jsxs("div",{className:"space-y-1 border-t border-border pt-3","data-testid":`${n}-share`,children:[e.jsx("p",{className:"text-sm font-medium text-muted-foreground",children:"Share"}),e.jsxs("div",{className:"flex flex-wrap justify-center gap-2",children:[cs(st,g.title).map(({name:d,glyph:l,href:y})=>e.jsx("a",{href:y,target:"_blank",rel:"noopener noreferrer","aria-label":`Share on ${d}`,title:d,className:p,"data-testid":`share-${d.toLowerCase()}`,children:e.jsx("svg",{viewBox:"0 0 24 24",fill:"currentColor",className:"h-5 w-5","aria-hidden":"true",children:e.jsx("path",{d:l})})},d)),e.jsxs("button",{type:"button",onClick:m,className:"inline-flex min-h-10 items-center gap-1.5 rounded-full border border-border px-3 text-sm font-medium text-foreground hover:bg-muted","data-testid":"share-event",children:[e.jsx(os,{className:"h-4 w-4","aria-hidden":"true"}),i?"Copied!":"Copy link"]})]})]})]})}function ht({line:t,testId:n,people:o=Ne,large:i=!1}){return e.jsxs("div",{className:"flex flex-col items-center gap-2 pt-1 text-center","data-testid":n,children:[e.jsx("div",{className:i?"my-1 scale-125":void 0,children:e.jsx(as,{attendees:o})}),e.jsx("span",{className:"text-sm text-muted-foreground",children:t})]})}const Os=["Facebook","Luma","todo.today","Sola","WhatsApp","Telegram","A friend","Other"];function $s({onRegistered:t}){const[n,o]=r.useState(!1),[i,c]=r.useState(null),[m,p]=r.useState(null);return e.jsxs("main",{className:"mx-auto max-w-2xl px-4 pt-4 pb-8","data-testid":"mock-register",children:[e.jsxs("div",{className:"bg-card rounded-xl border border-border shadow-sm p-6",children:[e.jsx("h1",{className:"text-2xl font-bold mb-4",children:g.title}),e.jsxs("div",{className:"space-y-3 text-sm text-foreground mb-6",children:[e.jsxs("p",{className:"flex items-center gap-2",children:[e.jsx(ve,{className:"h-4 w-4 text-muted-foreground","aria-hidden":"true"}),g.dateLabel," · ",g.timeLabel]}),e.jsxs("p",{className:"flex items-center gap-2",children:[e.jsx(xt,{className:"h-4 w-4 text-muted-foreground","aria-hidden":"true"}),g.location]})]}),e.jsx(O,{onClick:()=>o(!0),className:"w-full bg-blue-500 hover:bg-blue-700 text-white",size:"lg","data-testid":"rsvp-button",children:"Reserve a seat"})]}),e.jsx(qt,{open:n,onOpenChange:o,children:e.jsxs(Gt,{"data-testid":"register-sheet",children:[e.jsxs(Vt,{children:[e.jsx(Ft,{className:"text-xl",children:"Will you take 10 minutes to prepare before the event?"}),e.jsx(Jt,{className:"sr-only",children:"Choose how you will get ready, then register."})]}),e.jsxs("div",{className:"space-y-5 px-4",children:[e.jsx("div",{className:"flex flex-col gap-2",role:"radiogroup","aria-label":"Preparation",children:[["prepare","Yes, I'll prepare"],["early","I can't — I'll arrive 15 minutes early"]].map(([d,l])=>e.jsx("button",{type:"button",role:"radio","aria-checked":i===d,onClick:()=>c(d),"data-testid":`prep-choice-${d}`,className:S("min-h-12 rounded-lg border px-4 py-3 text-left text-base font-medium transition-colors",i===d?"border-blue-500 bg-blue-50 text-blue-900 dark:bg-blue-950 dark:text-blue-100":"border-border"),children:l},d))}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-2 text-sm text-muted-foreground",children:"How did you hear about the event? (optional)"}),e.jsx("div",{className:"flex flex-wrap gap-2","data-testid":"heard-from",children:Os.map(d=>e.jsx("button",{type:"button","aria-pressed":m===d,onClick:()=>p(m===d?null:d),className:S("min-h-10 rounded-full border px-3 text-sm",m===d?"border-blue-500 bg-blue-500 text-white":"border-border text-foreground"),children:d},d))})]})]}),e.jsx(Kt,{children:i&&e.jsx(O,{size:"lg",className:"w-full bg-blue-500 hover:bg-blue-700 text-white",onClick:()=>t(i),"data-testid":"register-confirm",children:"Register"})})]})})]})}function An({variant:t}={}){var Ge,Ve,Fe;const{session:n}=Dt(),o=Lt(),i=(Ge=n==null?void 0:n.user)==null?void 0:Ge.id,[c,m]=Ot(),[p,d]=r.useState(()=>Rs()),[l]=r.useState(()=>{const s=c.get("step");return E(s)&&p?p:null}),[y,ke]=r.useState((l==null?void 0:l.returning)??!1),[u,wt]=r.useState((l==null?void 0:l.step)??"confirm"),[ie,oe]=r.useState((l==null?void 0:l.furthest)??0),[Se,jt]=r.useState(0),[Ce,le]=r.useState(!1),[$,Ie]=r.useState(null),[B,Ee]=r.useState(()=>As());r.useEffect(()=>{_s(B)},[B]);const[P,M]=r.useState(null),[w,J]=r.useState((l==null?void 0:l.answer)??null),[K,H]=r.useState((l==null?void 0:l.principleRating)??null),[vt,Pe]=r.useState({answered:0,total:0}),[Nt,Te]=r.useState({answered:0,total:0}),[kt,Re]=r.useState({welcome:!1,story:!1,principle:!1}),[de,A]=r.useState((l==null?void 0:l.principleRating)!=null),[ce,Ae]=r.useState(0),[Y,Q]=r.useState((l==null?void 0:l.answer)!=null),[St,ue]=r.useState(!1),[W,U]=r.useState((l==null?void 0:l.micAsked)??!1),[C,z]=r.useState((l==null?void 0:l.micSetup)??null),[x,he]=r.useState({cmp7:null,ikigai1:null}),[j,_e]=r.useState(()=>Ps());r.useEffect(()=>{Ts(j)},[j]);const[Ct,It]=ct(),[T,De]=ct(),q=r.useCallback(()=>{se.forEach(s=>{Je.getPublicPointsFeed(rt,0,s,i,!0,!0).then(a=>he(h=>({...h,[s]:a}))).catch(()=>he(a=>({...a,[s]:[]})))})},[i]);r.useEffect(()=>{q()},[q]);const Le=se.every(s=>x[s]!==null),pe=((Ve=x.ikigai1)==null?void 0:Ve.length)??null,Oe=r.useCallback(()=>{i?q():he(s=>({...s}))},[i,q]),I=Ss(y),me=E(u)?I.indexOf(u):-1,X=s=>{var h;const a=s==="cmp7"?F:s==="stake"?D:null;return!a||(((h=j[a])==null?void 0:h.length)??0)>0?!1:(x[a]??[]).every(L)};r.useEffect(()=>{const s=u==="cmp7"?F:u==="stake"?D:null,a=s?x[s]:null;!s||!a||j[s]||_e(h=>({...h,[s]:a.filter(N=>!L(N)).map(N=>N.id)}))},[u,x,j]);const G=r.useCallback(s=>{wt(s),Ae(0),Q(!1),A(!1),U(!1),E(s)&&oe(a=>Math.max(a,ae.indexOf(s))),m(a=>{const h=new URLSearchParams(a);return E(s)?h.set("step",s):h.delete("step"),h},{replace:!0}),window.scrollTo(0,0)},[m]);r.useEffect(()=>{if(E(u)){const s={step:u,returning:y,answer:w,principleRating:K,furthest:ie,micAsked:W,micSetup:C};ye(s),d(s)}else u==="end"&&(Ee(!0),ye(null),d(null))},[u,y,w,K,ie,W,C]);const v=()=>{const s=I.slice(me+1);G(s.find(a=>!X(a))??"end")},$e=()=>{const a=I.slice(0,Math.max(me,0)).reverse().find(h=>
1!X(h))??"confirm";G(a),a==="principle"&&(Q(!0),A(K!=null))},Z=()=>{if(p){ke(p.returning),J(p.answer),H(p.principleRating),oe(p.furthest),z(p.micSetup??null),G(p.step),U(p.micAsked??!1);return}G(I.find(s=>!X(s))??"end")},Be=s=>{se.forEach(a=>(x[a]??[]).forEach(h=>Ue(h.id,null))),Promise.all(se.map(a=>Je.getPublicPointsFeed(rt,0,a,i,!0,!0).then(h=>h.forEach(N=>Ue(N.id,null))).catch(()=>{}))).then(q),ye(null),d(null),ke(s),jt(a=>a+1),le(!1),Ie(null),Ee(!1),M(null),J(null),H(null),oe(0),Pe({answered:0,total:0}),Te({answered:0,total:0}),ue(!1),z(null),_e({}),Re({welcome:!1,story:!1,principle:!1}),A(!1),G("confirm")},Et=()=>{w!==null&&de?(A(!1),H(null),window.scrollTo(0,0)):w!==null?(J(null),H(null),window.scrollTo(0,0)):Y?(Q(!1),window.scrollTo(0,0)):$e()},Me=r.useRef(null),He=r.useRef(null),[Pt,Tt]=r.useState(!1);r.useEffect(()=>{const s=()=>{const a=He.current,h=Me.current;if(!a||!h)return;const N=a.getBoundingClientRect().top+window.scrollY+32+h.offsetHeight;Tt(N>window.innerHeight)};return s(),window.addEventListener("resize",s),()=>window.removeEventListener("resize",s)});const Rt={paddingBottom:De>0?De+24:24},Ye=(s,a)=>{const h=s.answered>=s.total;return e.jsxs(R,{ref:T,children:[a&&e.jsx("div",{className:S("mb-3 w-full max-w-sm",s.answered>0&&"animate-in zoom-in-95 duration-300"),"aria-live":"polite","data-testid":"answered-count",children:e.jsx(Xe,{currentChapter:0,totalChapters:1,stepCount:Math.max(s.total,1),committedSteps:s.answered,label:`${s.answered} of ${s.total} answered`,tone:"subtle"})},s.answered),e.jsx(f,{label:"Continue",onClick:v,disabled:!h}),!h&&e.jsx(f,{label:"Skip and proceed",onClick:v,variant:"secondary"})]})},xe=(s,a)=>e.jsx(R,{ref:T,children:kt[s]?e.jsx(f,{label:"Continue",onClick:a}):e.jsxs(e.Fragment,{children:[e.jsx(f,{label:"Play the video",onClick:()=>Ae(h=>h+1)}),e.jsx(f,{label:"Continue without video",onClick:a,variant:"secondary"})]})}),fe=s=>()=>Re(a=>({...a,[s]:!0})),At=s=>{J(s),A(!1),window.scrollTo(0,0)},_t=(p?I.slice(Math.max(I.indexOf(p.step),0)):I).filter(s=>!X(s)),We=y?dt(_t,x):dt(I,x,!0),ee=E(u)?lt(u):-1,ge=b[ee],ze=u==="confirm"&&p?p:{returning:y,furthest:ie},qe=s=>{var a;return ze.returning?s<lt("stake"):!!((a=b[s])!=null&&a.steps.every(h=>ae.indexOf(h)<ze.furthest))},_=B?b.length:b.filter((s,a)=>qe(a)).length;return e.jsxs("div",{className:"min-h-[100dvh] bg-background",children:[e.jsxs("div",{ref:Ct,className:"fixed inset-x-0 top-0 z-50 border-b border-border bg-background pt-[env(safe-area-inset-top)]",children:[e.jsxs("div",{className:"mx-auto flex max-w-2xl items-center gap-2 border-b border-dashed border-border px-4 py-1 text-xs text-muted-foreground",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Prototype · P1336"}),e.jsxs("div",{className:"ml-auto flex gap-1",role:"group","aria-label":"Attendee state",children:[[!1,!0].map(s=>e.jsx("button",{type:"button",onClick:()=>Be(s),"aria-pressed":y===s&&P===null,className:S("min-h-10 rounded px-2",y===s&&P===null?"bg-foreground text-background":"border border-border bg-background text-foreground"),children:s?"Returning":"New registrant"},String(s))),t==="d"&&e.jsx("button",{type:"button",onClick:()=>{Be(!1),M("gate")},"aria-pressed":P!==null,"data-testid":"arrival-toggle",className:S("min-h-10 rounded px-2",P!==null?"bg-foreground text-background":"border border-border bg-background text-foreground"),children:"Arriving (not prepared)"})]})]}),ge&&E(u)&&P===null&&e.jsxs("div",{className:"mx-auto flex max-w-2xl items-center gap-3 px-4 py-2","data-testid":"step-header",children:[e.jsx("button",{type:"button",onClick:u==="principle"?Et:u==="research"&&W?()=>{U(!1),z(null),window.scrollTo(0,0)}:$e,"aria-label":"Back","data-testid":"header-back",className:"flex-shrink-0 -ml-1 flex h-11 w-11 items-center justify-center rounded-full text-muted-foreground hover:text-foreground hover:bg-gray-100 transition-colors",children:e.jsx(rs,{size:20})}),e.jsxs("div",{className:"min-w-0 flex-1 space-y-1",children:[e.jsx("p",{className:"text-sm font-semibold leading-snug text-foreground","data-testid":"step-name",children:ot(ee,pe)}),e.jsx(Xe,{currentChapter:ee,totalChapters:b.length,stepCount:u==="principle"?3:ge.steps.length,committedSteps:u==="principle"?(Y?1:0)+(w!==null?1:0):ge.steps.indexOf(u),label:`Step ${ee+1} of ${b.length}`})]})]})]}),e.jsx("div",{style:{height:It},"aria-hidden":!0}),P!==null?e.jsx("main",{className:"mx-auto max-w-2xl space-y-6 px-4 pt-4 pb-6",children:P==="gate"?e.jsxs("section",{className:"space-y-6 pt-8 text-center","data-testid":"arrival-gate",children:[e.jsx("h1",{className:"text-2xl font-bold leading-snug text-foreground",children:"You haven't prepared yet"}),e.jsx("p",{className:"text-base leading-relaxed text-muted-foreground",children:"The discussion uses a special structure. Ten minutes of preparation lets you take part fully."}),e.jsxs("div",{className:"flex flex-col items-center gap-1",children:[e.jsx(f,{label:"Prepare now",onClick:()=>{M(null),Z()}}),e.jsx(f,{label:"Join the room without preparing",onClick:()=>M("room"),variant:"secondary"}),e.jsx("p",{className:"text-sm text-muted-foreground","data-testid":"arrival-skip-consequence",children:"You'll miss the shared definitions and the meeting principle. You can catch up any time."})]})]}):e.jsxs("section",{className:"space-y-6","data-testid":"arrival-room",children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-x-3 rounded-lg border border-border px-3 py-1","data-testid":"finish-prep-link",children:[e.jsx("span",{className:"text-sm text-muted-foreground",children:_===0?"Preparation not started":`Preparation: ${_} of ${b.length} steps`}),e.jsx("button",{type:"button",onClick:()=>{M(null),Z()},className:"min-h-10 text-sm font-medium text-blue-600 hover:underline",children:_===0?"Start your preparation":"Finish your preparation"})]}),e.jsxs("div",{className:"space-y-3 rounded-xl border border-dashed border-border p-6 text-center",children:[e.jsx("h1",{className:"text-xl font-semibold text-foreground",children:"Event room (mock)"}),e.jsx("p",{className:"text-base text-muted-foreground",children:"The host is about to start the first roun
1d."})]})]})}):u==="principle"&&Y&&!(w!==null&&!de)?e.jsx($t,{level:gt,answer:w,rating:K,onAnswer:At,onRatingChange:H,onRatingSubmit:v,submitLabel:"Confirm",question:ks,header:w===null?e.jsx("h1",{className:"text-xl font-semibold leading-snug text-foreground","data-testid":"principle-decision-question",children:"Do you want to follow this principle with the attendees at the event?"}):void 0,aboveChoice:e.jsx("div",{className:"pb-3","data-testid":"opted-in-proof-bar",children:e.jsx(ht,{testId:"opted-in-proof",people:gs,line:`${xs} opted in at the last event · ${fs} for this event`})}),ratingBarClassName:"animate-in slide-in-from-bottom duration-300",aboveRating:e.jsxs("div",{className:"flex items-center gap-3 px-2 pb-2 sm:px-5","data-testid":"rating-host",children:[e.jsx(Ke,{name:"Slava",photoUrl:tt,isPledger:!0,size:"md"}),e.jsxs("div",{className:"min-w-0",children:[e.jsxs("p",{className:"text-sm font-semibold text-foreground",children:["Slava ",e.jsx("span",{className:"font-normal text-muted-foreground",children:"· event host"})]}),e.jsx("p",{className:"text-sm text-foreground","data-testid":"rating-context",children:w==="in"?"Thanks for trying it. Here is the question:":"Thanks for letting me ask. Here is the question:"})]})]})}):e.jsxs("main",{className:"mx-auto max-w-2xl space-y-6 px-4 pt-4",style:Rt,children:[u==="confirm"&&t==="c"&&$===null&&e.jsx($s,{onRegistered:Ie}),u==="confirm"&&!(t==="c"&&$===null)&&e.jsxs(e.Fragment,{children:[e.jsx(ut,{testId:"registered-card",title:e.jsxs("div",{className:"flex flex-col items-center gap-2",children:[e.jsxs("div",{className:"flex items-center justify-center gap-2",children:[e.jsx(is,{className:"h-5 w-5 flex-shrink-0 text-muted-foreground","aria-hidden":"true"}),e.jsx("h1",{className:"text-lg font-semibold",children:"You're Registered!"})]}),t==="d"&&B&&e.jsx("span",{"data-testid":"prep-status",children:e.jsx(et,{status:"completed",label:"Prepared ✓"})})]})}),t==="c"&&$==="early"&&e.jsx("p",{className:"text-center text-base text-foreground","data-testid":"arrive-early-line",children:"See you 15 minutes early. You can still prepare here any time."}),e.jsx("div",{ref:He,className:"!mt-0 h-0","aria-hidden":!0}),t==="d"&&!B&&(()=>{const s=e.jsxs("section",{className:"space-y-2 text-center","data-testid":"prep-block",ref:Me,children:[e.jsxs("div",{className:"space-y-0.5","data-testid":"prep-why",children:[e.jsx("p",{className:"text-base font-semibold text-foreground",children:"Our events are different"}),e.jsx("p",{className:"text-sm leading-snug text-muted-foreground",children:"We use a special structure, and we ask every participant to prepare."})]}),_===0?e.jsxs("h2",{className:"text-xl font-bold leading-snug text-foreground","data-testid":"prep-question",children:["Do you have ",Le?We:10," minutes to prepare now?"]}):e.jsxs("h2",{className:"text-xl font-bold leading-snug text-foreground","data-testid":"prep-progress",children:[_," of ",b.length," steps done"]}),e.jsxs("div",{className:"flex flex-col items-center gap-1","data-testid":"confirm-actions",children:[e.jsx(f,{label:_===0?"Prepare now":"Continue your preparation",onClick:Z}),Ce?e.jsx("p",{"aria-live":"polite",className:"flex min-h-11 items-center py-1 text-center text-sm font-medium text-green-600","data-testid":"reminder-confirmation",children:"✓ We'll email you a reminder"}):e.jsx(f,{label:"Remind me by email",onClick:()=>le(!0),variant:"secondary"})]})]});return Pt?e.jsx(R,{ref:T,children:s}):e.jsx("div",{className:"!mt-8",children:s})})(),t!=="c"&&t!=="d"&&e.jsxs("section",{className:"space-y-3 !mt-12 text-center","data-testid":"prep-block",children:[e.jsxs("h2",{className:"text-2xl font-bold leading-snug text-foreground","data-testid":"prep-question",children:["Do you have ",Le?We:10," minutes to prepare for the event?"]}),e.jsx("p",{className:"text-base leading-relaxed text-muted-foreground",children:"Your short preparation will make the event discussions more meaningful."}),e.jsx(ht,{large:!0,testId:"prepared-proof",line:`${ms} prepared for the last event · ${Ne.length} for this event`})]}),t!=="d"&&e.jsxs("div",{className:"flex flex-col items-center gap-1","data-testid":"confirm-actions",children:[e.jsx(f,{label:p?"Continue where you left off":t==="c"&&$==="prepare"?"Start preparing":"Prepare now",onClick:Z,variant:t==="c"&&$==="early"?"secondary":void 0}),Ce?e.jsx("p",{"aria-live":"polite",className:"flex min-h-11 items-center py-1 text-center text-sm font-medium text-green-600","data-testid":"reminder-confirmation",children:"✓ We'll email you a reminder"}):e.jsx(f,{label:"Remind me by email",onClick:()=>le(!0),variant:"secondary"})]})]}),u==="plan"&&e.jsxs("section",{className:"space-y-5",children:[e.jsxs(k,{children:["Your preparation · ",b.length," steps"]}),e.jsx("ol",{"data-testid":"agenda",children:b.map((s,a)=>{const h=qe(a),N=a===b.length-1;return e.jsxs("li",{className:"flex gap-3","data-testid":`agenda-step-${a+1}`,children:[e.jsxs("div",{className:"flex flex-col items-center",children:[e.jsx("span",{className:S("flex h-8 w-8 shrink-0 items-center justify-center rounded-full text-sm font-bold",h?"bg-blue-500 text-white":"bg-muted text-muted-foreground"),children:h?e.jsx(Bt,{className:"h-4 w-4","aria-label":"Done"}):a+1}),!N&&e.jsx("span",{className:"my-1 w-px flex-1 bg-border","aria-hidden":"true"})]}),e.jsxs("div",{className:S("flex min-w-0 flex-1 items-start justify-between gap-3 pt-1",!N&&"pb-6"),children:[e.jsx("p",{className:S("min-w-0 text-base font-medium leading-snug text-foreground",h&&"text-muted-foreground"),children:ot(a,pe)}),e.jsxs("span",{className:"shrink-0 pt-0.5 text-sm tabular-nums text-muted-foreground",children:[bt(s.steps,x,!y)," min"]})]})]},s.label)})}),e.jsx(R,{ref:T,children:e.jsx(f,{label:"Start now",onClick:v})})]}),u==="welcome"&&e.jsxs("section",{className:"space-y-5",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(k,{children:"How this event is different"}),e.jsx("p",{className:"text-base leading-relaxed text-muted-foreground","data-testid":"welcome-intro",children:"In our events, we reward revealing gaps in cognitive understanding."})]}),e.jsx(te,{clip:"welcome",pulse:!0,onPlay:fe("welcome"),playRequest:ce}),xe("welcome",v)]}),u==="story"&&e.jsxs("section",{className:"space-y-5",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(k,{children:"What is cognitive understanding?"}),e.jsx("p",{className:"text-base leading-relaxed text-muted-foreground","data-testid":"story-intro",children:"I explain back your intended meaning, and you rate me 10 out of 10: verified cognitive understanding. It's not agreement, and it's not feeling what you feel."})]}),e.jsx(te,{clip:"story",pulse:!0,onPlay:fe("story"),playRequest:ce}),xe("story",v)]}),u==="principle"&&!Y&&e.jsxs("section",{className:"space-y-5",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(k,{children:"Introducing the Clarity Meeting Principle"}),e.jsx("p",{className:"text-base leading-relaxed text-muted-foreground","data-testid":"principle-intro",children:"It makes the conversations at the event more meaningful. Every attendee can opt in or opt out, both are completely fine. Watch the video, then decide."})]}),e.jsx(te,{clip:"principle",onPlay:fe("principle"),playRequest:ce}),xe("principle",()=>{Q(!0),window.scrollTo(0,0)})]}),u==="principle"&&Y&&w!==null&&!de&&e.jsxs("section",{className:"flex flex-col items-center space-y-4 pt-8 text-center","data-testid":w==="in"?"try-it-now":"opt-out-ask",children:[e.jsxs("div",{className:"flex flex-col items-center gap-1",children:[e.jsx(Ke,{name:"Slava",photoUrl:tt,isPledger:!0,size:"xl"}),e.jsxs("p",{className:"text-base font-semibold text-foreground","data-testid":"host-caption",children:["Slava ",e.jsx("span",{className:"text-sm font-normal text-muted-foreground",children:"· event host"})]})]}),e.jsx("p",{className:"text-lg leading-relaxed text-foreground",children:w==="in"?"Thank you for opting in. You promised that anybody at the event can ask you a specific question, right? Let's try it now, to show how it works.":"Thank y
1ou. It's completely okay to opt out. It usually means something is unclear, or you disagree. Before you continue, can I ask you one question?"}),e.jsxs(R,{ref:T,children:[e.jsx(f,{label:w==="in"?"Try it now":"Yes",onClick:()=>{A(!0),window.scrollTo(0,0)}}),w==="out"&&e.jsx(f,{label:"No, continue",onClick:v,variant:"secondary"})]})]}),u==="cmp7"&&e.jsxs("section",{className:"space-y-4",children:[e.jsx("div",{className:"space-y-2",children:e.jsx(k,{children:"What is your value perception of the Clarity Meeting Principle?"})}),x.cmp7&&j.cmp7&&e.jsx(it,{tag:F,points:x.cmp7,askedIds:j.cmp7,onPointsChanged:Oe,onCountChange:Te},`cmp7-${Se}`),Ye(Nt,!!(x.cmp7&&j.cmp7))]}),u==="stake"&&e.jsxs("section",{className:"space-y-4",children:[y&&me===0&&e.jsx(Ds,{}),e.jsxs("div",{className:"space-y-2",children:[e.jsxs(k,{children:["Set your positions on"," ",((Fe=j.ikigai1)==null?void 0:Fe.length)??(x.ikigai1??[]).filter(s=>!L(s)).length," points about “",g.topic,"”"]}),e.jsx("p",{className:"text-base text-muted-foreground",children:"Your positions help us pair you with someone who sees it differently at the event."})]}),x.ikigai1&&j.ikigai1&&e.jsx(it,{tag:D,points:x.ikigai1,askedIds:j.ikigai1,onPointsChanged:Oe,onCountChange:Pe},`stake-${Se}`),Ye(vt,!!(x.ikigai1&&j.ikigai1))]}),u==="research"&&W&&e.jsxs("section",{className:"space-y-5","data-testid":"mic-question",children:[e.jsxs("div",{className:"space-y-2",children:[e.jsx(k,{children:"Does your phone have a USB-C port?"}),e.jsx("p",{className:"text-base text-muted-foreground",children:"iPhone 15 and newer, and most Android phones, do."})]}),C==="none"&&e.jsx("p",{className:"text-base text-foreground","data-testid":"mic-none-note",children:"Thanks. You can still take part in the discussion without recording."}),e.jsx(R,{ref:T,className:"px-0",children:e.jsxs("div",{className:Qe,children:[e.jsx("div",{className:"grid w-full grid-cols-1 gap-2","data-testid":"mic-answers",children:[["usbc","Yes, USB-C"],["own","No, I'll bring my own microphone"],["none","No, and I don't have a microphone"]].map(([s,a])=>e.jsx(O,{onClick:()=>{z(s),s!=="none"&&v()},size:"lg",variant:"outline","aria-pressed":C===s,className:S("h-12 min-w-0 rounded-full px-2 text-base",C===s&&"border-2 border-[#002B5C] bg-[#002B5C] font-semibold text-white hover:bg-[#002B5C] hover:text-white dark:border-blue-400 dark:bg-blue-400"),children:a},s))}),C==="none"&&e.jsx("div",{className:"mt-3 flex w-full justify-center",children:e.jsx(f,{label:"Continue",onClick:v})})]})})]}),u==="research"&&!W&&e.jsxs("section",{className:"space-y-5",children:[e.jsx("div",{className:"space-y-2",children:e.jsx(k,{children:"Are you open to be one of six volunteers who record their conversations at the event, to contribute to our R&D?"})}),e.jsx("p",{className:"text-base text-foreground",children:"We provide you with a USB-C lavalier microphone, or you can bring your own mic."}),e.jsx(te,{clip:"research"}),e.jsx(R,{ref:T,className:"px-0",children:e.jsxs("div",{className:S(Qe,"flex flex-col items-center"),children:[e.jsxs("p",{className:"mb-2 text-base font-medium text-foreground","data-testid":"places-left",children:[ws," of ",ys," volunteer places left"]}),e.jsx("div",{className:"mb-2 flex justify-center",children:e.jsx("button",{type:"button",onClick:()=>ue(!0),"aria-haspopup":"dialog",className:"inline-flex min-h-10 items-center text-sm text-blue-600 underline underline-offset-4","data-testid":"learn-more",children:"Learn how we use your data"})}),e.jsxs("div",{className:"grid w-full grid-cols-2 gap-2","data-testid":"research-answers",children:[e.jsx(O,{onClick:()=>{U(!0),window.scrollTo(0,0)},size:"lg",className:"h-12 min-w-0 rounded-full bg-blue-600 px-2 text-base text-white hover:bg-blue-700",children:"Yes, sure"}),e.jsx(O,{onClick:()=>{z(null),v()},size:"lg",variant:"outline",className:"h-12 min-w-0 rounded-full px-2 text-base",children:"No, thanks"})]})]})})]}),u==="end"&&e.jsxs("section",{className:"pt-4",children:[e.jsx(ut,{testId:"end-card",title:t==="d"?e.jsxs("div",{className:"flex flex-col items-center gap-2",children:[e.jsx(k,{children:"Thank y
1ou for preparing"}),e.jsx(et,{status:"completed",label:"Prepared ✓"})]}):e.jsx(k,{children:"Thank you for preparing"}),note:(C==="usbc"||C==="own")&&e.jsxs("p",{className:"text-sm text-muted-foreground","data-testid":"volunteer-note",children:["You're a recording volunteer."," ",C==="usbc"?"We'll bring a USB-C mic for you.":"Please bring your own microphone."]})}),e.jsxs("div",{className:"mt-12 flex flex-col items-center gap-3 text-center","data-testid":"end-stories",children:[e.jsx("h2",{className:"text-xl font-semibold text-foreground",children:"Interested in enriching your perspective before the event?"}),e.jsxs("p",{className:"text-base leading-relaxed text-muted-foreground",children:["Our AI agents predicted how ",be.slice(0,-1).join(", ")," and ",be[be.length-1]," would answer the ",pe??""," points"," ",(x.ikigai1??[]).some(L)?"you took a position on":"we'll discuss",". Each position comes with a story that explains it."]}),e.jsx(f,{label:"Read their stories",onClick:()=>o(`/stake/${D}?tab=stories`)})]})]})]}),e.jsx(Mt,{open:St,onOpenChange:ue,children:e.jsxs(Ht,{className:"flex max-h-[85dvh] flex-col sm:max-w-md","data-testid":"research-dialog",children:[e.jsxs(Yt,{children:[e.jsx(Wt,{children:"How we use your data"}),e.jsx(zt,{className:"sr-only",children:"Questions and answers about the voice recording."})]}),e.jsx("dl",{className:"-mx-6 min-h-0 flex-1 space-y-4 overflow-y-auto border-y border-border px-6 py-4","data-testid":"research-qa",children:vs.map(({q:s,a})=>e.jsxs("div",{className:"space-y-1",children:[e.jsx("dt",{className:"text-sm font-semibold text-foreground",children:s}),e.jsx("dd",{className:"text-sm text-muted-foreground",children:a})]},s))}),e.jsxs("p",{className:"text-sm text-muted-foreground","data-testid":"research-legal",children:[e.jsx("a",{href:"/terms-of-service",target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 hover:underline",children:"Terms"})," · ",e.jsx("a",{href:"/privacy-policy",target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 hover:underline",children:"Privacy"})," · ",e.jsx("a",{href:Ns,target:"_blank",rel:"noopener noreferrer",className:"text-blue-600 hover:underline",children:"Read more about our research program"})]})]})})]})}export{An as P1336OnboardingPrototype};

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.