1(function(){try{var e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{};e.SENTRY_RELEASE={id:`chessbook-web@bb8efeb7ea07680c803efd4da4817360df75da47`};var t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`1c7ab526-e715-4a17-99aa-c16acc0c5b98`,e._sentryDebugIdIdentifier=`sentry-dbid-1c7ab526-e715-4a17-99aa-c16acc0c5b98`)}catch{}})();import{O as e,P as t,T as n,p as r}from"./web-zdZ8e3vS.js";import{n as i}from"./GameResultsBar-D4-lXtI4.js";var a=n(`<main class="min-h-screen bg-gray-24 text-primary"><div class="mx-auto flex w-full max-w-5xl flex-col gap-8 px-4 py-6"><header class="border-b border-gray-37 pb-5"><h1 class="text-2xl font-bold">Game Results Bar</h1><p class="mt-1 text-sm text-tertiary">Fixtures are labelled white-draw-black percentages.</p></header><!><!>`),o=n(`<section class="flex flex-col gap-3"><div><h2 class="text-lg font-bold"></h2><p class="text-sm text-tertiary"></p></div><div class="grid gap-2">`),s=n(`<div class="grid min-w-0 grid-cols-[76px_122px_122px] items-center gap-3 border border-gray-37 bg-gray-26 px-3 py-2"><div class="text-xs font-semibold tabular-nums text-secondary"></div><!><!>`),c=n(`<div class="grid min-w-0 grid-cols-[34px_80px] items-center gap-2"><div class="text-xs font-medium capitalize text-tertiary"></div><div class=w-[80px]>`),l=1e4,u=e=>({white:Math.round(e.white/100*l),draw:Math.round(e.draw/100*l),black:Math.round(e.black/100*l)}),d=Array.from({length:17},(e,t)=>{let n=10+t*5;return{label:`${n}-5-${100-n-5}`,white:n,draw:5,black:100-n-5}}),f=[10,15,20,25,30,35,40,45,50].map(e=>({label:`${e}-40-${100-e-40}`,white:e,draw:40,black:100-e-40})),p=()=>{var e=a(),n=e.firstChild,i=n.firstChild.nextSibling,o=i.nextSibling;return r(n,t(m,{title:`5% draw, white wins 10-90%`,description:`White win chance steps by 5%; black gets the remainder.`,fixtures:d}),i),r(n,t(m,{title:`40% draw`,description:`High-draw cases with white win chance stepping from 10-50%.`,fixtures:f}),o),e},m=n=>(()=>{var i=o(),a=i.firstChild,s=a.firstChild,c=s.nextSibling,l=a.nextSibling;return r(s,()=>n.title),r(c,()=>n.description),r(l,t(e,{get each(){return n.fixtures},children:e=>t(h,{fixture:e})})),i})(),h=e=>{let n=()=>u(e.fixture);var i=s(),a=i.firstChild,o=a.nextSibling,c=o.nextSibling;return r(a,()=>e.fixture.label),r(i,t(g,{activeSide:`white`,get results(){return n()}}),o),r(i,t(g,{activeSide:`black`,get results(){return n()}}),c),i},g=e=>(()=>{var n=c(),a=n.firstChild,o=a.nextSibling;return r(a,()=>e.activeSide),r(o,t(i,{get gameResults(){return e.results},lowConfidence:!1,get activeSide(){return e.activeSide}})),n})();export{p as GameResultsBarStorybook};
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.