PageSourceSearch

https://atlanta.tickets.beatthebomb.com/_nuxt/D_NV2Ft9.js

js beatthebomb.com collected 2026-09-26 03:27:48 UTC 27,353 bytes, 1 lines download raw bytes

1import{_ as yt}from"./Ba8ZYnUw.js";import{e as ft,j as vt,l as st,f as A,m as wt,Q as kt,x as v,c as i,h as a,a as t,g as d,b,w as G,t as n,n as m,d as p,F as g,r as I,B as at,Z as nt,E as ot,s as Ct,v as St,o as l,i as It}from"#entry";import{u as it}from"./DgmzirMX.js";import{s as Rt}from"./BzLCLO6P.js";import"./9gGBeuqq.js";const At={key:0},$t={class:"mb-8"},Ft={class:"flex items-start justify-between"},Dt={class:"text-3xl font-bold text-white"},Bt={class:"text-gray-400 mt-1"},Tt={class:"flex items-center gap-3"},Lt=["disabled"],Nt=["href"],Vt=["disabled"],jt=["disabled"],Et=["disabled"],Pt={key:0,class:"mb-4 p-4 bg-btb-red/20 text-btb-red text-sm"},Mt={key:1,class:"btb-card mb-6 border-btb-green"},Ut={class:"flex items-center gap-4"},Wt={class:"w-12 h-12 bg-btb-green/20 flex items-center justify-center"},zt={class:"text-lg font-bold text-btb-green"},Ot={key:2,class:"flex items-center gap-2 mb-3 text-xs text-gray-500"},qt={class:"grid grid-cols-4 gap-4 mb-6"},Zt={class:"btb-card text-center"},Gt={class:"text-3xl font-bold text-white"},Ht={class:"btb-card text-center"},Jt={class:"text-3xl font-bold text-white"},Kt={class:"text-xs text-gray-500 mt-0.5"},Qt={class:"btb-card text-center"},Yt={class:"text-3xl font-bold text-btb-green"},Xt={class:"btb-card text-center"},te={class:"text-3xl font-bold text-white"},ee={class:"btb-card mb-6"},se={class:"overflow-x-auto"},ae={class:"btb-table"},ne={class:"min-w-[160px]"},oe={class:"flex flex-col gap-1"},ie={class:"font-medium text-white"},le={key:0,class:"flex items-center gap-1"},re={key:0,class:"btb-badge btb-badge-draft w-fit"},ce={key:1,class:"btb-badge btb-badge-running w-fit"},de={class:"text-center text-gray-300 tabular-nums"},ue={class:"text-center tabular-nums"},be={class:"text-center tabular-nums"},me={class:"text-center"},pe={class:"text-center"},xe={key:1,class:"text-gray-500"},he={class:"text-center"},_e={key:0,class:"flex flex-col gap-0.5 items-center"},ge={class:"text-xs text-gray-500 tabular-nums"},ye={key:1,class:"text-gray-500",title:"Not enough data — need at least 2 exposures per arm"},fe={key:2,class:"text-gray-500"},ve={class:"flex flex-col gap-1"},we=["onClick","disabled"],ke=["onClick","disabled"],Ce={key:0},Se={key:1},Ie={class:"mt-4 p-4 bg-btb-gray"},Re={class:"flex items-center gap-2 mb-3"},Ae={class:"space-y-2"},$e={class:"flex items-center justify-between text-sm"},Fe={class:"text-gray-400"},De={class:"flex items-center gap-4"},Be={class:"text-gray-500 text-xs"},Te={key:0,class:"btb-badge btb-badge-running text-xs"},Le={key:1,class:"btb-badge btb-badge-draft text-xs"},Ne={class:"mt-1 h-1.5 bg-btb-dark overflow-hidden"},Ve={key:1,class:"flex items-center justify-between text-sm"},je={class:"text-gray-400"},Ee={class:"text-xs text-gray-500 mt-3"},Pe={key:1,class:"flex items-center gap-2"},Me={class:"text-gray-400 text-sm"},Ue={key:3,class:"btb-card mb-6"},We={key:0,class:"text-sm text-btb-yellow bg-btb-yellow/10 border border-btb-yellow/30 rounded px-3 py-2 mb-3"},ze={key:1,class:"text-xs text-gray-500 mb-3 tabular-nums"},Oe={key:0},qe={key:0},Ze={class:"overflow-x-auto mb-4"},Ge={class:"btb-table"},He={class:"min-w-[160px]"},Je={class:"flex flex-col gap-1"},Ke={class:"font-medium text-white"},Qe={key:0,class:"btb-badge btb-badge-draft w-fit"},Ye={class:"text-center text-gray-300 tabular-nums"},Xe={class:"text-center"},ts={class:"flex flex-col gap-0.5 items-center"},es={class:"tabular-nums text-gray-300"},ss={class:"text-gray-500 text-xs tabular-nums"},as={class:"text-center text-gray-300 tabular-nums"},ns={class:"text-center text-gray-300 tabular-nums"},os={class:"text-center"},is={key:0,class:"text-gray-600"},ls={key:1,class:"flex flex-col gap-0.5 items-center"},rs={class:"tabular-nums text-white font-medium"},cs={class:"text-gray-500 text-xs tabular-nums"},ds={class:"text-center"},us={key:0,class:"text-gray-600"},bs={key:2,class:"text-xs text-gray-500 mb-2"},ms={class:"overflow-x-auto"},ps={class:"btb-table"},xs={class:"min-w-[160px]"},hs={class:"flex flex-col gap-1"},_s={class:"font-medium text-white"},gs={key:0,class:"btb-badge btb-badge-draft w-fit"},ys={class:"text-center text-gray-300 tabular-nums"},fs={class:"text-center text-gray-300 tabular-nums"},vs={class:"text-center"},ws={key:0,class:"flex flex-col gap-0.5 items-center"},ks={class:"text-gray-500 text-xs tabular-nums"},Cs={key:1,class:"text-gray-500"},Ss={class:"text-center"},Is={key:0,class:"flex flex-col gap-0.5 items-center"},Rs={class:"text-gray-500 text-xs tabular-nums"},As={key:1,class:"text-gray-500"},$s={class:"text-center"},Fs={key:0,class:"flex flex-col gap-0.5 items-center"},Ds={class:"text-gray-500 text-xs tabular-nums"},Bs={key:1,class:"text-gray-500"},Ts={class:"text-center"},Ls={key:0,class:"text-gray-600"},Ns={key:1,class:"flex flex-col gap-0.5 items-center"},Vs={class:"text-gray-500 text-xs tabular-nums"},js={class:"text-center"},Es={key:0,class:"text-gray-600"},Ps={key:1,class:"text-gray-300 tabular-nums"},Ms={key:3,class:"text-xs text-gray-500 mt-2"},Us={key:4,class:"btb-card mb-6"},Ws={class:"text-xs text-gray-500 mb-3"},zs={class:"overflow-x-auto"},Os={class:"btb-table"},qs={class:"min-w-[120px]"},Zs={class:"font-medium text-white capitalize"},Gs={class:"text-center tabular-nums"},Hs={class:"text-center tabular-nums"},Js={class:"text-center"},Ks={class:"text-center text-gray-300 tabular-nums"},Qs={class:"btb-card"},Ys={class:"flex items-center justify-between mb-4"},Xs={key:0,class:"mb-4 p-4 bg-btb-gray space-y-4"},ta={class:"grid grid-cols-2 gap-4"},ea=["value"],sa=["value"],aa={key:0,class:"text-btb-red text-sm"},na={class:"flex items-center justify-end gap-3"},oa=["disabled"],ia={class:"grid grid-cols-2 gap-4 text-sm"},la={class:"text-white ml-2 capitalize"},ra={class:"text-white ml-2"},ca={class:"text-white ml-2"},da={class:"text-white ml-2"},ua={class:"text-white ml-2"},ba={class:"text-white ml-2"},ma={class:"text-white ml-2"},pa={class:"text-white ml-2"},xa={class:"text-white ml-2"},ha={class:"text-white ml-2"},_a={key:1,class:"text-center py-12"},Sa=ft({__name:"[id]",async setup(ga){let w,N;const y=vt().params.id,{data:r,refresh:lt}=([w,N]=st(()=>it(`/api/admin/experiments/${y}`,"$BH7_NA380p")),w=await w,N(),w),{data:h,refresh:rt}=([w,N]=st(()=>it(`/api/admin/experiments/${y}/stats`,"$Jv4MEGWjJZ")),w=await w,N(),w);function $(){lt(),rt()}const H=[{value:"",label:"All locations (global)"},{value:"brooklyn",label:"Brooklyn"},{value:"atlanta",label:"Atlanta"},{value:"dc",label:"DC"},{value:"denver",label:"Denver"},{value:"philadelphia",label:"Philadelphia"},{value:"charlotte",label:"Charlotte"},{value:"houston",label:"Houston"},{value:"staging",label:"Staging"}],J=[{value:"view_item_list",label:"View item list"},{value:"view_item",label:"View item"},{value:"add_to_cart",label:"Add to cart"},{value:"begin_checkout",label:"Begin checkout"},{value:"add_payment_info",label:"Add payment info"},{value:"purchase",label:"Purchase"}];function K(o){return o?H.find(e=>e.value===o)?.label||o:"All / global"}function P(o){return o?J.find(e=>e.value===o)?.label||o:"Purchase"}function _(o,e=1){return o==null||!Number.isFinite(o)?"—":`${(o*100).toFixed(e)}%`}
1function M(o){return`$${(o||0).toLocaleString("en-US",{minimumFractionDigits:2,maximumFractionDigits:2})}`}function u(o){return o==null||!Number.isFinite(o)?"—":o.toLocaleString()}const k=A(()=>h.value?.variants??[]);function ct(o){return o==null||!Number.isFinite(o)?"—":`${o>=0?"+":""}${(o*100).toFixed(1)}%`}function Q(o){return h.value?.comparisons?.find(e=>e.variantId===o)?.adjustedLift??null}const Y=A(()=>k.value.reduce((o,e)=>o+(e.unresolvedDepositBookings||0),0));let F=null;wt(()=>r.value?.status,o=>{F&&clearInterval(F),o==="running"&&(F=Rt($,3e4))},{immediate:!0}),kt(()=>{F&&clearInterval(F)});const D=v(!1),V=v(!1),B=v(""),T=v(""),L=v("purchase");function dt(){T.value=r.value?.location_id||"",L.value=r.value?.target_metric||"purchase",B.value="",D.value=!0}async function ut(){V.value=!0,B.value="";try{await $fetch(`/api/admin/experiments/${y}`,{method:"PUT",body:{location_id:T.value,target_metric:L.value}}),D.value=!1,$()}catch(o){B.value=o.data?.message||"Failed to update targeting"}finally{V.value=!1}}const C=v(!1),j=v(!1),E=v("");async function U(o){C.value=!0;try{await $fetch(`/api/admin/experiments/${y}`,{method:"PUT",body:{status:o}}),$()}catch(e){alert(e.data?.message||"Failed to update experiment")}finally{C.value=!1}}async function bt(o){if(confirm("Are you sure you want to declare this variant as the winner and complete the experiment?")){C.value=!0;try{await $fetch(`/api/admin/experiments/${y}`,{method:"PUT",body:{status:"completed",winner_variant_id:o}}),$()}catch(e){alert(e.data?.message||"Failed to declare winner")}finally{C.value=!1}}}const W=v(!1);async function mt(){if(r.value&&confirm(`Clone "${r.value.name}" as a new draft?`)){W.value=!0;try{const o=await $fetch(`/api/admin/experiments/${y}/clone`,{method:"POST"});o?.id&&Ct(`/admin/experiments/${o.id}`)}catch(o){alert(o?.data?.message||"Failed to clone experiment")}finally{W.value=!1}}}async function pt(o){const e=r.value?.variants?.find(s=>s.id===o);if(!e)return;const c=e.config,f=Object.keys(c||{});if(f.length===0){alert("This variant has no config keys to promote.");return}if(confirm(`Promote "${e.name}" to live CMS? This will update ${f.length} content key(s) and complete the experiment.`)){j.value=!0,E.value="";try{for(const[s,R]of Object.entries(c))await $fetch("/api/admin/cms/copy",{method:"POST",body:{page:r.value?.target_page,key:s,value:R}});await $fetch(`/api/admin/experiments/${y}`,{method:"PUT",body:{status:"completed",winner_variant_id:o}}),$()}catch(s){E.value=s.data?.message||"Failed to promote winner"}finally{j.value=!1}}}const X=A(()=>r.value?.winner_variant_id?r.value?.variants?.find(o=>o.id===r.value?.winner_variant_id):null),z=A(()=>r.value?.variantStats?.reduce((o,e)=>o+e.impressions,0)||0),tt=A(()=>r.value?.variantStats?.reduce((o,e)=>o+e.conversions,0)||0),S=A(()=>r.value?.variantStats?.find(o=>o.isControl));function xt(o,e,c,f){const s={zScore:0,confidence:0,isSignificant:!1,hasEnoughData:!1};if(o<2||c<2)return s;const R=e/o,_t=f/c,et=(e+f)/(o+c),O=et*(1-et)*(1/o+1/c);if(!isFinite(O)||O<=0)return s;const gt=Math.sqrt(O),q=Math.abs((R-_t)/gt);if(!isFinite(q))return s;const Z=(1-2*(1-ht(q)))*100;return isFinite(Z)?{zScore:q,confidence:Math.min(Math.max(Z,0),99.99),isSignificant:Z>=95,hasEnoughData:!0}:s}function ht(o){const e=1/(1+.2316419*o),c=e*(.31938153+e*(-.356563782+e*(1.781477937+e*(-1.821255978+e*1.330274429))));return 1-1/Math.sqrt(2*Math.PI)*Math.exp(-.5*o*o)*c}const x=A(()=>{const o=S.value;if(!o)return{};const e={};for(const c of r.value?.variantStats??[])c.isControl||(e[c.variantId]=xt(o.uniqueVisitors,o.conversions,c.uniqueVisitors,c.conversions));return e});return(o,e)=>{const c=St("UIcon"),f=yt;return a(r)?(l(),i("div",At,[t("div",$t,[b(f,{to:"/admin/experiments",class:"text-gray-400 hover:text-white mb-2 inline-flex items-center"},{default:G(()=>[b(c,{name:"i-heroicons-arrow-left",class:"w-4 h-4 mr-2"}),e[6]||(e[6]=p(" Back to Experiments ",-1))]),_:1}),t("div",Ft,[t("div",null,[t("h1",Dt,n(a(r).name),1),t("p",Bt,n(a(r).description||"No description"),1)]),t("div",Tt,[t("span",{class:m(["btb-badge text-sm px-3 py-1",`btb-badge-${a(r).status}`])},n(a(r).status),3),b(f,{to:`/admin/experiments/results#exp-${a(y)}`,class:"btb-btn-secondary text-sm",title:"Open the Live Results reporting screen"},{default:G(()=>[b(c,{name:"i-heroicons-chart-bar",class:"w-4 h-4 mr-1"}),e[7]||(e[7]=p(" Live Results ",-1))]),_:1},8,["to"]),t("button",{onClick:mt,disabled:a(W),class:"btb-btn-secondary text-sm",title:"Duplicate this experiment as a new draft"},[b(c,{name:"i-heroicons-document-duplicate",class:"w-4 h-4 mr-1"}),e[8]||(e[8]=p(" Clone ",-1))],8,Lt),t("a",{href:`/api/admin/experiments/${a(y)}/export.csv`,class:"btb-btn-secondary text-sm",title:"Download raw impression + conversion rollups as CSV"},[b(c,{name:"i-heroicons-arrow-down-tray",class:"w-4 h-4 mr-1"}),e[9]||(e[9]=p(" Export CSV ",-1))],8,Nt),a(r).status==="draft"?(l(),i("button",{key:0,onClick:e[0]||(e[0]=s=>U("running")),disabled:a(C),class:"btb-btn-success"},[b(c,{name:"i-heroicons-play",class:"w-5 h-5 mr-2"}),e[10]||(e[10]=p(" Start Experiment ",-1))],8,Vt)):a(r).status==="running"?(l(),i("button",{key:1,onClick:e[1]||(e[1]=s=>U("paused")),disabled:a(C),class:"btb-btn-secondary"},[b(c,{name:"i-heroicons-pause",class:"w-5 h-5 mr-2"}),e[11]||(e[11]=p(" Pause ",-1))],8,jt)):a(r).status==="paused"?(l(),i("button",{key:2,onClick:e[2]||(e[2]=s=>U("running")),disabled:a(C),class:"btb-btn-success"},[b(c,{name:"i-heroicons-play",class:"w-5 h-5 mr-2"}),e[12]||(e[12]=p(" Resume ",-1))],8,Et)):d("",!0)])])]),a(E)?(l(),i("div",Pt,n(a(E)),1)):d("",!0),a(r).status==="completed"&&a(X)?(l(),i("div",Mt,[t("div",Ut,[t("div",Wt,[b(c,{name:"i-heroicons-trophy",class:"w-6 h-6 text-btb-green"})]),t("div",null,[t("h3",zt,"Winner: "+n(a(X).name),1),e[13]||(e[13]=t("p",{class:"text-gray-400"},"This experiment has been completed",-1))])])])):d("",!0),a(r).status==="running"?(l(),i("div",Ot,[...e[14]||(e[14]=[t("span",{class:"inline-block w-2 h-2 rounded-full bg-btb-green animate-pulse"}
1,null,-1),p(" Live — refreshes every 30s ",-1)])])):d("",!0),t("div",qt,[t("div",Zt,[t("p",Gt,n(a(z).toLocaleString()),1),e[15]||(e[15]=t("p",{class:"text-gray-400 text-sm"},"Total Impressions",-1))]),t("div",Ht,[t("p",Jt,n(a(tt).toLocaleString()),1),e[16]||(e[16]=t("p",{class:"text-gray-400 text-sm"},"Total Conversions",-1)),t("p",Kt,"Goal: "+n(P(a(r).target_metric)),1)]),t("div",Qt,[t("p",Yt,n(a(z)>0?(a(tt)/a(z)*100).toFixed(2):"0.00")+"% ",1),e[17]||(e[17]=t("p",{class:"text-gray-400 text-sm"},"Overall Conv. Rate",-1))]),t("div",Xt,[t("p",te,n(a(r).traffic_percent)+"%",1),e[18]||(e[18]=t("p",{class:"text-gray-400 text-sm"},"Traffic Allocation",-1))])]),t("div",ee,[e[22]||(e[22]=t("h2",{class:"btb-card-header"},"Variant Performance",-1)),e[23]||(e[23]=t("p",{class:"text-xs text-gray-500 -mt-2 mb-3"}," Impressions, conversions, and Z-test significance vs. control, per variant. ",-1)),t("div",se,[t("table",ae,[e[19]||(e[19]=t("thead",null,[t("tr",null,[t("th",{class:"min-w-[160px]"},"Variant"),t("th",{class:"text-center"},"Impressions"),t("th",{class:"text-center"},"Visitors"),t("th",{class:"text-center"},"Conversions"),t("th",{class:"text-center"},"Conv. Rate"),t("th",{class:"text-center"},"Improvement"),t("th",{class:"text-center"},"Confidence"),t("th",{class:"min-w-[120px]"},"Actions")])],-1)),t("tbody",null,[(l(!0),i(g,null,I(a(r).variantStats,s=>(l(),i("tr",{key:s.variantId,class:m({"bg-btb-green/10":a(r).winner_variant_id===s.variantId})},[t("td",ne,[t("div",oe,[t("span",ie,n(s.variantName),1),s.isControl||a(r).winner_variant_id===s.variantId?(l(),i("div",le,[s.isControl?(l(),i("span",re,"Control")):d("",!0),a(r).winner_variant_id===s.variantId?(l(),i("span",ce,"Winner")):d("",!0)])):d("",!0)])]),t("td",de,n(u(s.impressions??0)),1),t("td",ue,n(u(s.uniqueVisitors)),1),t("td",be,n(u(s.conversions)),1),t("td",me,[t("span",{class:m(["font-medium tabular-nums",parseFloat(s.conversionRate)>0?"text-btb-green":"text-gray-400"])},n(s.conversionRate)+"% ",3)]),t("td",pe,[!s.isControl&&a(S)?(l(),i("span",{key:0,class:m(["font-medium tabular-nums",parseFloat(s.conversionRate)>=parseFloat(a(S).conversionRate)?"text-btb-green":"text-btb-red"])},n(a(S).conversionRate&&parseFloat(a(S).conversionRate)>0?((parseFloat(s.conversionRate)-parseFloat(a(S).conversionRate))/parseFloat(a(S).conversionRate)*100).toFixed(1)+"%":"N/A"),3)):(l(),i("span",xe,"—"))]),t("td",he,[!s.isControl&&a(x)[s.variantId]?.hasEnoughData?(l(),i("div",_e,[t("span",{class:m(["font-medium text-sm tabular-nums",a(x)[s.variantId].isSignificant?"text-btb-green":"text-btb-yellow"])},n(a(x)[s.variantId].confidence.toFixed(1))+"% ",3),t("span",ge," z="+n(a(x)[s.variantId].zScore.toFixed(2)),1)])):s.isControl?(l(),i("span",fe,"—")):(l(),i("span",ye,"—"))]),t("td",null,[t("div",ve,[a(r).status==="running"?(l(),i("button",{key:0,onClick:R=>bt(s.variantId),class:"btb-btn-secondary text-xs py-1",disabled:a(C)}," Declare Winner ",8,we)):d("",!0),(a(r).status==="running"||a(r).status==="paused")&&!s.isControl&&a(r).type==="copy"?(l(),i("button",{key:1,onClick:R=>pt(s.variantId),class:"btb-btn-primary text-xs py-1",disabled:a(j),title:"Apply this variant's text to live CMS and complete experiment"},[a(j)?(l(),i("span",Ce,"Promoting...")):(l(),i("span",Se,"Promote Winner"))],8,ke)):d("",!0)])])],2))),128))])])]),t("div",Ie,[t("div",Re,[b(c,{name:"i-heroicons-chart-bar",class:"w-5 h-5 text-btb-cyan"}),e[20]||(e[20]=t("span",{class:"font-medium text-white"},"Statistical Analysis",-1))]),a(S)&&(a(r).variantStats?.length??0)>1?(l(),i(g,{key:0},[t("div",Ae,[(l(!0),i(g,null,I(a(r).variantStats,s=>(l(),i("div",{key:s.variantId},[!s.isControl&&a(x)[s.variantId]?.hasEnoughData?(l(),i(g,{key:0},[t("div",$e,[t("span",Fe,n(s.variantName)+" vs Control",1),t("div",De,[t("span",Be," Z-score: "+n(a(x)[s.variantId].zScore.toFixed(3)),1),t("span",{class:m(["font-medium",a(x)[s.variantId].isSignificant?"text-btb-green":"text-btb-yellow"])},n(a(x)[s.variantId].confidence.toFixed(2))+"% confidence ",3),a(x)[s.variantId].isSignificant?(l(),i("span",Te," Significant ")):(l(),i("span",Le," Not yet "))])]),t("div",Ne,[t("div",{class:m(["h-full transition-all duration-500",a(x)[s.variantId].isSignificant?"bg-btb-green":"bg-btb-yellow"]),style:It({width:Math.min(a(x)[s.variantId].confidence,100)+"%"})},null,6)])],64)):s.isControl?d("",!0):(l(),i("div",Ve,[t("span",je,n(s.variantName)+" vs Control",1),e[21]||(e[21]=t("span",{class:"text-gray-500 text-xs",title:"Need at least 2 exposures on both arms to run the Z-test"}," — not enough data ",-1))]))]))),128))]),t("p",Ee," 95% confidence required to declare statistical significance. Formula: two-proportion Z-test. Minimum sample size: "+n(a(r).min_sample_size)+" per variant. ",1)],64)):(l(),i("div",Pe,[b(c,{name:"i-heroicons-clock",class:"w-5 h-5 text-btb-yellow"}),t("span",Me,"Collecting data... Need at least "+n(a(r).min_sample_size)+" visitors per variant.",1)]))])]),a(k).length?(l(),i("div",Ue,[e[27]||(e[27]=t("h2",{class:"btb-card-header"},"Cancellations, No-Shows & Unpaid Balances",-1)),e[28]||(e[28]=t("p",{class:"text-xs text-gray-500 -mt-2 mb-3"}," Cancellation and no-show rate per variant, the deposit-only cut of the cancellation rate, and outstanding balances split by whether the visit has already happened. ",-1)),a(h)&&!a(h).rollerStatusDataAvailable?(l(),i("p",We," These bookings have not been checked against Roller yet, so cancellations, no-shows and balances below are not known. They are not zero. ")):a(h)?(l(),i("p",ze,[e[24]||(e[24]=p(" Checked against Roller: ",-1)),(l(!0),i(g,null,I(a(k),(s,R)=>(l(),i("span",{key:`rec-${s.variantId}`},[R?(l(),i("span",Oe," · ")):d("",!0),p(n(s.name)+" "+n(u(s.reconciledBookings))+"/"+n(u(s.bookingsWithStatus)),1)]))),128)),a(k)[0]?.lastReconciledAt?(l(),i("span",qe," · last check "+n(new Date(a(k)[0].lastReconciledAt).toLocaleStr
1ing()),1)):d("",!0)])):d("",!0),e[29]||(e[29]=t("h3",{class:"text-sm font-semibold text-white mb-2"},"AdjCR (Adjusted Conversion Rate)",-1)),t("div",Ze,[t("table",Ge,[e[25]||(e[25]=t("thead",null,[t("tr",null,[t("th",{class:"min-w-[160px]"},"Variant"),t("th",{class:"text-center"},"Purchases"),t("th",{class:"text-center min-w-[150px]"},"Drawdowns"),t("th",{class:"text-center"},"Adjusted purchases"),t("th",{class:"text-center min-w-[100px]"},"Conv. rate"),t("th",{class:"text-center min-w-[140px]"},"AdjCR"),t("th",{class:"text-center min-w-[110px]"},"AdjCR vs control")])],-1)),t("tbody",null,[(l(!0),i(g,null,I(a(k),s=>(l(),i("tr",{key:`adjcr-${s.variantId}`},[t("td",He,[t("div",Je,[t("span",Ke,n(s.name),1),s.isControl?(l(),i("span",Qe,"Control")):d("",!0)])]),t("td",Ye,n(u(s.purchaseBookings)),1),t("td",Xe,[t("div",ts,[t("span",es,n(u(s.drawdownBookings)),1),t("span",ss,n(u(s.drawdownCancelled))+" cancelled · "+n(u(s.drawdownDepositNoShow))+" deposit no-show · "+n(u(s.drawdownDepositUnpaid))+" deposit unpaid ",1)])]),t("td",as,n(u(s.adjustedPurchases)),1),t("td",ns,n(_(s.purchaseCvr,2)),1),t("td",os,[a(h)?.rollerStatusDataAvailable?(l(),i("div",ls,[t("span",rs,n(_(s.adjustedCvr,2)),1),t("span",cs," ["+n(_(s.adjustedCvrWilson95Lo))+"–"+n(_(s.adjustedCvrWilson95Hi))+"] ",1)])):(l(),i("span",is,"—"))]),t("td",ds,[s.isControl||!a(h)?.rollerStatusDataAvailable?(l(),i("span",us,"—")):(l(),i("span",{key:1,class:m(["tabular-nums",(Q(s.variantId)??0)>=0?"text-btb-green":"text-btb-red"])},n(ct(Q(s.variantId))),3))])]))),128))])])]),a(Y)>0?(l(),i("p",bs," Provisional: "+n(a(Y))+" deposit booking(s) have not had their visit yet or have not been checked against Roller. ",1)):d("",!0),e[30]||(e[30]=t("p",{class:"text-xs text-gray-500 mb-4"}," AdjCR (adjusted conversion rate) = purchases minus bookings later cancelled/refunded, plus deposit bookings that no-showed or still owed a balance after the visit date. ",-1)),t("div",ms,[t("table",ps,[e[26]||(e[26]=t("thead",null,[t("tr",null,[t("th",{class:"min-w-[160px]"},"Variant"),t("th",{class:"text-center"},"Bookings"),t("th",{class:"text-center"},"Cancelled"),t("th",{class:"text-center min-w-[140px]"},"Cancellation rate"),t("th",{class:"text-center min-w-[160px]"},"Deposit bookings cancelled"),t("th",{class:"text-center min-w-[140px]"},"No-show rate"),t("th",{class:"text-center min-w-[140px]"},"Unpaid after visit"),t("th",{class:"text-center"},"Balance not yet due")])],-1)),t("tbody",null,[(l(!0),i(g,null,I(a(k),s=>(l(),i("tr",{key:`canc-${s.variantId}`},[t("td",xs,[t("div",hs,[t("span",_s,n(s.name),1),s.isControl?(l(),i("span",gs,"Control")):d("",!0)])]),t("td",ys,n(u(s.bookingsWithStatus)),1),t("td",fs,n(u(s.cancelledBookings)),1),t("td",vs,[s.bookingsWithStatus?(l(),i("div",ws,[t("span",{class:m(["tabular-nums",s.cancellationRate>.05?"text-btb-pink font-medium":"text-gray-300"])},n(_(s.cancellationRate)),3),t("span",ks," ["+n(_(s.cancellationWilson95Lo))+"–"+n(_(s.cancellationWilson95Hi))+"] ",1)])):(l(),i("span",Cs,"—"))]),t("td",Ss,[s.depositBookingsWithStatus?(l(),i("div",Is,[t("span",{class:m(["tabular-nums",s.depositCancellationRate>.05?"text-btb-pink font-medium":"text-gray-300"])},n(_(s.depositCancellationRate)),3),t("span",Rs,n(u(s.cancelledDepositBookings))+"/"+n(u(s.depositBookingsWithStatus))+" deposit ",1)])):(l(),i("span",As,"—"))]),t("td",$s,[s.pastVisitBookings?(l(),i("div",Fs,[t("span",{class:m(["tabular-nums",s.noShowRate>.05?"text-btb-pink font-medium":"text-gray-300"])},n(_(s.noShowRate)),3),t("span",Ds,n(u(s.noShowBookings))+"/"+n(u(s.pastVisitBookings))+" past visits ",1)])):(l(),i("span",Bs,"—"))]),t("td",Ts,[s.balanceDataAvailable?(l(),i("div",Ns,[t("span",{class:m(["tabular-nums",s.unpaidAsOfVisit>0?"text-btb-red font-medium":"text-gray-300"])},n(M(s.unpaidAsOfVisit)),3),t("span",Vs,n(u(s.unpaidBookingsAsOfVisit))+" bookings",1)])):(l(),i("span",Ls,"—"))]),t("td",js,[s.balanceDataAvailable?(l(),i("span",Ps,n(M(s.pendingBalance)),1)):(l(),i("span",Es,"—"))])]))),128))])])]),a(k).some(s=>!s.balanceDataAvailable)?(l(),i("p",Ms," Balance data not available (migration pending) — see docs/DEPOSIT-BALANCE-TRACKING.md. ")):d("",!0),e[31]||(e[31]=t("p",{class:"text-xs text-gray-500 mt-2"}," Cancelled = Roller shows the booking cancelled or refunded, or an agent cancelled and refunded it here. No-show = Roller marked it a no-show, counted only over checked bookings whose visit date has passed. Balances come from the same Roller check and can lag Roller by up to a day. ",-1))])):d("",!0),a(h)?.byLocation?.length?(l(),i("div",Us,[e[33]||(e[33]=t("h2",{class:"btb-card-header"},"Location Breakdown",-1)),t("p",Ws," Exposed sessions and "+n(P(a(h).primaryGoal).toLowerCase())+" conversions per location. ",1),t("div",zs,[t("table",Os,[e[32]||(e[32]=t("thead",null,[t("tr",null,[t("th",{class:"min-w-[120px]"},"Location"),t("th",{class:"text-center"},"Exposed sessions"),t("th",{class:"text-center"},"Conversions"),t("th",{class:"text-center"},"CVR"),t("th",{class:"text-center"},"Revenue")])],-1)),t("tbody",null,[(l(!0),i(g,null,I(a(h).byLocation,s=>(l(),i("tr",{key:s.locationId??"__all__"},[t("td",qs,[t("span",Zs,n(K(s.locationId)),1)]),t("td",Gs,n(u(s.exposedSessions)),1),t("td",Hs,n(u(s.primaryConversions)),1),t("td",Js,[t("span",{class:m(["font-medium tabular-nums",s.cvr>0?"text-btb-green":"text-gray-400"])},n(_(s.cvr,2)),3)]),t("td",Ks,n(M(s.primaryRevenue)),1)]))),128))])])])])):d("",!0),t("div",Qs,[t("div",Ys,[e[35]||(e[35]=t("h2",{class:"btb-card-header mb-0"},"Experiment Details",-1)),a(D)?d("",!0):(l(),i("button",{key:0,onClick:dt,class:"btb-btn-secondary text-sm"},[b(c,{name:"i-heroicons-pencil-square",class:"w-4 h-4 mr-1"}),e[34]||(e[34]=p(" Edit Targeting ",-1))]))]),a(D)?(l(),i("div",Xs,[t("div",ta,[t("div",null,[e[36]||(e[36]=t("label",{class:"btb-label"},"Location targeting",-1)),at(t("select",{"onUpdate:modelValue":e[3]||(e[3]=s=>ot(T)?T.value=s:null),class:"btb-select w-full"},[(l(),i(g,null,I(H,s=>t("option",{key:s.value,value:s.value},n(s.label),9,ea)),64))],512),[[nt,a(T)]])]),t("div",null,[e[37]||(e[37]=t("label",{class:"btb-label"},"Primary metric (goal)",-1)),at(t("select",{"onUpdate:modelValue":e[4]||(e[4]=s=>ot(L)?L.value=s:null),class:"btb-select w-full"},[(l(),i(g,null,I(J,s=>t("option",{key:s.value,value:s.value},n(s.label),9,sa)),64))],512),[[nt,a(L)]])])]),a(B)?(l(),i("div",aa,n(a(B)),1)):d("",!0),t("div",na,[t("button",{onClick:e[5]||(e[5]=s=>D.value=!1),class:"btb-btn-secondary text-sm"},"Cancel"),t("button",{onClick:ut,disabled:a(V),class:"btb-btn-primary text-sm"},n(a(V)?"Saving...":"Save"),9,oa)])])):d("",!0),t("div",ia,[t("div",null,[e[38]||(e[38]=t("span",{class:"text-gray-400"},"Type:",-1)),t("span",la,n(a(r).type),1)]),t("div",null,[e[39]||(e[39]=t("span",{class:"text-gray-400"},"Target Page:",-1)),t("span",ra,n(a(r).target_page||"All pages"),1)]),t("div",null,[e[40]||(e[40]=t("span",{class:"text-gray-400"},"Location:",-1)),t("span",ca,n(K(a(r).location_id)),1)]),t("div",null,[e[41]||(e[41]=t("span",{class:"text-gray-400"},"Primary Metric:",-1)),t("span",da,n(P(a(r).target_metric)),1)]),t("div",null,[e[42]||(e[42]=t("span",{class:"text-gray-400"},"Target Element:",-1)),t("span",ua,n(a(r).target_element||"Not specified"),1)]),t("div",null,[e[43]||(e[43]=t("span",{class:"text-gray-400"},"Auto-promote:",-1)),t("span",ba,n(a(r).auto_promote?"Yes":"No"),1)]),t("div",null,[e[44]||(e[44]=t("span",{class:"text-gray-400"},"Confidence Threshold:",-1)),t("span",ma,n((a(r).confidence_threshold*100).toFixed(0))+"%",1)]),t("div",null,[e[45]||(e[45]=t("span",{class:"text-gray-400"},"Min Sample Size:",-1)),t("span",pa,n(a(r).min_sample_size)+" per variant",1)]),t("div",null,[e[46]||(e[46]=t("span",{class:"text-gray-400"},"Created:",-1)),t("span",xa,n(new Date(a(r).created_at).toLocaleDateString()),1)]),t("div",null,[e[47]||(e[47]=t("span",{class:"text-gray-400"},"Created By:",-1)),t("span",ha,n(a(r).created_by||"Unknown"),1)])])])])):(l(),i("div",_a,[b(c,{name:"i-heroicons-exclamation-circle",class:"w-16 h-16 mx-auto text-gray-500 mb-4"}),e[49]||(e[49]=t("h2",{class:"text-xl text-white"},"Experiment not found",-1)),b(f,{to:"/admin/experiments",class:"btb-btn-primary mt-4"},{default:G(()=>[...e[48]||(e[48]=[p(" Back to Experiments ",-1)])]),_:1})]))}}});
1export{Sa 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.