@divami-artefacts/ai-design-system 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +315 -0
- package/dist/canvas/CanvasTooltip.d.ts +13 -0
- package/dist/canvas/CausalFlowCanvas.d.ts +16 -0
- package/dist/canvas/canvasUtils.d.ts +38 -0
- package/dist/canvas/easing.d.ts +23 -0
- package/dist/canvas/useCanvasInteraction.d.ts +45 -0
- package/dist/canvas/useCanvasLoop.d.ts +19 -0
- package/dist/components/areaChart/AreaChart.d.ts +2 -0
- package/dist/components/barChart/BarChart.d.ts +2 -0
- package/dist/components/chartFrame/ChartFrame.d.ts +2 -0
- package/dist/components/commitmentRace/CommitmentRace.d.ts +2 -0
- package/dist/components/commitmentRace/index.d.ts +2 -0
- package/dist/components/commitmentRace/styles.d.ts +1 -0
- package/dist/components/commitmentRace/types.d.ts +5 -0
- package/dist/components/common/SeriesChart.d.ts +2 -0
- package/dist/components/compensationGauge/CompensationGauge.d.ts +2 -0
- package/dist/components/compensationGauge/index.d.ts +2 -0
- package/dist/components/compensationGauge/styles.d.ts +1 -0
- package/dist/components/compensationGauge/types.d.ts +6 -0
- package/dist/components/constants.d.ts +6 -0
- package/dist/components/contractBars/ContractBars.d.ts +2 -0
- package/dist/components/contractBars/index.d.ts +2 -0
- package/dist/components/contractBars/styles.d.ts +1 -0
- package/dist/components/contractBars/types.d.ts +5 -0
- package/dist/components/contractValueOrb/ContractValueOrb.d.ts +2 -0
- package/dist/components/contractValueOrb/index.d.ts +2 -0
- package/dist/components/contractValueOrb/styles.d.ts +1 -0
- package/dist/components/contractValueOrb/types.d.ts +5 -0
- package/dist/components/contractorRank/ContractorRank.d.ts +2 -0
- package/dist/components/contractorRank/index.d.ts +2 -0
- package/dist/components/contractorRank/styles.d.ts +1 -0
- package/dist/components/contractorRank/types.d.ts +5 -0
- package/dist/components/donutChart/DonutChart.d.ts +2 -0
- package/dist/components/ewCategory/EWCategory.d.ts +2 -0
- package/dist/components/ewCategory/index.d.ts +2 -0
- package/dist/components/ewCategory/styles.d.ts +1 -0
- package/dist/components/ewCategory/types.d.ts +5 -0
- package/dist/components/hooks/useWorkspace.d.ts +6 -0
- package/dist/components/keyHighlights/KeyHighlights.d.ts +4 -0
- package/dist/components/lineChart/LineChart.d.ts +2 -0
- package/dist/components/miniBars/MiniBars.d.ts +2 -0
- package/dist/components/nceTree/NCETree.d.ts +2 -0
- package/dist/components/nceTree/index.d.ts +2 -0
- package/dist/components/nceTree/styles.d.ts +1 -0
- package/dist/components/nceTree/types.d.ts +6 -0
- package/dist/components/pieChart/PieChart.d.ts +2 -0
- package/dist/components/quotationBalance/QuotationBalance.d.ts +2 -0
- package/dist/components/quotationBalance/index.d.ts +2 -0
- package/dist/components/quotationBalance/styles.d.ts +1 -0
- package/dist/components/quotationBalance/types.d.ts +6 -0
- package/dist/components/quotationTrend/QuotationTrend.d.ts +2 -0
- package/dist/components/quotationTrend/index.d.ts +2 -0
- package/dist/components/quotationTrend/styles.d.ts +1 -0
- package/dist/components/quotationTrend/types.d.ts +5 -0
- package/dist/components/sankey/ProcessSankey.d.ts +2 -0
- package/dist/components/sankey/RankingSankey.d.ts +2 -0
- package/dist/components/sankey/SankeySvg.d.ts +2 -0
- package/dist/components/sankey/index.d.ts +3 -0
- package/dist/components/severityBands/SeverityBands.d.ts +2 -0
- package/dist/components/severityBands/index.d.ts +2 -0
- package/dist/components/severityBands/styles.d.ts +1 -0
- package/dist/components/severityBands/types.d.ts +5 -0
- package/dist/components/statusArc/StatusArc.d.ts +2 -0
- package/dist/components/statusArc/index.d.ts +2 -0
- package/dist/components/statusArc/styles.d.ts +1 -0
- package/dist/components/statusArc/types.d.ts +9 -0
- package/dist/components/trendChart/TrendChart.d.ts +2 -0
- package/dist/components/variationSplit/VariationSplit.d.ts +2 -0
- package/dist/components/variationSplit/index.d.ts +2 -0
- package/dist/components/variationSplit/styles.d.ts +1 -0
- package/dist/components/variationSplit/types.d.ts +5 -0
- package/dist/components/visualizationRenderer/VisualizationRenderer.d.ts +2 -0
- package/dist/components/weeklyFlow/WeeklyFlow.d.ts +2 -0
- package/dist/components/weeklyFlow/index.d.ts +2 -0
- package/dist/components/weeklyFlow/styles.d.ts +1 -0
- package/dist/components/weeklyFlow/types.d.ts +5 -0
- package/dist/components/workspaceShell/WorkspaceShell.d.ts +1 -0
- package/dist/hooks/useWorkspace.d.ts +6 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +3019 -0
- package/dist/mocks/workspace.mock.d.ts +378 -0
- package/dist/pages/chartGallery/ChartGalleryPage.d.ts +1 -0
- package/dist/pages/projectDashboard/ProjectDashboardPage.d.ts +1 -0
- package/dist/pages/projectDashboard/index.d.ts +2 -0
- package/dist/pages/projectDashboard/styles.d.ts +4 -0
- package/dist/pages/projectDashboard/types.d.ts +3 -0
- package/dist/pages/workspace/WorkspacePage.d.ts +1 -0
- package/dist/types/index.d.ts +344 -0
- package/dist/utils/mounts.d.ts +4 -0
- package/dist/utils/workspace.utils.d.ts +17 -0
- package/package.json +53 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const containerStyle: React.CSSProperties;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function WorkspaceShell(): import("react/jsx-runtime").JSX.Element;
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let e=require(`react-dom/client`),t=require(`react`),n=require(`react/jsx-runtime`);function r({children:e,className:t=``}){return(0,n.jsx)(`div`,{className:`d3-chart ${t}`.trim(),children:e})}var i={bg:`#070B12`,bgL:`#0C1420`,sf:`#111B28`,bd:`#1C2D42`,blue:`#3B8BF6`,cyan:`#22D3EE`,orange:`#F0813A`,red:`#F06060`,green:`#34D399`,purple:`#A78BFA`,amber:`#FBBF24`,t1:`#F1F5F9`,t2:`#94A3B8`,t3:`#64748B`,t4:`#334155`},a=[i.blue,i.cyan,i.amber,i.purple,i.green,i.red];function o(e,t=1){let n=e.replace(`#`,``);return`rgba(${parseInt(n.substring(0,2),16)},${parseInt(n.substring(2,4),16)},${parseInt(n.substring(4,6),16)},${t})`}function s(e,t,n){return e+(t-e)*n}function c(e,t,n){let r=e=>{let t=e.replace(`#`,``);return[parseInt(t.substring(0,2),16),parseInt(t.substring(2,4),16),parseInt(t.substring(4,6),16)]},[i,a,o]=r(e),[c,l,u]=r(t),d=e=>Math.max(0,Math.min(255,Math.round(e)));return[d(s(i,c,n)),d(s(a,l,n)),d(s(o,u,n))].map(e=>e.toString(16).padStart(2,`0`)).join(``).replace(/^/,`#`)}function l(e,t,n,r=2){e.width=t*r,e.height=n*r;let i=e.getContext(`2d`);return i.scale(r,r),i}function u(e,t,n,r,i,a=.3){let s=e.createRadialGradient(t,n,0,t,n,r);s.addColorStop(0,o(i,a)),s.addColorStop(1,o(i,0)),e.fillStyle=s,e.beginPath(),e.arc(t,n,r,0,Math.PI*2),e.fill()}function d(e,t,n,r,a=50,s=o(i.blue,.05)){for(let i=0;i<a;i++)e.beginPath(),e.arc((Math.sin(r*.001+i*23)*.5+.5)*t,(Math.cos(r*8e-4+i*37)*.5+.5)*n,.6,0,Math.PI*2),e.fillStyle=s,e.fill()}function f(e,t,n,r,i=.015){e.fillStyle=`rgba(0,0,0,${i})`;let a=r*.5%6;for(let r=a;r<n;r+=3)e.fillRect(0,r,t,1)}function p(e,t,n,r,a=o(i.t1,.08)){e.strokeStyle=a,e.lineWidth=1,e.setLineDash([3,3]),e.beginPath(),e.moveTo(t,n),e.lineTo(t,r),e.stroke(),e.setLineDash([])}function m({visible:e,x:r,y:a,content:o,parentW:s}){let c=(0,t.useRef)(null);if((0,t.useLayoutEffect)(()=>{let t=c.current;if(!t)return;let n=t.offsetWidth,l=r-n/2,u=a-58;l<4&&(l=4),l+n>(s??400)-4&&(l=(s??400)-n-4),u<4&&(u=a+16),t.style.transform=`translate(${l}px, ${u}px)`,t.style.opacity=e?`1`:`0`;let d=o&&typeof o==`object`&&o.color?o.color:i.blue;t.style.setProperty(`--tooltip-accent`,d??i.blue)},[e,r,a,s,o]),!o)return null;let l=typeof o==`object`,u=l?o.label:null,d=l?o.value:o,f=l?o.sublabel:null;return(0,n.jsxs)(`div`,{ref:c,style:{position:`absolute`,top:0,left:0,minWidth:80,pointerEvents:`none`,background:i.sf,border:`1px solid ${i.bd}`,borderLeft:`2px solid var(--tooltip-accent)`,borderRadius:6,padding:`6px 10px`,opacity:0,transition:`opacity 0.15s ease`,zIndex:20,fontFamily:`'JetBrains Mono', monospace`},children:[u&&(0,n.jsx)(`div`,{style:{fontFamily:`'DM Sans', sans-serif`,fontSize:10,color:i.t3,marginBottom:2,whiteSpace:`nowrap`},children:u}),(0,n.jsx)(`div`,{style:{fontSize:11,color:i.t1,fontWeight:600,whiteSpace:`nowrap`},children:d}),f&&(0,n.jsx)(`div`,{style:{fontSize:9,color:`var(--tooltip-accent)`,marginTop:2,whiteSpace:`nowrap`},children:f})]})}function h(e,{width:n,height:r,onClick:i,enabled:a=!0}){let o=(0,t.useRef)({x:-1,y:-1,over:!1}),s=(0,t.useRef)(null),c=(0,t.useRef)([]),l=(0,t.useRef)(null),[u,d]=(0,t.useState)({visible:!1,x:0,y:0,content:null}),f=(0,t.useCallback)((e,t,n)=>{l.current&&clearTimeout(l.current),l.current=setTimeout(()=>{d({visible:!0,x:e,y:t,content:n})},30)},[]),p=(0,t.useCallback)(()=>{l.current&&clearTimeout(l.current),d(e=>e.visible?{visible:!1,x:e.x,y:e.y,content:e.content}:e)},[]);return(0,t.useEffect)(()=>{let t=e.current;if(!t||!a)return;let u=e=>{let i=t.getBoundingClientRect(),a=n/i.width,l=r/i.height;o.current.x=(e.clientX-i.left)*a,o.current.y=(e.clientY-i.top)*l,o.current.over=!0;let u=null,d=c.current;for(let e=d.length-1;e>=0;e--)if(d[e].test(o.current.x,o.current.y)){u=d[e];break}let m=s.current;s.current=u?u.id:null,t.style.cursor=u?`pointer`:`default`,u?f((e.clientX-i.left)*a,(e.clientY-i.top)*l,u.data):m&&p()},d=()=>{o.current={x:-1,y:-1,over:!1},s.current&&(s.current=null,t.style.cursor=`default`,p())},m=()=>{if(s.current&&i){let e=c.current.find(e=>e.id===s.current);e&&i(e.id,e.data)}};return t.addEventListener(`mousemove`,u),t.addEventListener(`mouseleave`,d),t.addEventListener(`click`,m),()=>{t.removeEventListener(`mousemove`,u),t.removeEventListener(`mouseleave`,d),t.removeEventListener(`click`,m),l.current&&clearTimeout(l.current)}},[e,n,r,a,i,f,p]),{mouseRef:o,hoveredRef:s,tooltip:u,showTooltip:f,hideTooltip:p,hitZonesRef:c}}function g(e,t,n,r,i,a){e.push({id:t,data:a,test:(e,t)=>(e-n)**2+(t-r)**2<=i*i})}function _(e,t,n,r,i,a,o){e.push({id:t,data:o,test:(e,t)=>e>=n&&e<=n+i&&t>=r&&t<=r+a})}var v=e=>1-(1-e)**3,y=e=>1-(1-e)**4,b=e=>e===1?1:1-2**(-10*e),x=e=>{let t=1.70158;return 1+(t+1)*(e-1)**3+t*(e-1)**2},S=(e,t=.04,n=.001)=>Math.sin(e*t)*Math.exp(-Math.min(e*n,4)),C=(e,t,n,r=v)=>{let i=Math.min(.06,.5/n),a=t*i,o=1-(n-1)*i;return r(Math.max(0,Math.min((e-a)/o,1)))};function w(e,t,n=.12){e.forEach((r,i)=>{let a=i===t?1:0,o=r+(a-r)*n;Math.abs(o-a)<.005?a===0?e.delete(i):e.set(i,1):e.set(i,o)}),t&&!e.has(t)&&e.set(t,0)}var T=760,E=250;function D({rows:e=[],variant:a,className:s,colors:c}){let d=(0,t.useRef)(null),f=(0,t.useRef)(new Map),_=(0,t.useRef)(0),{mouseRef:v,hoveredRef:y,tooltip:x,hitZonesRef:C}=h(d,{width:T,height:E});return(0,t.useEffect)(()=>{let t=d.current;if(!t)return;let n=l(t,T,E);_.current=0;let r=c?.line??i.blue,s=c?.point??i.blue,m=c?.axisLine??i.bd,h=c?.areaFill??i.blue,x={top:24,right:24,bottom:44,left:24},D=T-x.left-x.right,O=E-x.top-x.bottom,k,A=()=>{_.current++;let t=_.current;if(n.clearRect(0,0,T,E),e.length<2){k=requestAnimationFrame(A);return}let c=e.map(e=>e.pricing??0),l=Math.max(100,...c),d=t=>x.left+t/(e.length-1)*D,j=e=>x.top+(1-e/l)*O,M=b(Math.min(t/48,1)),N=Math.max(2,Math.floor(M*e.length));w(f.current,y.current),C.current=[],n.strokeStyle=o(i.bd,.2),n.lineWidth=.5;for(let e=0;e<=4;e++){let t=x.top+e/4*O;n.beginPath(),n.moveTo(x.left,t),n.lineTo(x.left+D,t),n.stroke()}if(n.strokeStyle=o(m,.4),n.lineWidth=1,n.setLineDash([]),n.beginPath(),n.moveTo(x.left,j(0)),n.lineTo(x.left+D,j(0)),n.stroke(),v.current.over&&y.current){let e=parseInt(y.current.split(`-`)[1]);isNaN(e)||p(n,d(e),x.top,x.top+O)}if(a===`area`&&N>1){let t=n.createLinearGradient(0,x.top,0,x.top+O);t.addColorStop(0,o(h,.12)),t.addColorStop(1,o(h,0)),n.fillStyle=t,n.beginPath(),n.moveTo(d(0),x.top+O);for(let t=0;t<N;t++)n.lineTo(d(t),j(e[t].pricing??0));n.lineTo(d(N-1),x.top+O),n.closePath(),n.fill()}if(N>1){n.strokeStyle=o(r,.85),n.lineWidth=2,n.setLineDash([]),n.beginPath();for(let t=0;t<N;t++){let r=d(t),i=j(e[t].pricing??0);t===0?n.moveTo(r,i):n.lineTo(r,i)}n.stroke()}for(let r=0;r<N;r++){let c=d(r),l=j(e[r].pricing??0),p=`sc-${r}`,m=f.current.get(p)??0,h=r===e.length-1;g(C.current,p,c,l,12,{label:e[r].vendor,value:String(e[r].pricing??0),color:h?i.red:s}),m>0&&u(n,c,l,16*m,s,.2*m);let _=h?S(t,.05,5e-4):0,v=a===`area`?5:6;h?(n.shadowColor=o(i.red,.5),n.shadowBlur=(8+_*4)*(1+m*.5),n.fillStyle=i.red,n.beginPath(),n.arc(c,l,(v+_*1.5)*(1+m*.3),0,Math.PI*2),n.fill(),n.shadowBlur=0):(n.fillStyle=o(s,.7+m*.3),n.beginPath(),n.arc(c,l,v+m*2,0,Math.PI*2),n.fill()),n.font=`10px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.6+m*.3),n.textAlign=`center`,n.fillText(e[r].vendor,c,E-14)}k=requestAnimationFrame(A)};return A(),()=>cancelAnimationFrame(k)},[e,a,c]),(0,n.jsx)(r,{className:s,children:(0,n.jsxs)(`div`,{style:{position:`relative`,width:T,height:E},children:[(0,n.jsx)(`canvas`,{ref:d,role:`img`,"aria-label":`${a} chart`,style:{width:T,height:E,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...x,parentW:T,parentH:E})]})})}function O({rows:e=[],className:t,colors:r}){return(0,n.jsx)(D,{rows:e,variant:`area`,className:t,colors:r})}var k=760,A=280;function j({rows:e=[],className:s,colors:c}){let d=(0,t.useRef)(null),f=(0,t.useRef)(new Map),p=(0,t.useRef)(0),{hoveredRef:g,tooltip:v,hitZonesRef:b}=h(d,{width:k,height:A});return(0,t.useEffect)(()=>{let t=d.current;if(!t)return;let n=l(t,k,A);p.current=0;let r=c?.bars??a,s=c?.axisLine??i.bd,m=c?.valueLabel??i.t2,h={top:24,right:24,bottom:56,left:24},v=A-h.top-h.bottom,x=(k-h.left-h.right)/Math.max(e.length,1),S=Math.max(100,...e.map(e=>e.pricing??0)),T=h.top+v,E,D=()=>{p.current++;let t=p.current;n.clearRect(0,0,k,A);let a=y(Math.min(t/48,1));w(f.current,g.current),b.current=[],n.strokeStyle=o(s,.4),n.lineWidth=1,n.setLineDash([]),n.beginPath(),n.moveTo(h.left,T),n.lineTo(k-h.right,T),n.stroke(),e.forEach((t,s)=>{let c=h.left+s*x,l=C(a,s,e.length,y),d=S>0?(t.pricing??0)/S*v:0,p=Math.max(d>0?4:0,d*l),g=r[s%r.length],w=f.current.get(t.id??`bar-${s}`)??0;_(b.current,t.id??`bar-${s}`,c+4,T-p,x-8,p,{label:t.vendor,value:String(t.pricing??0),color:g}),p>0&&(w>0&&u(n,c+x/2,T-p/2,x*.8,g,.12*w),n.shadowColor=o(g,.2*(w>0?w:0)),n.shadowBlur=w>0?6:0,n.fillStyle=o(g,.5+w*.25),n.beginPath(),n.roundRect(c+4,T-p,x-8,p,[4,4,0,0]),n.fill(),n.shadowBlur=0,w>0&&(n.strokeStyle=o(g,.4*w),n.lineWidth=1,n.beginPath(),n.roundRect(c+4,T-p,x-8,p,[4,4,0,0]),n.stroke())),l>.5&&p>0&&(n.globalAlpha=Math.min(1,(l-.5)*2),n.font=`bold 10px 'JetBrains Mono', monospace`,n.fillStyle=w>0?g:o(m,.7),n.textAlign=`center`,n.fillText(String(t.pricing??``),c+x/2,T-p-6),n.globalAlpha=1),n.font=`${w>0?`bold `:``}9px 'JetBrains Mono', monospace`,n.fillStyle=w>0?g:o(i.t3,.6),n.textAlign=`center`,n.fillText(t.vendor,c+x/2,A-14)}),E=requestAnimationFrame(D)};return D(),()=>cancelAnimationFrame(E)},[e,c]),(0,n.jsx)(r,{className:s,children:(0,n.jsxs)(`div`,{style:{position:`relative`,width:k,height:A},children:[(0,n.jsx)(`canvas`,{ref:d,role:`img`,"aria-label":`bar chart`,style:{width:k,height:A,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...v,parentW:k,parentH:A})]})})}var M=680,N=300,ee=[i.green,i.blue,i.cyan,i.amber,i.red];function te({contractors:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(0),c=(0,t.useRef)(new Map),p=[...e].sort((e,t)=>t.commitmentPct-e.commitmentPct),{hoveredRef:_,tooltip:y,hitZonesRef:b}=h(a,{width:M,height:N});return(0,t.useEffect)(()=>{let e=a.current;if(!e)return;let t=l(e,M,N);s.current=0;let n=M*.13,r=M*.08,m=N*.08,h=N*.14,y=M-n-r,x,S=()=>{s.current++;let e=s.current;t.clearRect(0,0,M,N),b.current=[],c.current.forEach((e,t)=>{let n=t===_.current?1:0,r=e+(n-e)*.12;Math.abs(r-n)<.005?n===0?c.current.delete(t):c.current.set(t,1):c.current.set(t,r)}),_.current&&!c.current.has(_.current)&&c.current.set(_.current,0),d(t,M,N,e,40,o(i.blue,.04)),p.forEach((r,a)=>{let s=ee[a%ee.length],l=c.current.get(r.id)??0,d=m+a*(h+10);t.fillStyle=o(s,.04+l*.04),t.beginPath(),t.roundRect(n,d,y,h,3),t.fill(),t.strokeStyle=o(s,.08),t.lineWidth=1,t.setLineDash([4,4]),t.beginPath(),t.moveTo(n,d+h/2),t.lineTo(n+y,d+h/2),t.stroke(),t.setLineDash([]);let f=r.commitmentPct/100,p=n+y*Math.min(f,f*v(Math.min(1,e*.005)));if(p>n+4){let e=t.createLinearGradient(n,0,p,0);e.addColorStop(0,o(s,.02)),e.addColorStop(1,o(s,.25+l*.15)),t.fillStyle=e,t.beginPath(),t.roundRect(n,d+2,p-n,h-4,2),t.fill()}u(t,p,d+h/2,18+l*8,s,.3+l*.2),t.beginPath(),t.arc(p,d+h/2,5+l*2,0,Math.PI*2),t.fillStyle=o(s,.9),t.fill(),g(b.current,r.id,p,d+h/2,14,{label:r.name,value:`${r.commitmentPct}% commitment`,sublabel:`Base: £${r.base}M · Variations: £${r.variations}M`,color:s}),t.font=`bold 10px 'JetBrains Mono', monospace`,t.fillStyle=o(s,.9+l*.1),t.textAlign=`left`,t.textBaseline=`middle`,t.fillText(`${r.commitmentPct}%`,p+10,d+h/2),t.font=`${l>0?`bold `:``}10px 'JetBrains Mono', monospace`,t.fillStyle=l>0?s:o(i.t2,.8),t.textAlign=`right`,t.fillText(r.shortName,n-8,d+h/2)}),t.strokeStyle=o(i.t3,.3),t.lineWidth=1,t.setLineDash([]),t.beginPath(),t.moveTo(n+y,m),t.lineTo(n+y,m+(p.length-1)*(h+10)+h),t.stroke(),f(t,M,N,e,.015),x=requestAnimationFrame(S)};return S(),()=>cancelAnimationFrame(x)},[p]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:M,height:N},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Commitment race — contractors ranked by commitment percentage`,style:{width:M,height:N,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...y,parentW:M,parentH:N})]})}var ne=480,re=340;function ie({pct:e,confirmed:r,total:a,"data-testid":s}){let c=(0,t.useRef)(null),d=(0,t.useRef)(0);return(0,t.useEffect)(()=>{let t=c.current;if(!t)return;let n=l(t,ne,re);d.current=0;let s=ne/2,f=Math.PI,p=2*Math.PI,m=Math.PI,h,g=()=>{d.current++;let t=d.current;n.clearRect(0,0,ne,re);let c=v(Math.min(t/80,1)),l=x(Math.min(t/72,1));n.beginPath(),n.arc(s,220,120,f,p),n.strokeStyle=o(i.bd,.35),n.lineWidth=46,n.stroke(),[{start:0,end:.33,color:i.red},{start:.33,end:.66,color:i.amber},{start:.66,end:1,color:i.green}].forEach(e=>{let t=f+e.start*m,r=f+e.end*m;n.beginPath(),n.arc(s,220,194/2,t,r),n.strokeStyle=o(e.color,.12),n.lineWidth=42,n.stroke()}),[{label:`Low`,angle:f+.16*m},{label:`Mid`,angle:f+.5*m},{label:`High`,angle:f+.84*m}].forEach(({label:e,angle:t})=>{let r=s+Math.cos(t)*166,a=220+Math.sin(t)*166;n.font=`13px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.55),n.textAlign=`center`,n.fillText(e,r,a+3)});let _=f+e/100*m*c,y=e>=66?i.green:e>=33?i.amber:i.red;u(n,s+Math.cos(_)*194/2,220+Math.sin(_)*194/2,18,y,.35*c),n.beginPath(),n.arc(s,220,194/2,f,_),n.strokeStyle=o(y,.7*c),n.lineWidth=38,n.lineCap=`round`,n.stroke(),n.lineCap=`butt`;let b=f+e/100*m*l,S=s+Math.cos(b)*82,C=220+Math.sin(b)*82,w=s-Math.cos(b)*14,T=220-Math.sin(b)*14;n.strokeStyle=o(y,.18*l),n.lineWidth=6,n.lineCap=`round`,n.beginPath(),n.moveTo(w,T),n.lineTo(S,C),n.stroke(),n.strokeStyle=o(i.t1,.92*l),n.lineWidth=2,n.lineCap=`round`,n.beginPath(),n.moveTo(w,T),n.lineTo(S,C),n.stroke(),n.beginPath(),n.arc(S,C,3,0,Math.PI*2),n.fillStyle=o(y,.9*l),n.fill(),u(n,s,220,20,y,.25*l),n.beginPath(),n.arc(s,220,9,0,Math.PI*2),n.strokeStyle=o(y,.5*l),n.lineWidth=1.5,n.stroke(),n.beginPath(),n.arc(s,220,5,0,Math.PI*2),n.fillStyle=i.t1,n.fill(),c>.5&&(n.globalAlpha=Math.min(1,(c-.5)/.5),n.font=`bold 22px 'JetBrains Mono', monospace`,n.fillStyle=y,n.textAlign=`center`,n.fillText(`${Math.round(e*l)}%`,s,182),n.globalAlpha=1),c>.7&&(n.globalAlpha=Math.min(1,(c-.7)/.3),n.font=`13px 'JetBrains Mono', monospace`,n.fillStyle=i.t2,n.textAlign=`center`,n.fillText(`NCEs confirmed`,s,252),n.font=`bold 11px 'JetBrains Mono', monospace`,n.fillStyle=i.t2,n.fillText(`${r} of ${a} NCEs are confirmed compensation events`,s,272),n.globalAlpha=1);for(let e=0;e<=10;e++){let t=f+e/10*m;if(n.strokeStyle=o(i.bd,.5),n.lineWidth=e%5==0?1.5:.8,n.beginPath(),n.moveTo(s+Math.cos(t)*122,220+Math.sin(t)*122),n.lineTo(s+Math.cos(t)*128,220+Math.sin(t)*128),n.stroke(),e%5==0){let r=s+Math.cos(t)*138,a=220+Math.sin(t)*138;n.font=`11px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.45),n.textAlign=`center`,n.fillText(`${e*10}%`,r,a+3)}}h=requestAnimationFrame(g)};return g(),()=>cancelAnimationFrame(h)},[e,r,a]),(0,n.jsx)(`div`,{"data-testid":s,style:{position:`relative`,width:ne,height:re},children:(0,n.jsx)(`canvas`,{ref:c,role:`img`,"aria-label":`Compensation event gauge — ${e}% of NCEs confirmed as compensation events`,style:{width:ne,height:re,display:`block`}})})}function ae(e,n,r,i,a=!0,o={}){let s=(0,t.useRef)(0),{easing:c=v,durationFrames:l=48}=o;(0,t.useEffect)(()=>{let t=e.current;if(!t||!n||!r)return;let o=t.getContext(`2d`);if(!o)return;t.width=n*2,t.height=r*2,o.scale(2,2);let u;s.current=0;let d=()=>{s.current++;let e=s.current;o.clearRect(0,0,n,r);let t=a?Math.min(e/l,1):1;if(i(o,c(t),e),t<1)u=requestAnimationFrame(d);else{let e=()=>{s.current++,o.clearRect(0,0,n,r),i(o,1,s.current),u=requestAnimationFrame(e)};u=requestAnimationFrame(e)}};return d(),()=>cancelAnimationFrame(u)},[n,r,a])}var P=780,oe=234,se=130,ce=52,le=[i.blue,i.cyan,i.amber,i.purple,i.green],ue=[`Base Value`,`Variations`,`Commitment`],de=[`Base`,`Var`,`Commit`];function fe({contractors:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(new Map),{hoveredRef:c,tooltip:l,hitZonesRef:p}=h(a,{width:P,height:oe}),_=(0,t.useMemo)(()=>{let t=Math.max(...e.map(e=>e.base)),n=Math.max(...e.map(e=>e.variations));return e.map((e,r)=>{let i=P*(.12+r*.19),a=se,o=Math.min(P*.075,ce),s=le[r%le.length],c=[e.base/t*100,e.variations/n*100,e.commitmentPct],l=[`£${e.base}M`,`£${e.variations}M`,`${e.commitmentPct}%`],u=c.map((e,t)=>{let n=-Math.PI/2+t/ue.length*Math.PI*2,r=e/100,s=o*Math.max(.08,r);return{name:ue[t],short:de[t],label:l[t],val:Math.round(e),x:i+Math.cos(n)*s,y:a+Math.sin(n)*s,angle:n,norm:r}}),d=u.reduce((e,t)=>e+t.x,0)/u.length,f=u.reduce((e,t)=>e+t.y,0)/u.length,p=Math.sqrt(u.reduce((e,t)=>e+(t.x-d)**2+(t.y-f)**2,0)/u.length);return{...e,cx:i,cy:a,baseR:o,stars:u,scatter:p,color:s}})},[e]);return ae(a,P,oe,(e,t,n)=>{w(s.current,c.current),p.current=[],d(e,P,oe,n,30),_.forEach((t,r)=>{let a=t.color,c=`constellation-${r}`,l=s.current.get(c)??0;e.beginPath(),e.arc(t.cx,t.cy,t.baseR+5,0,Math.PI*2),e.strokeStyle=o(i.bd,.08+.08*l),e.lineWidth=.5,e.stroke(),e.beginPath(),t.stars.forEach((t,n)=>{n===0?e.moveTo(t.x,t.y):e.lineTo(t.x,t.y)}),e.closePath(),e.fillStyle=o(a,.04+.03*l),e.fill(),e.strokeStyle=o(a,.15+.1*l),e.lineWidth=.8,e.stroke(),t.stars.forEach((i,c)=>{let l=S(n,.05,5e-4)*.3+.7,u=3.5*l,d=`star-${r}-${c}`,f=s.current.get(d)??0,m=e.createRadialGradient(i.x,i.y,0,i.x,i.y,u*4);m.addColorStop(0,o(a,(.2+.1*f)*l)),m.addColorStop(1,o(a,0)),e.fillStyle=m,e.beginPath(),e.arc(i.x,i.y,u*4,0,Math.PI*2),e.fill(),e.beginPath(),e.arc(i.x,i.y,u+f*2,0,Math.PI*2),e.fillStyle=o(a,(.8+.2*f)*l),e.fill();let h=Math.sin(i.angle)<-.3;e.textAlign=`center`,e.textBaseline=`middle`,h?(e.font=`8px 'DM Sans', sans-serif`,e.fillStyle=o(a,.5+.15*f),e.fillText(i.short,i.x,i.y-24),e.font=`bold 11px 'JetBrains Mono', monospace`,e.fillStyle=o(a,.8+.15*f),e.fillText(i.label,i.x,i.y-11)):(e.font=`8px 'DM Sans', sans-serif`,e.fillStyle=o(a,.5+.15*f),e.fillText(i.short,i.x,i.y+11),e.font=`bold 11px 'JetBrains Mono', monospace`,e.fillStyle=o(a,.8+.15*f),e.fillText(i.label,i.x,i.y+24)),g(p.current,d,i.x,i.y,u*4+2,{label:i.name,value:i.label,sublabel:t.shortName,color:a})}),l>0&&u(e,t.cx,t.cy,16*l,a,.15*l),e.beginPath(),e.arc(t.cx,t.cy,t.baseR+12,0,Math.PI*2),e.strokeStyle=o(a,.1+S(n,.03,5e-4)*.05),e.lineWidth=1,e.stroke(),e.font=`bold 11px 'DM Sans', sans-serif`,e.textAlign=`center`,e.textBaseline=`alphabetic`,e.fillStyle=o(i.t2,.65+l*.25),e.fillText(t.shortName,t.cx,t.cy+t.baseR+26),g(p.current,c,t.cx,t.cy,t.baseR+5,{label:t.name,value:`£${t.totalCommitment}M total`,sublabel:`${t.commitmentPct}% committed · scatter ${t.scatter.toFixed(1)}`,color:a})}),e.font=`11px 'DM Sans', sans-serif`,e.textAlign=`center`,e.textBaseline=`middle`,e.fillStyle=o(i.t4,.55),e.fillText(`▲ top = Base value · ▼▸ lower-right = Variations · ◂▼ lower-left = Commitment % · hover stars for details`,P/2,oe-14),f(e,P,oe,n,.012)},!0),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:P,height:oe},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Contract value breakdown per contractor — multi-KPI constellation chart`,style:{width:P,height:oe,display:`block`}}),(0,n.jsx)(m,{...l,parentW:P,parentH:oe})]})}var pe=680,me=220,he=[i.blue,i.cyan,i.amber,i.purple,i.green],F={left:8,right:64,top:16,bottom:38},I=88,L=18;function ge({data:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(new Map),{hoveredRef:c,tooltip:l,hitZonesRef:d}=h(a,{width:pe,height:me}),{contractors:f,totals:p}=e,g=f.length,v=Math.max(...f.map(e=>e.totalCommitment),1),b=pe-F.left-I-F.right,x=g>1?(me-F.top-F.bottom-g*L)/(g-1):0;return ae(a,pe,me,(e,t)=>{w(s.current,c.current),d.current=[],f.forEach((n,r)=>{let a=he[r%he.length],c=C(t,r,g,y),l=F.top+r*(L+x),f=F.left+I,p=s.current.get(n.id)??0,m=n.base/v*b*c,h=n.totalCommitment/v*b*c,S=h-m;e.font=`${p>0?`bold `:``}10px 'DM Sans', sans-serif`,e.fillStyle=p>0?a:o(i.t2,.8),e.textAlign=`right`,e.textBaseline=`middle`,e.fillText(n.shortName,f-8,l+L/2),e.fillStyle=o(i.bd,.25),e.beginPath(),e.roundRect(f,l,b,L,4),e.fill(),m>0&&(p>0&&u(e,f+m/2,l+L/2,m*.3,a,.1*p),e.fillStyle=o(a,.5+p*.15),e.beginPath(),e.roundRect(f,l,m,L,4),e.fill()),S>2&&(e.fillStyle=o(a,.22+p*.08),e.beginPath(),e.roundRect(f+m,l,S,L,[0,4,4,0]),e.fill(),e.setLineDash([2,3]),e.strokeStyle=o(a,.55),e.lineWidth=1,e.beginPath(),e.moveTo(f+m,l+3),e.lineTo(f+m,l+L-3),e.stroke(),e.setLineDash([])),p>0&&h>0&&(e.strokeStyle=o(a,.5*p),e.lineWidth=1,e.setLineDash([]),e.beginPath(),e.roundRect(f,l,h,L,4),e.stroke()),c>.35&&(e.globalAlpha=Math.min(1,(c-.35)/.4),e.font=`bold 9px 'JetBrains Mono', monospace`,e.fillStyle=p>0?a:i.t2,e.textAlign=`left`,e.textBaseline=`middle`,e.fillText(`£${n.totalCommitment}M`,f+h+6,l+L/2),e.globalAlpha=1),_(d.current,n.id,f,l,Math.max(h,1),L,{label:n.name,value:`£${n.totalCommitment}M total`,sublabel:`Base £${n.base}M + Var £${n.variations}M · ${n.commitmentPct}% committed`,color:a})});let n=me-14;e.textBaseline=`middle`,e.font=`7px 'DM Sans', sans-serif`,e.textAlign=`left`,e.fillStyle=o(i.cyan,.5),e.beginPath(),e.roundRect(F.left+I,n-3,14,6,2),e.fill(),e.fillStyle=o(i.t3,.45),e.fillText(`base value`,F.left+I+18,n),e.fillStyle=o(i.cyan,.22),e.beginPath(),e.roundRect(F.left+I+94,n-3,14,6,2),e.fill(),e.setLineDash([2,3]),e.strokeStyle=o(i.cyan,.5),e.lineWidth=.5,e.beginPath(),e.moveTo(F.left+I+101,n-3),e.lineTo(F.left+I+101,n+3),e.stroke(),e.setLineDash([]),e.fillStyle=o(i.t3,.45),e.fillText(`approved variations`,F.left+I+112,n),e.font=`bold 8px 'JetBrains Mono', monospace`,e.textAlign=`right`,e.fillStyle=o(i.t2,.6),e.fillText(`Portfolio: £${p.totalCommitment}M`,pe-8,n)},!0,{easing:y}),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:pe,height:me},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Total contract value per contractor — horizontal bar chart`,style:{width:pe,height:me,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...l,parentW:pe,parentH:me})]})}var R=780,z=240,_e=12,ve=10,ye=[`Highest exposure`,`Elevated risk`,`Moderate exposure`,`Moderate exposure`,`Low exposure`];function be({contractors:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(0),c=(0,t.useRef)(new Map),{hoveredRef:d,tooltip:p,hitZonesRef:g}=h(a,{width:R,height:z}),v=[...e].sort((e,t)=>t.openCount-e.openCount).slice(0,5),y=v.reduce((e,t)=>e+t.openCount,0);return(0,t.useEffect)(()=>{let e=a.current;if(!e)return;let t=l(e,R,z);s.current=0;let n=Math.min(5,v.length),r=(R-2*_e-(n-1)*ve)/n,p=z*.84,m=z*.08,h,b=()=>{s.current++;let e=s.current;t.clearRect(0,0,R,z),g.current=[],c.current.forEach((e,t)=>{let n=t===d.current?1:0,r=e+(n-e)*.12;Math.abs(r-n)<.005?n===0?c.current.delete(t):c.current.set(t,1):c.current.set(t,r)}),d.current&&!c.current.has(d.current)&&c.current.set(d.current,0),v.forEach((n,a)=>{let s=a===0,l=s?i.red:a===1?i.amber:i.blue,d=_e+a*(r+ve),f=c.current.get(n.id)??0,h=f*8,v=d-h/2,b=r+h,x=s?S(e,.04,3e-4)*.06+.06:0;t.fillStyle=o(l,.08+f*.07),t.beginPath(),t.roundRect(v,m,b,p,6),t.fill(),t.strokeStyle=o(l,.2+f*.4+x),t.lineWidth=s?1.5:1,t.stroke(),(f>.01||s)&&u(t,v+b/2,m+p/2,b*.55,l,x+f*.14),t.font=`bold 8px 'JetBrains Mono', monospace`,t.textAlign=`left`,t.textBaseline=`top`,t.fillStyle=o(l,.5+f*.35),t.fillText(`#${a+1}`,v+7,m+6);let C=r*.28,w=v+b/2,T=m+p*.38,E=t.createRadialGradient(w,T-C*.2,0,w,T,C);E.addColorStop(0,o(l,.5+f*.2)),E.addColorStop(1,o(l,.2+f*.1)),t.beginPath(),t.arc(w,T,C,0,Math.PI*2),t.fillStyle=E,t.fill(),t.strokeStyle=o(l,.4+f*.3),t.lineWidth=1,t.stroke(),t.font=`bold ${Math.min(10,r*.11)}px 'JetBrains Mono', monospace`,t.textAlign=`center`,t.textBaseline=`middle`,t.fillStyle=o(i.t1,.9),t.fillText(n.shortName,w,T),t.font=`bold ${Math.min(18,r*.18)}px 'JetBrains Mono', monospace`,t.textBaseline=`alphabetic`,t.fillStyle=o(l,.9+f*.1),t.fillText(String(n.openCount),w,m+p*.76),t.font=`8px 'JetBrains Mono', monospace`,t.fillStyle=o(i.t2,.6),t.fillText(`open EWs`,w,m+p*.88);let D=Math.round(n.openCount/y*100),O=ye[a]??`Low exposure`;_(g.current,n.id,d,m,r,p,{label:n.name,value:`${n.openCount} open EWs · ${D}% of total`,sublabel:`Rank #${a+1} · ${O}`,color:l})}),f(t,R,z,e,.015),h=requestAnimationFrame(b)};return b(),()=>cancelAnimationFrame(h)},[v,y]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:R,height:z},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Contractor rank — open EW count per contractor`,style:{width:R,height:z,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...p,parentW:R,parentH:z})]})}var B=680,V=260;function xe({categories:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(0),c=(0,t.useRef)(new Map),{hoveredRef:p,tooltip:_,hitZonesRef:v}=h(a,{width:B,height:V});return(0,t.useEffect)(()=>{let t=a.current;if(!t)return;let n=l(t,B,V);s.current=0;let r=e.length,m=Math.max(...e.map(e=>e.count),1),h=m,_=B*.05,y=V*.1,b=B*.9/r,x=V*.7/h,C=e.reduce((e,t)=>e+t.count,0),w,T=()=>{s.current++;let t=s.current;n.clearRect(0,0,B,V),v.current=[],c.current.forEach((e,t)=>{let n=t===p.current?1:0,r=e+(n-e)*.12;Math.abs(r-n)<.005?n===0?c.current.delete(t):c.current.set(t,1):c.current.set(t,r)}),p.current&&!c.current.has(p.current)&&c.current.set(p.current,0),d(n,B,V,t,40,o(i.blue,.04)),e.forEach((e,r)=>{let a=e.count===m,s=a?i.cyan:i.blue,l=c.current.get(`${e.category}-col`)??0;for(let i=0;i<h;i++){let d=_+r*b+b/2,f=y+i*x+x/2,p=Math.min(b,x)*.38;if(i>=m-e.count){let m=p*(1+(S(t,.04,5e-4)+Math.sin(r*.6+i*1.2)*.3)*.12);(a||l>.01)&&u(n,d,f,m*3,s,(a?.2:.1)+l*.1),n.beginPath(),n.arc(d,f,m,0,Math.PI*2),n.fillStyle=o(s,a?.8:.5+l*.2),n.fill();let h=`${e.category}-${i}`;g(v.current,h,d,f,p+4,{label:e.fullName,value:`${e.count} Early Warnings`,sublabel:`${Math.round(e.count/C*100)}% of total`,color:s}),c.current.get(`${e.category}-col`)}else n.beginPath(),n.arc(d,f,1,0,Math.PI*2),n.fillStyle=o(s,.08),n.fill()}let d=y+h*x+16;n.font=`${a?`bold `:``}9px 'JetBrains Mono', monospace`,n.textAlign=`center`,n.textBaseline=`alphabetic`,n.fillStyle=a?i.cyan:o(i.t2,.65),n.fillText(e.category,_+r*b+b/2,d)}),f(n,B,V,t,.015),w=requestAnimationFrame(T)};return T(),()=>cancelAnimationFrame(w)},[e]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:B,height:V},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Early Warning count by category — breathing dot grid`,style:{width:B,height:V,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{..._,parentW:B,parentH:V})]})}function Se({rows:e=[],className:t,colors:r}){return(0,n.jsx)(D,{rows:e,variant:`line`,className:t,colors:r})}var Ce=[`#6bbcff`,`#5fe6dd`,`#d7bc6d`,`#95a9ff`,`#7fb58a`,`#ee8a8a`],we={nodes:[{id:`supplier-x`,name:`Supplier X`,valueLabel:`Si +0.12%`},{id:`bf3-superheat`,name:`BF-3 Superheat`,valueLabel:`22°C (target 34)`},{id:`ccm3-solidification`,name:`CCM-3 Solidification`,valueLabel:`Rate deviation`},{id:`grade-risk`,name:`Grade Risk`,valueLabel:`Automotive 74%`}],links:[{source:`supplier-x`,target:`bf3-superheat`,value:92},{source:`bf3-superheat`,target:`ccm3-solidification`,value:87},{source:`ccm3-solidification`,target:`grade-risk`,value:74}]};function Te({rows:e=[],className:t,colors:r}){let i=r?.slices??Ce;return(0,n.jsx)(`div`,{className:[`d3-mini-bars`,t].filter(Boolean).join(` `),children:e.map(([e,t,r],a)=>(0,n.jsxs)(`div`,{className:`d3-mini-row`,children:[(0,n.jsx)(`span`,{children:e}),(0,n.jsx)(`div`,{className:`d3-mini-track`,children:(0,n.jsxs)(`svg`,{viewBox:`0 0 100 12`,className:`d3-mini-svg`,"aria-hidden":`true`,children:[(0,n.jsx)(`rect`,{x:`0`,y:`0`,width:`100`,height:`12`,rx:`6`,className:`d3-mini-track-fill`}),(0,n.jsx)(`rect`,{x:`0`,y:`0`,width:Math.max(0,Math.min(100,t)),height:`12`,rx:`6`,className:`d3-mini-fill tone-${a%Ce.length}`,fill:i[a%i.length]})]})}),(0,n.jsx)(`span`,{children:r})]},`${e}-${a}`))})}var Ee=680,H=320;function De({total:e,byContractor:r,"data-testid":s}){let c=(0,t.useRef)(null),d=(0,t.useRef)(new Map),f=(0,t.useRef)(0),{hoveredRef:p,tooltip:_,hitZonesRef:y}=h(c,{width:Ee,height:H});return(0,t.useEffect)(()=>{let t=c.current;if(!t)return;let n=l(t,Ee,H);f.current=0;let s=H/2,m=Ee-80,h=Math.max(...r.map(e=>e.count)),_=(H-60)/(r.length-1),b=r.map((e,t)=>({x:m,y:30+t*_})),x,S=()=>{f.current++;let t=f.current;n.clearRect(0,0,Ee,H);let c=v(Math.min(t/72,1));w(d.current,p.current),y.current=[],u(n,88,s,48*c,i.blue,.15*c),r.forEach((t,l)=>{let f=a[l%a.length],p=C(c,l,r.length,v),_=b[l],x=d.current.get(t.id)??0,S=Math.max(1.5,t.count/h*6);if(p<.01)return;let w=88+(m-88)*.4,T=s,E=88+(m-88)*.6,D=_.y,O=p;n.beginPath();for(let e=0;e<=40;e++){let t=e/40*O,r=(1-t)**3*88+3*(1-t)**2*t*w+3*(1-t)*t**2*E+t**3*_.x,i=(1-t)**3*s+3*(1-t)**2*t*T+3*(1-t)*t**2*D+t**3*_.y;e===0?n.moveTo(r,i):n.lineTo(r,i)}if(n.strokeStyle=o(f,x>0?.8:.45),n.lineWidth=S*(x>0?1.3:1),n.stroke(),p>.85){let r=Math.min(1,(p-.85)/.15),a=4+t.count/h*12;u(n,_.x,_.y,a*2.5,f,(.25+x*.2)*r),n.beginPath(),n.arc(_.x,_.y,a*r,0,Math.PI*2),n.fillStyle=o(f,(.7+x*.2)*r),n.fill(),g(y.current,t.id,_.x,_.y,a+8,{label:t.name,value:`${t.count} NCEs raised`,sublabel:`${Math.round(t.count/e*100)}% of all NCEs`,color:f}),n.globalAlpha=r,n.font=`bold 9px 'JetBrains Mono', monospace`,n.fillStyle=x>0?f:o(i.t2,.85),n.textAlign=`left`,n.fillText(t.shortName,_.x+a+6,_.y-3),n.font=`bold 11px 'JetBrains Mono', monospace`,n.fillStyle=x>0?f:i.t1,n.fillText(String(t.count),_.x+a+6,_.y+10),n.globalAlpha=1}}),n.beginPath(),n.arc(88,s,32*c,0,Math.PI*2),n.fillStyle=i.bgL,n.fill(),n.strokeStyle=o(i.blue,.6*c),n.lineWidth=2,n.stroke(),c>.4&&(n.globalAlpha=Math.min(1,(c-.4)/.4),n.font=`bold 18px 'JetBrains Mono', monospace`,n.fillStyle=i.t1,n.textAlign=`center`,n.fillText(String(e),88,s+5),n.font=`8px 'JetBrains Mono', monospace`,n.fillStyle=i.t3,n.fillText(`NCEs`,88,s+18),n.globalAlpha=1),x=requestAnimationFrame(S)};return S(),()=>cancelAnimationFrame(x)},[e,r]),(0,n.jsxs)(`div`,{"data-testid":s,style:{position:`relative`,width:Ee,height:H},children:[(0,n.jsx)(`canvas`,{ref:c,role:`img`,"aria-label":`NCE fault tree — NCEs per contractor as branching tree`,style:{width:Ee,height:H,display:`block`}}),(0,n.jsx)(m,{..._,parentW:Ee,parentH:H})]})}var Oe=192,U=Oe,ke=Oe+80;function Ae({rows:e=[],variant:s,className:d,colors:f}){let p=(0,t.useRef)(null),_=(0,t.useRef)(new Map),v=(0,t.useRef)(0),y=f?.slices??a,{hoveredRef:b,tooltip:x,hitZonesRef:C}=h(p,{width:U,height:ke});return(0,t.useEffect)(()=>{let t=p.current;if(!t)return;let n=l(t,U,ke);v.current=0;let r=U/2,a=Oe/2,d=Oe*.4,f=s===`donut`?Oe*.21:0,m=e.reduce((e,t)=>e+(t.pricing??0),0)||1,h,x=()=>{v.current++;let t=v.current;n.clearRect(0,0,U,ke);let l=1-(1-Math.min(t/48,1))**3;w(_.current,b.current),C.current=[];let p=-Math.PI/2;e.forEach((e,s)=>{let c=(e.pricing??0)/m,h=c*Math.PI*2*l,v=p+h,b=y[s%y.length],x=_.current.get(e.id??`sl-${s}`)??0,w=p+h/2,T=(d+f)/2,E=r+Math.cos(w)*T,D=a+Math.sin(w)*T,O=(d-f)/2+8;g(C.current,e.id??`sl-${s}`,E,D,O,{label:e.vendor,value:`${e.pricing??0} (${Math.round(c*100)}%)`,color:b}),x>0&&u(n,E,D,O*2*x,b,.2*x);let k=S(t,.03,3e-4),A=d+x*6+(x>0?k*2:0);n.beginPath(),n.moveTo(r+Math.cos(p)*f,a+Math.sin(p)*f),n.arc(r,a,A,p,v),f>0?n.arc(r,a,f,v,p,!0):n.lineTo(r,a),n.closePath(),n.fillStyle=o(b,.7+x*.2),n.fill(),n.strokeStyle=o(i.bg,.8),n.lineWidth=1.5,n.stroke(),p=v}),s===`donut`&&e.length>0&&u(n,r,a,f*.8,i.blue,.06);let T=Oe+12;e.forEach((e,t)=>{let r=y[t%y.length],a=(e.pricing??0)/m,s=_.current.get(e.id??`sl-${t}`)??0,l=T+t*18;n.beginPath(),n.arc(8,l,4,0,Math.PI*2),n.fillStyle=o(r,.8+s*.2),n.fill(),n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t2,.7+s*.2),n.textAlign=`left`,n.fillText(e.vendor,18,l+3.5),n.font=`bold 9px 'JetBrains Mono', monospace`,n.fillStyle=c(i.t3,r,s),n.textAlign=`right`,n.fillText(`${e.pricing??0} (${Math.round(a*100)}%)`,U-4,l+3.5)}),h=requestAnimationFrame(x)};return x(),()=>cancelAnimationFrame(h)},[e,s,f,y]),(0,n.jsx)(r,{className:[`canvas-pie-frame`,d].filter(Boolean).join(` `),children:(0,n.jsxs)(`div`,{style:{position:`relative`,width:U,height:ke},children:[(0,n.jsx)(`canvas`,{ref:p,role:`img`,"aria-label":`${s} chart`,style:{width:U,height:ke,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...x,parentW:U,parentH:ke})]})})}function je(e,t,n,r){let i=new Set(t.map(e=>e.source)),a=new Set(t.map(e=>e.target)),o=new Map,s=[];for(e.forEach(e=>{i.has(e.id)&&!a.has(e.id)&&s.push({id:e.id,depth:0})});s.length>0;){let e=s.shift();if(!e)break;let{id:n,depth:r}=e;o.has(n)||(o.set(n,r),t.filter(e=>e.source===n).forEach(e=>{o.has(e.target)||s.push({id:e.target,depth:r+1})}))}let c=o.size>0?Math.max(...Array.from(o.values())):0;e.forEach(e=>{o.has(e.id)||o.set(e.id,c+1)});let l=new Map;e.forEach(e=>{let t=o.get(e.id)??0;l.has(t)||l.set(t,[]),l.get(t).push(e.id)});let u=Math.max(...Array.from(l.keys()))+1,d={left:100,right:80,top:40,bottom:40},f=new Map;return l.forEach((e,t)=>{let i=d.left+t/Math.max(u-1,1)*(n-d.left-d.right),a=r-d.top-d.bottom,o=Math.max(24,(a-(e.length-1)*12)/e.length),s=e.length*o+(e.length-1)*12,c=d.top+(a-s)/2;e.forEach((e,t)=>{f.set(e,{x:i-20/2,y:c+t*(o+12),w:20,h:o})})}),f}function Me({nodes:e,links:s,width:c=960,height:d=280,ariaLabel:p,selectedEntity:v,className:y,colors:b}){let x=(0,t.useRef)(null),C=(0,t.useRef)(new Map),T=(0,t.useRef)(0),E=(0,t.useRef)([]),D=b?.nodes??a,O=b?.links??i.bd,k=b?.activeLinks??i.blue,A=b?.activeNodes??i.blue,j=(0,t.useMemo)(()=>je(e,s,c,d),[e,s,c,d]),{hoveredRef:M,tooltip:N,hitZonesRef:ee}=h(x,{width:c,height:d});return(0,t.useEffect)(()=>{let t=x.current;if(!t)return;let n=l(t,c,d);T.current=0,E.current=[];let r=s.length>0?Math.max(...s.map(e=>e.value)):1,a,p=()=>{T.current++;let t=T.current;n.clearRect(0,0,c,d);let l=1-(1-Math.min(t/56,1))**3;w(C.current,M.current),ee.current=[],s.forEach((e,a)=>{let s=j.get(e.source),c=j.get(e.target);if(!s||!c)return;let u=!!v&&(e.source===v||e.target===v),d=u?k:O,f=u?.5:.2,p=Math.max(3,e.value/r*36*l),m=p/2,h=s.x+s.w,_=s.y+s.h/2,y=c.x,b=c.y+c.h/2,x=(h+y)/2;for(let e=0;e<30;e++){let r=e/30,i=(e+1)/30,s=1-r,c=1-i,l=s*s*h+2*s*r*x+r*r*y,u=s*s*_+2*s*r*_+r*r*b,p=c*c*h+2*c*i*x+i*i*y,g=c*c*_+2*c*i*_+i*i*b,v=S(t+r*120+a*40,.025,3e-4)*1.2;n.beginPath(),n.moveTo(l,u-m+v),n.lineTo(p,g-m+v),n.lineTo(p,g+m+v),n.lineTo(l,u+m+v),n.closePath(),n.fillStyle=o(d,f*(.5+r*.5)),n.fill()}g(ee.current,`link-${a}`,x,(_+b)/2,p+6,{label:`${e.source} → ${e.target}`,value:String(e.value),color:u?k:i.blue}),Math.random()<.08&&E.current.push({linkIdx:a,prog:0,speed:.006+Math.random()*.006,off:(Math.random()-.5)*p*.5,sz:1+Math.random()})}),e.forEach((e,r)=>{let a=j.get(e.id);if(!a)return;let s=v===e.id,c=M.current===`node-${r}`,l=C.current.get(`node-${r}`)??0,d=s?A:D[r%D.length];_(ee.current,`node-${r}`,a.x,a.y,a.w,a.h,{label:e.name,value:e.valueLabel??e.id,color:d}),(l>0||s)&&u(n,a.x+a.w/2,a.y+a.h/2,a.w*2,d,.2*Math.max(l,s?.6:0));let f=s?S(t,.03,3e-4)*.15:0;n.fillStyle=o(d,.6+l*.25+f),n.beginPath(),n.roundRect(a.x,a.y,a.w,a.h,4),n.fill(),(s||l>0)&&(n.strokeStyle=o(d,.5*Math.max(l,s?1:0)),n.lineWidth=1,n.beginPath(),n.roundRect(a.x,a.y,a.w,a.h,4),n.stroke());let p=a.x+a.w+8;n.font=`${s||c?`bold `:``}10px 'JetBrains Mono', monospace`,n.fillStyle=o(s?d:i.t2,.7+l*.2),n.textAlign=`left`,n.fillText(e.name,p,a.y+a.h/2+4),e.valueLabel&&(n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=o(d,.5+l*.2),n.fillText(e.valueLabel,p,a.y+a.h/2+17))}),E.current=E.current.filter(e=>{if(e.prog+=e.speed,e.prog>1)return!1;let t=s[e.linkIdx];if(!t)return!1;let r=j.get(t.source),a=j.get(t.target);if(!r||!a)return!1;let c=r.x+r.w,l=r.y+r.h/2,u=a.x,d=a.y+a.h/2,f=(c+u)/2,p=1-e.prog,m=p*p*c+2*p*e.prog*f+e.prog*e.prog*u,h=p*p*l+2*p*e.prog*l+e.prog*e.prog*d+e.off,g=Math.sin(e.prog*Math.PI)*.5,_=b?.links??i.cyan;return n.beginPath(),n.arc(m,h,e.sz,0,Math.PI*2),n.fillStyle=o(_,g),n.fill(),!0}),E.current.length>150&&(E.current=E.current.slice(-150)),f(n,c,d,t,.01),a=requestAnimationFrame(p)};return p(),()=>{cancelAnimationFrame(a),E.current=[]}},[e,s,c,d,v,b,j]),(0,n.jsx)(r,{className:[`canvas-sankey-frame`,y].filter(Boolean).join(` `),children:(0,n.jsxs)(`div`,{role:`img`,"aria-label":p,style:{position:`relative`,width:c,height:d},children:[(0,n.jsx)(`canvas`,{ref:x,style:{width:c,height:d,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...N,parentW:c,parentH:d})]})})}var Ne=[{x:.13,y:.48},{x:.37,y:.28},{x:.63,y:.62},{x:.87,y:.38},{x:.25,y:.72},{x:.5,y:.18},{x:.75,y:.7},{x:.92,y:.22}],Pe=[i.blue,i.cyan,i.orange,i.red,i.purple,i.green,i.amber,i.t2],Fe=[26,24,24,26,22,22,22,22];function Ie(e,t){let n=1-t;return{x:n*n*n*e.p0.x+3*n*n*t*e.p1.x+3*n*t*t*e.p2.x+t*t*t*e.p3.x,y:n*n*n*e.p0.y+3*n*n*t*e.p1.y+3*n*t*t*e.p2.y+t*t*t*e.p3.y}}function Le(e,t){let n=1-t,r=3*n*n*(e.p1.x-e.p0.x)+6*n*t*(e.p2.x-e.p1.x)+3*t*t*(e.p3.x-e.p2.x),i=3*n*n*(e.p1.y-e.p0.y)+6*n*t*(e.p2.y-e.p1.y)+3*t*t*(e.p3.y-e.p2.y),a=Math.sqrt(r*r+i*i)||1;return{x:-i/a,y:r/a}}function Re(e,t){let n=t.x-e.x,r=t.y-e.y;return{p0:{x:e.x,y:e.y},p1:{x:e.x+n*.3+r*.15,y:e.y+r*.3-n*.15},p2:{x:t.x-n*.3+r*.08,y:t.y-r*.3-n*.08},p3:{x:t.x,y:t.y}}}function ze({nodes:e,links:r,width:a=960,height:s=280,selectedEntity:p}){let _=(0,t.useRef)(null),y=(0,t.useRef)(0),b=(0,t.useRef)([]),{hoveredRef:x,tooltip:C,hitZonesRef:w}=h(_,{width:a,height:s}),T=(0,t.useMemo)(()=>{let t=new Map;return e.forEach((e,n)=>t.set(e.id,n)),t},[e]),E=(0,t.useMemo)(()=>r.length>0?Math.max(...r.map(e=>e.value)):100,[r]),D=e=>E>1?e/100:e,O=(0,t.useMemo)(()=>e.map((e,t)=>{let n=Ne[t%Ne.length];return{id:e.id,label:e.name,sub:e.valueLabel??``,x:n.x*a,y:n.y*s,r:Fe[t%Fe.length],color:Pe[t%Pe.length]}}),[e,a,s]),k=(0,t.useMemo)(()=>r.map(e=>({fromIdx:T.get(e.source)??-1,toIdx:T.get(e.target)??-1,conf:D(e.value)})).filter(e=>e.fromIdx>=0&&e.toIdx>=0),[r,T]);return(0,t.useEffect)(()=>{let e=_.current;if(!e)return;let t=l(e,a,s);y.current=0,b.current=[];let n,r=()=>{y.current++;let e=y.current;if(t.clearRect(0,0,a,s),w.current=[],d(t,a,s,e,50,o(i.blue,.05)),k.forEach((e,n)=>{let r=O[e.fromIdx],a=O[e.toIdx];if(!r||!a)return;let s=!!p&&(r.id===p||a.id===p),l=c(r.color,a.color,.5),u=s?.18:.05,d=s?.25:.1,f=Re(r,a);t.beginPath(),t.moveTo(f.p0.x,f.p0.y),t.bezierCurveTo(f.p1.x,f.p1.y,f.p2.x,f.p2.y,f.p3.x,f.p3.y),t.strokeStyle=o(l,u),t.lineWidth=16,t.lineCap=`round`,t.stroke(),t.strokeStyle=o(l,d),t.lineWidth=1.5,t.stroke();for(let t=0;t<e.conf*2.5;t++)Math.random()<.45&&b.current.push({edgeIdx:n,t:0,speed:.003+Math.random()*.004,off:(Math.random()-.5)*13,sz:.7+Math.random()*2});let m=Ie(f,.5),h=`${Math.round(e.conf*100)}%`;t.font=`bold 12px 'JetBrains Mono', monospace`,t.textBaseline=`middle`;let g=t.measureText(h).width+14;t.fillStyle=`rgba(10,16,24,0.88)`,t.beginPath(),t.roundRect(m.x-g/2,m.y-11,g,22,6),t.fill(),t.strokeStyle=o(i.cyan,.25),t.lineWidth=1,t.stroke(),t.fillStyle=o(i.cyan,.9),t.textAlign=`center`,t.fillText(h,m.x,m.y)}),b.current=b.current.filter(e=>{if(e.t+=e.speed,e.t>1)return!1;let n=k[e.edgeIdx];if(!n)return!1;let r=O[n.fromIdx],i=O[n.toIdx];if(!r||!i)return!1;let a=Re(r,i),s=Ie(a,e.t),l=Le(a,e.t),d=s.x+l.x*e.off,f=s.y+l.y*e.off,p=Math.sin(e.t*Math.PI)*.7,m=c(r.color,i.color,e.t);return u(t,d,f,e.sz*3,m,p*.1),t.beginPath(),t.arc(d,f,e.sz,0,Math.PI*2),t.fillStyle=o(m,p),t.fill(),!0}),b.current.length>350&&(b.current=b.current.slice(-350)),O.forEach((n,r)=>{let a=p===n.id,s=x.current===`node-${r}`,c=S(e,.03,3e-4)*.1+1,l=n.r*c*(a?1.15:1);t.beginPath(),t.arc(n.x,n.y,l+6,0,Math.PI*2),t.strokeStyle=o(n.color,a?.3:.1),t.lineWidth=a?1.5:.7,t.stroke(),u(t,n.x,n.y,l*3,n.color,a?.22:.12);let d=t.createRadialGradient(n.x,n.y-l*.2,0,n.x,n.y,l);if(d.addColorStop(0,o(n.color,a?1:.85)),d.addColorStop(1,o(n.color,a?.65:.45)),t.fillStyle=d,t.beginPath(),t.arc(n.x,n.y,l,0,Math.PI*2),t.fill(),a||r===O.length-1){let r=l+16,i=e*.04,a=n.x+Math.cos(i)*r,s=n.y+Math.sin(i)*r;u(t,a,s,6,n.color,.3),t.beginPath(),t.arc(a,s,2,0,Math.PI*2),t.fillStyle=o(n.color,.75),t.fill()}g(w.current,`node-${r}`,n.x,n.y,l+8,{label:n.label,value:n.sub||n.id,color:n.color}),t.font=`${a||s?`bold `:``}12px 'DM Sans', sans-serif`,t.textAlign=`center`,t.textBaseline=`alphabetic`,t.fillStyle=o(n.color,a?1:.9),t.fillText(n.label,n.x,n.y+l+18),n.sub&&(t.font=`10px 'JetBrains Mono', monospace`,t.fillStyle=o(i.t3,.65),t.fillText(n.sub,n.x,n.y+l+32))}),k.length>=2){let n=k.reduce((e,t)=>e*t.conf,1),r=s*.92,c=a*.12,l=a*.76,u=v(Math.min(e*.008,1));t.fillStyle=o(i.bd,.35),t.beginPath(),t.roundRect(c,r,l,5,3),t.fill(),t.fillStyle=o(i.orange,.6),t.beginPath(),t.roundRect(c,r,l*n*u,5,3),t.fill(),t.font=`bold 12px 'JetBrains Mono', monospace`,t.textAlign=`left`,t.textBaseline=`middle`,t.fillStyle=o(i.orange,.85),t.fillText(`${Math.round(n*100)}% compound confidence`,c+l*n*u+10,r+2);let d=k.map(e=>e.conf.toFixed(2)).join(` × `);t.textAlign=`right`,t.font=`9px 'JetBrains Mono', monospace`,t.fillStyle=o(i.t4,.6),t.fillText(d,c-6,r+2)}f(t,a,s,e,.012),n=requestAnimationFrame(r)};return r(),()=>{cancelAnimationFrame(n),b.current=[]}},[O,k,a,s,p]),(0,n.jsxs)(`div`,{style:{position:`relative`,width:a,height:s},children:[(0,n.jsx)(`canvas`,{ref:_,style:{width:a,height:s,display:`block`,borderRadius:8},role:`img`,"aria-label":`causal flow diagram`}),(0,n.jsx)(m,{...C,parentW:a,parentH:s})]})}function Be({selectedEntity:e,colors:t}){return(0,n.jsx)(ze,{nodes:we.nodes,links:we.links,width:960,height:280,selectedEntity:e})}function Ve({rows:e=[],className:r,colors:i}){let{nodes:a,links:o}=(0,t.useMemo)(()=>{let t=e.slice(0,5);return{nodes:[{id:`score`,name:`Portfolio Score`},...t.map(e=>({id:e.id??e.vendor,name:e.vendor}))],links:t.map(e=>({source:e.id??e.vendor,target:`score`,value:Math.max(8,e.pricing??0)}))}},[e]);return(0,n.jsx)(Me,{nodes:a,links:o,width:760,height:280,ariaLabel:`sankey chart`,className:r,colors:i})}var He=500,Ue=320;function We({accepted:e,submitted:r,"data-testid":a}){let s=(0,t.useRef)(null),c=(0,t.useRef)(0);return(0,t.useEffect)(()=>{let t=s.current;if(!t)return;let n=l(t,He,Ue);c.current=0;let a=He/2,d=Math.max(e.value,r.value),f=(e.value-r.value)/d*14,p,m=()=>{c.current++;let t=c.current;n.clearRect(0,0,He,Ue);let s=v(Math.min(t/80,1)),l=f*x(Math.min(t/80,1))*Math.PI/180;n.strokeStyle=o(i.bd,.5*s),n.lineWidth=2,n.beginPath(),n.moveTo(a,100),n.lineTo(a,Ue-80),n.stroke(),n.beginPath(),n.arc(a,100,5*s,0,Math.PI*2),n.fillStyle=i.t2,n.fill();let h={x:a-Math.cos(l)*160,y:100+Math.sin(-l)*160},g={x:a+Math.cos(l)*160,y:100+Math.sin(l)*160};n.strokeStyle=o(i.t2,.5*s),n.lineWidth=2,n.beginPath(),n.moveTo(h.x,h.y),n.lineTo(g.x,g.y),n.stroke();let _=Math.max(20,e.value/d*100*s),y=h.y+18;u(n,h.x,y+_/2,90*.5,i.green,.18*s),n.fillStyle=o(i.green,.5*s),n.beginPath(),n.roundRect(h.x-90/2,y,90,_,[0,0,6,6]),n.fill(),n.strokeStyle=o(i.green,.7*s),n.lineWidth=1.5,n.stroke(),n.strokeStyle=o(i.t3,.35*s),n.lineWidth=1,[-90/3,90/3].forEach(e=>{n.beginPath(),n.moveTo(h.x+e,h.y+4),n.lineTo(h.x+e,y),n.stroke()}),s>.5&&(n.globalAlpha=Math.min(1,(s-.5)/.5),n.font=`bold 14px 'JetBrains Mono', monospace`,n.fillStyle=i.green,n.textAlign=`center`,n.fillText(e.label,h.x,y+_+18),n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=i.t2,n.fillText(`Accepted`,h.x,y+_+32),n.fillText(`${e.count} quotations`,h.x,y+_+44),n.globalAlpha=1);let b=Math.max(20,r.value/d*100*s),S=g.y+18;n.fillStyle=o(i.amber,.3*s),n.strokeStyle=o(i.amber,.5*s),n.lineWidth=1.5,n.beginPath(),n.roundRect(g.x-90/2,S,90,b,[0,0,6,6]),n.fill(),n.stroke(),n.strokeStyle=o(i.t3,.35*s),n.lineWidth=1,[-90/3,90/3].forEach(e=>{n.beginPath(),n.moveTo(g.x+e,g.y+4),n.lineTo(g.x+e,S),n.stroke()}),s>.5&&(n.globalAlpha=Math.min(1,(s-.5)/.5),n.font=`bold 14px 'JetBrains Mono', monospace`,n.fillStyle=i.amber,n.textAlign=`center`,n.fillText(r.label,g.x,S+b+18),n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=i.t2,n.fillText(`Submitted`,g.x,S+b+32),n.fillText(`${r.count} quotations`,g.x,S+b+44),n.globalAlpha=1),s>.85&&Math.abs(f)>1&&(n.globalAlpha=Math.min(1,(s-.85)/.15)*.6,n.font=`8px 'JetBrains Mono', monospace`,n.fillStyle=i.t3,n.textAlign=`center`,n.fillText(`${Math.abs(f).toFixed(1)}° tilt toward accepted`,a,Ue-12),n.globalAlpha=1),p=requestAnimationFrame(m)};return m(),()=>cancelAnimationFrame(p)},[e,r]),(0,n.jsx)(`div`,{"data-testid":a,style:{position:`relative`,width:He,height:Ue},children:(0,n.jsx)(`canvas`,{ref:s,role:`img`,"aria-label":`Quotation balance — accepted vs submitted quotation value`,style:{width:He,height:Ue,display:`block`}})})}var Ge=680,W=280;function Ke({trend:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(new Map),c=(0,t.useRef)(0),{hoveredRef:d,tooltip:f,hitZonesRef:_}=h(a,{width:Ge,height:W});return(0,t.useEffect)(()=>{let t=a.current;if(!t)return;let n=l(t,Ge,W);c.current=0;let r=Ge-54-28,f=W-30-54,m=Math.max(...e.map(e=>e.count)),h=e.length,y=r/(h-1),b=e.map((e,t)=>({x:54+t*y,y:30+f-e.count/m*f,point:e})),x,S=()=>{c.current++;let e=c.current;n.clearRect(0,0,Ge,W);let t=v(Math.min(e/72,1));w(s.current,d.current),_.current=[],[.25,.5,.75,1].forEach(e=>{let t=30+f-e*f;n.strokeStyle=o(i.bd,.18),n.lineWidth=1,n.setLineDash([3,5]),n.beginPath(),n.moveTo(54,t),n.lineTo(54+r,t),n.stroke(),n.setLineDash([]),n.font=`10px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t4,.6),n.textAlign=`right`,n.fillText(String(Math.round(m*e)),48,t+3)}),n.save(),n.translate(12,30+f/2),n.rotate(-Math.PI/2),n.font=`11px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.5),n.textAlign=`center`,n.fillText(`Submissions`,0,0),n.restore(),n.font=`11px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.5),n.textAlign=`center`,n.fillText(`Week`,54+r/2,W-6),n.strokeStyle=o(i.bd,.3),n.lineWidth=1,n.setLineDash([]),n.beginPath(),n.moveTo(54,30+f),n.lineTo(54+r,30+f),n.stroke();let a=t*(h-1),l=Math.floor(a)+1;if(l>=2){n.beginPath(),n.moveTo(b[0].x,30+f),n.lineTo(b[0].x,b[0].y);for(let e=1;e<l;e++){let t=a-Math.floor(a),r=e<l-1?b[e].x:b[e-1].x+(b[e].x-b[e-1].x)*(e===Math.ceil(a)?t:1),i=e<l-1?b[e].y:b[e-1].y+(b[e].y-b[e-1].y)*(e===Math.ceil(a)?t:1);n.lineTo(r,i)}let e=b[Math.min(l-1,h-1)];n.lineTo(e.x,30+f),n.closePath();let t=n.createLinearGradient(0,30,0,30+f);t.addColorStop(0,o(i.cyan,.22)),t.addColorStop(1,o(i.cyan,.02)),n.fillStyle=t,n.fill()}n.beginPath();for(let e=0;e<l;e++){let t=a-Math.floor(a),r=e===l-1&&e>0&&e===Math.ceil(a),i=e===0||e<l-1?b[e].x:b[e-1].x+(b[e].x-b[e-1].x)*(r?t:1),o=e===0||e<l-1?b[e].y:b[e-1].y+(b[e].y-b[e-1].y)*(r?t:1);e===0?n.moveTo(i,o):n.lineTo(i,o)}n.strokeStyle=o(i.cyan,.85),n.lineWidth=2,n.stroke(),b.forEach((e,t)=>{if(t>=l)return;let r=`pt-${t}`,a=s.current.get(r)??0;g(_.current,r,e.x,e.y,10,{label:e.point.week,value:`${e.point.count} quotations submitted`,sublabel:`£${e.point.value}M value`,color:i.cyan}),a>0&&p(n,e.x,30,30+f,o(i.cyan,.15*a));let c=e.point.count===m;(a>0||c)&&u(n,e.x,e.y,14,i.cyan,(c?.3:0)+a*.25),n.beginPath(),n.arc(e.x,e.y,a>0?5:3.5,0,Math.PI*2),n.fillStyle=o(i.cyan,a>0?1:.8),n.fill(),(a>0||c)&&(n.font=`bold 10px 'JetBrains Mono', monospace`,n.fillStyle=i.cyan,n.textAlign=`center`,n.fillText(String(e.point.count),e.x,e.y-10)),n.font=`10px 'JetBrains Mono', monospace`,n.fillStyle=a>0?i.cyan:o(i.t3,.6),n.textAlign=`center`,n.fillText(e.point.week,e.x,W-54+14)}),x=requestAnimationFrame(S)};return S(),()=>cancelAnimationFrame(x)},[e]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:Ge,height:W},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Quotation submission trend — weekly count over 12 weeks`,style:{width:Ge,height:W,display:`block`}}),(0,n.jsx)(m,{...f,parentW:Ge,parentH:W})]})}var G=680,qe=240,Je={Critical:i.red,High:i.orange,Medium:i.amber,Low:i.green};function Ye({severities:e,"data-testid":r}){let a=(0,t.useRef)(null),s=(0,t.useRef)(new Map),c=(0,t.useRef)(0),{hoveredRef:d,tooltip:f,hitZonesRef:p}=h(a,{width:G,height:qe});return(0,t.useEffect)(()=>{let t=a.current;if(!t)return;let n=l(t,G,qe);c.current=0;let r=e.reduce((e,t)=>e+t.count,0),f=G-28-28,m=qe-50-52,h=e.map(e=>e.count/r*f),g,v=()=>{c.current++;let t=c.current;n.clearRect(0,0,G,qe);let a=y(Math.min(t/60,1));w(s.current,d.current),p.current=[],n.strokeStyle=o(i.bd,.2),n.lineWidth=1,n.beginPath(),n.rect(28,50,f,m),n.stroke(),n.strokeStyle=o(i.t4,.15),n.lineWidth=1,n.setLineDash([4,4]),n.beginPath(),n.moveTo(G/2,50),n.lineTo(G/2,50+m),n.stroke(),n.setLineDash([]);let l=28;e.forEach((e,t)=>{let c=Je[e.severity]??i.blue,d=h[t];d*a;let f=s.current.get(e.severity)??0,g=l+d/2,v=d*.85;g-v/2;let y=d*a,b=v*a,x=g-b/2;if(y>0&&(f>0&&u(n,l+y/2,50+m/2,y*.4,c,.15*f),n.beginPath(),n.moveTo(x,50),n.lineTo(x+b,50),n.lineTo(l+y,50+m),n.lineTo(l,50+m),n.closePath(),n.fillStyle=o(c,.45+f*.25),n.fill(),n.strokeStyle=o(c,(.5+f*.3)*a),n.lineWidth=f>0?2:1,n.beginPath(),n.moveTo(x,50),n.lineTo(x+b,50),n.stroke(),n.strokeStyle=o(c,(.3+f*.3)*a),n.lineWidth=f>0?2:1,n.beginPath(),n.moveTo(l,50+m),n.lineTo(l+y,50+m),n.stroke()),_(p.current,e.severity,l,50,d,m,{label:e.severity,value:`${e.count} Early Warnings`,sublabel:`${Math.round(e.count/r*100)}% of all EWs`,color:c}),a>.5){let t=Math.min(1,(a-.5)/.5),s=l+d/2;n.globalAlpha=t,n.font=`bold 10px 'JetBrains Mono', monospace`,n.fillStyle=f>0?c:o(c,.9),n.textAlign=`center`,n.fillText(e.severity,s,38),n.font=`bold ${d>80?`18`:`13`}px 'JetBrains Mono', monospace`,n.fillStyle=f>0?i.t1:o(i.t1,.85),n.fillText(String(e.count),s,50+m/2+6),n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=f>0?c:o(i.t3,.7),n.fillText(`${Math.round(e.count/r*100)}%`,s,50+m+18),n.globalAlpha=1}l+=d});let b=n.createLinearGradient(28,0,28+f,0);b.addColorStop(0,o(i.red,.03)),b.addColorStop(.33,o(i.orange,.03)),b.addColorStop(.66,o(i.amber,.03)),b.addColorStop(1,o(i.green,.03)),n.fillStyle=b,n.fillRect(28,50,f*a,m),g=requestAnimationFrame(v)};return v(),()=>cancelAnimationFrame(g)},[e]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:G,height:qe},children:[(0,n.jsx)(`canvas`,{ref:a,role:`img`,"aria-label":`Early Warning severity distribution — prism spectrum bands`,style:{width:G,height:qe,display:`block`}}),(0,n.jsx)(m,{...f,parentW:G,parentH:qe})]})}var K=460,q=300,Xe={Open:i.red,Submitted:i.amber,Closed:i.green};function Ze({segments:e,title:r,"data-testid":a}){let s=(0,t.useRef)(null),c=(0,t.useRef)(0),p=(0,t.useRef)(new Map),{hoveredRef:_,tooltip:v,hitZonesRef:y}=h(s,{width:K,height:q});return(0,t.useEffect)(()=>{let t=s.current;if(!t)return;let n=l(t,K,q);c.current=0;let r=K*.5,a=q*.54,m=K*.22,h=e.reduce((e,t)=>e+t.count,0),v=Math.max(...e.map(e=>e.count),1),b,x=()=>{c.current++;let t=c.current;n.clearRect(0,0,K,q),y.current=[],p.current.forEach((e,t)=>{let n=t===_.current?1:0,r=e+(n-e)*.12;Math.abs(r-n)<.005?n===0?p.current.delete(t):p.current.set(t,1):p.current.set(t,r)}),_.current&&!p.current.has(_.current)&&p.current.set(_.current,0),d(n,K,q,t,40,o(i.blue,.04)),e.forEach((e,s)=>{let c=s/3*Math.PI*2-Math.PI/2,l=r+Math.cos(c)*m,d=a+Math.sin(c)*m,f=Xe[e.status]??i.blue,p=2+e.count/v*8;n.beginPath(),n.moveTo(r,a),n.lineTo(l,d),n.strokeStyle=o(f,.08),n.lineWidth=p*2,n.stroke(),n.beginPath(),n.moveTo(r,a),n.lineTo(l,d),n.strokeStyle=o(f,.25),n.lineWidth=1,n.stroke();let h=(t*.005+s*.33)%1,g=r+(l-r)*h,_=a+(d-a)*h;u(n,g,_,6,f,.4),n.beginPath(),n.arc(g,_,2,0,Math.PI*2),n.fillStyle=o(f,.8),n.fill();let y=(r+l)/2,b=(a+d)/2;n.font=`bold 9px 'JetBrains Mono', monospace`,n.textAlign=`center`,n.textBaseline=`middle`,n.fillStyle=o(f,.85),n.fillText(String(e.count),y,b)}),e.forEach((e,t)=>{let s=t/3*Math.PI*2-Math.PI/2,c=r+Math.cos(s)*m,l=a+Math.sin(s)*m,d=Xe[e.status]??i.blue,f=10+e.count/v*18,_=p.current.get(e.status)??0;u(n,c,l,f*2.5,d,.2+_*.15);let b=n.createRadialGradient(c,l-f*.2,0,c,l,f);b.addColorStop(0,o(d,.8+_*.2)),b.addColorStop(1,o(d,.4+_*.1)),n.beginPath(),n.arc(c,l,f,0,Math.PI*2),n.fillStyle=b,n.fill(),n.font=`bold 9px 'JetBrains Mono', monospace`,n.textAlign=`center`,n.textBaseline=`middle`,n.fillStyle=o(i.t1,.9),n.fillText(e.status,c,l),g(y.current,e.status,c,l,f+6,{label:e.status,value:`${e.count} Early Warnings`,sublabel:`${Math.round(e.count/h*100)}%`,color:d})});let s=p.current.get(`center`)??0;u(n,r,a,36,i.t3,.2+s*.15);let l=n.createRadialGradient(r,a-4,0,r,a,22);l.addColorStop(0,o(i.t2,.9)),l.addColorStop(1,o(i.t3,.5)),n.beginPath(),n.arc(r,a,22,0,Math.PI*2),n.fillStyle=l,n.fill(),n.font=`bold 8px 'JetBrains Mono', monospace`,n.textAlign=`center`,n.textBaseline=`middle`,n.fillStyle=o(i.t1,.9),n.fillText(`EW Status`,r,a-4),n.font=`bold 10px 'JetBrains Mono', monospace`,n.fillStyle=i.t1,n.fillText(String(h),r,a+8),g(y.current,`center`,r,a,28,{label:`Total EW Status`,value:`${h} Early Warnings`,color:i.t3}),f(n,K,q,t,.015),b=requestAnimationFrame(x)};return x(),()=>cancelAnimationFrame(b)},[e,r]),(0,n.jsxs)(`div`,{"data-testid":a,style:{position:`relative`,width:K,height:q},children:[(0,n.jsx)(`canvas`,{ref:s,role:`img`,"aria-label":r??`EW status arc visualization`,style:{width:K,height:q,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...v,parentW:K,parentH:q})]})}var J=280,Y=96;function Qe({points:e=[],className:a,colors:s}){let c=(0,t.useRef)(null),d=(0,t.useRef)(new Map),f=(0,t.useRef)(0),_=(0,t.useMemo)(()=>e.map(([e,t])=>{let n=String(t).match(/-?\d+(\.\d+)?/);return{label:e,value:n?Number(n[0]):0}}),[e]),{mouseRef:v,hoveredRef:y,tooltip:b,hitZonesRef:x}=h(c,{width:J,height:Y});return(0,t.useEffect)(()=>{let e=c.current;if(!e)return;let t=l(e,J,Y);f.current=0;let n=s?.line??i.blue,r=s?.point??i.blue,a=s?.axisLine??i.bd,m,h=()=>{f.current++;let e=f.current;if(t.clearRect(0,0,J,Y),_.length<2){m=requestAnimationFrame(h);return}let s={left:12,right:12,top:16,bottom:20},c=J-s.left-s.right,l=Y-s.top-s.bottom,b=_.map(e=>e.value),C=Math.min(...b),T=Math.max(...b)-C||1,E=e=>s.left+e/(_.length-1)*c,D=e=>s.top+(1-(e-C)/T)*l,O=1-(1-Math.min(e/48,1))**3,k=Math.max(2,Math.floor(O*_.length));if(w(d.current,y.current),x.current=[],t.strokeStyle=o(a,.3),t.lineWidth=.5,t.setLineDash([]),t.beginPath(),t.moveTo(s.left,Y-s.bottom),t.lineTo(J-s.right,Y-s.bottom),t.stroke(),t.font=`9px 'JetBrains Mono', monospace`,t.fillStyle=o(i.t4,.9),t.textAlign=`center`,_.forEach((e,n)=>{t.fillText(e.label.replace(`Day `,`D`),E(n),Y-4)}),v.current.over&&y.current){let e=parseInt(y.current.split(`-`)[1]);isNaN(e)||p(t,E(e),s.top,s.top+l)}if(k>1){let e=t.createLinearGradient(0,s.top,0,s.top+l);e.addColorStop(0,o(n,.15)),e.addColorStop(1,o(n,0)),t.fillStyle=e,t.beginPath(),t.moveTo(E(0),s.top+l);for(let e=0;e<k;e++)t.lineTo(E(e),D(_[e].value));t.lineTo(E(k-1),s.top+l),t.closePath(),t.fill(),t.strokeStyle=o(n,.8),t.lineWidth=1.5,t.setLineDash([]),t.beginPath();for(let e=0;e<k;e++){let n=E(e),r=D(_[e].value);e===0?t.moveTo(n,r):t.lineTo(n,r)}t.stroke()}for(let e=0;e<k;e++){let n=E(e),a=D(_[e].value),s=`tp-${e}`,c=d.current.get(s)??0,l=e===_.length-1;g(x.current,s,n,a,10,{label:_[e].label,value:String(_[e].value),color:l?i.red:r}),c>0&&!l&&(u(t,n,a,12*c,r,.2*c),t.fillStyle=o(r,.8),t.beginPath(),t.arc(n,a,3+c*2,0,Math.PI*2),t.fill())}if(k>=_.length){let n=_.length-1,r=E(n),a=D(_[n].value),s=d.current.get(`tp-${n}`)??0,c=S(e,.05,5e-4),l=1+s*.5;t.shadowColor=o(i.red,.5),t.shadowBlur=(8+c*4)*l,t.fillStyle=i.red,t.beginPath(),t.arc(r,a,(3.5+c*1.5)*l,0,Math.PI*2),t.fill(),t.shadowBlur=0}m=requestAnimationFrame(h)};return h(),()=>cancelAnimationFrame(m)},[_,s]),(0,n.jsx)(r,{className:[`canvas-trend-frame`,a].filter(Boolean).join(` `),children:(0,n.jsxs)(`div`,{style:{position:`relative`,width:J,height:Y},children:[(0,n.jsx)(`canvas`,{ref:c,role:`img`,"aria-label":`trend chart`,style:{width:J,height:Y,display:`block`,borderRadius:8}}),(0,n.jsx)(m,{...b,parentW:J,parentH:Y})]})})}var $e=680,et=320;function tt({contractors:e,"data-testid":r}){let s=(0,t.useRef)(null),c=(0,t.useRef)(new Map),d=(0,t.useRef)(0),{hoveredRef:f,tooltip:p,hitZonesRef:g}=h(s,{width:$e,height:et});return(0,t.useEffect)(()=>{let t=s.current;if(!t)return;let n=l(t,$e,et);d.current=0;let r=$e-60-28,p=Math.max(...e.map(e=>e.implemented+e.unimplemented)),m=e.length*40-14,h=16+(et-16-32-m)/2,v,b=()=>{d.current++;let t=d.current;n.clearRect(0,0,$e,et);let s=y(Math.min(t/60,1));w(c.current,f.current),g.current=[],e.forEach((t,l)=>{let d=a[l%a.length],f=C(s,l,e.length,y),m=h+l*40,v=t.implemented+t.unimplemented,b=t.implemented/p*r*f,x=t.unimplemented/p*r*f,S=`${t.id}-impl`,w=`${t.id}-un`,T=c.current.get(S)??0,E=c.current.get(w)??0;_(g.current,S,60,m,b||1,26,{label:`${t.name} — Implemented`,value:`${t.implemented} variations`,sublabel:`${Math.round(t.implemented/v*100)}% complete`,color:i.green}),_(g.current,w,60+b,m,x||1,26,{label:`${t.name} — Unimplemented`,value:`${t.unimplemented} variations`,sublabel:`${Math.round(t.unimplemented/v*100)}% pending`,color:i.amber}),n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=o(d,.85),n.textAlign=`right`,n.fillText(t.shortName,52,m+26/2+4),n.fillStyle=o(i.bd,.15),n.beginPath(),n.roundRect(60,m,v/p*r,26,4),n.fill(),b>0&&(T>0&&u(n,60+b/2,m+26/2,b*.3,i.green,.12*T),n.fillStyle=o(i.green,.6+T*.2),n.beginPath(),n.roundRect(60,m,b,26,[4,0,0,4]),n.fill(),b>28&&f>.5&&(n.font=`bold 10px 'JetBrains Mono', monospace`,n.fillStyle=T>0?i.green:o(i.t1,.8),n.textAlign=`center`,n.fillText(String(t.implemented),60+b/2,m+26/2+4))),x>0&&(E>0&&u(n,60+b+x/2,m+26/2,x*.3,i.amber,.12*E),n.fillStyle=o(i.amber,.18+E*.18),n.strokeStyle=o(i.amber,.3+E*.3),n.lineWidth=1,n.beginPath(),n.roundRect(60+b,m,x,26,[0,4,4,0]),n.fill(),n.stroke(),x>28&&f>.5&&(n.font=`${E>0?`bold `:``}10px 'JetBrains Mono', monospace`,n.fillStyle=E>0?i.amber:o(i.t3,.8),n.textAlign=`center`,n.fillText(String(t.unimplemented),60+b+x/2,m+26/2+4))),b>0&&x>0&&(n.strokeStyle=o(i.bg,.7),n.lineWidth=2,n.beginPath(),n.moveTo(60+b,m),n.lineTo(60+b,m+26),n.stroke())});let l=h+m+24,x=60+r/2;n.font=`9px 'JetBrains Mono', monospace`,n.textAlign=`right`,n.fillStyle=i.green,n.fillText(`■ Implemented`,x-10,l),n.textAlign=`left`,n.fillStyle=o(i.t3,.7),n.fillText(`■ Unimplemented`,x+10,l),v=requestAnimationFrame(b)};return b(),()=>cancelAnimationFrame(v)},[e]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:$e,height:et},children:[(0,n.jsx)(`canvas`,{ref:s,role:`img`,"aria-label":`Implemented vs unimplemented variations per contractor — split bar`,style:{width:$e,height:et,display:`block`}}),(0,n.jsx)(m,{...p,parentW:$e,parentH:et})]})}var nt=800,X=360;function rt({contractors:e,"data-testid":r}){let s=(0,t.useRef)(null),c=(0,t.useRef)(new Map),d=(0,t.useRef)(0),{hoveredRef:f,tooltip:p,hitZonesRef:g}=h(s,{width:nt,height:X});return(0,t.useEffect)(()=>{let t=s.current;if(!t)return;let n=l(t,nt,X);d.current=0;let r=e.reduce((e,t)=>e+t.base,0),p=e.reduce((e,t)=>e+t.variations,0),m=e.reduce((e,t)=>e+t.totalCommitment,0),h=X-20-26,y=h-6*(e.length-1),b=20,x=e.map((e,t)=>{let n=Math.max(24,e.totalCommitment/m*y),r={x:100-110/2,y:b,h:n,cy:b+n/2,c:e,color:a[t%a.length]};return b+=n+6,r}),S=y-14,T=Math.max(28,r/m*S),E=Math.max(18,p/m*S),D=20+(h-(T+E+14))/2,O={x:420-110/2,y:D,h:T,cy:D+T/2},k={x:420-110/2,y:D+T+14,h:E,cy:D+T+14+E/2},A={x:720-110/2,y:20,h,cy:20+h/2},j,M=()=>{d.current++;let t=d.current;n.clearRect(0,0,nt,X);let a=v(Math.min(t/80,1));if(w(c.current,f.current),g.current=[],e.forEach((t,i)=>{let o=x[i],s=C(a,i,e.length,v),l=c.current.get(t.id)??0;if(s<.01)return;let u=t.base/t.totalCommitment,d=t.variations/t.totalCommitment,f=o.h*u,m=o.h*d,h=o.y+f/2,g=o.y+f+m/2,_=Math.max(2,t.base/r*T),y=Math.max(2,t.variations/p*E),b=O.y+e.slice(0,i).reduce((e,t)=>e+t.base/r*T,0)+_/2,S=k.y+e.slice(0,i).reduce((e,t)=>e+t.variations/p*E,0)+y/2,w=l*.2+.18;it(n,o.x+110,h,420-110/2,b,_*s,o.color,w),it(n,o.x+110,g,420-110/2,S,y*s,o.color,w*.75)}),a>.3){let e=Math.min(1,(a-.3)/.7),t=A.y+r/m*h/2,o=A.y+h-p/m*h/2;it(n,475,O.cy,720-110/2,t,T*e,i.blue,.25*e),it(n,475,k.cy,720-110/2,o,E*e,i.amber,.22*e)}if([`Contractors`,`Components`,`Total`].forEach((e,t)=>{let r=[100,420,720][t];n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.5),n.textAlign=`center`,n.fillText(e,r,X-8)}),e.forEach((t,r)=>{let s=x[r],l=C(a,r,e.length,v),d=c.current.get(t.id)??0;_(g.current,t.id,s.x,s.y,110,s.h,{label:t.name,value:`£${t.totalCommitment}M total commitment`,sublabel:`Base £${t.base}M + Variations £${t.variations}M`,color:s.color}),d>0&&u(n,s.x+110/2,s.cy,110*.6,s.color,.12*d),n.fillStyle=o(s.color,(.3+d*.15)*l),n.strokeStyle=o(s.color,(.55+d*.25)*l),n.lineWidth=1,n.beginPath(),n.roundRect(s.x,s.y,110*l,s.h,4),n.fill(),n.stroke(),l>.6&&s.h>=24&&(n.globalAlpha=Math.min(1,(l-.6)/.4),n.font=`${d>0?`bold `:``}9px 'JetBrains Mono', monospace`,n.fillStyle=d>0?s.color:o(i.t2,.9),n.textAlign=`center`,n.textBaseline=`middle`,n.fillText(t.shortName,s.x+110/2,s.h>=36?s.cy-5:s.cy),s.h>=36&&(n.font=`8px 'JetBrains Mono', monospace`,n.fillStyle=o(i.t3,.8),n.fillText(`£${t.totalCommitment}M`,s.x+110/2,s.cy+7)),n.globalAlpha=1,n.textBaseline=`alphabetic`)}),a>.2){let e=Math.min(1,(a-.2)/.4);u(n,420,O.cy,30,i.blue,.1*e),n.fillStyle=o(i.blue,.3*e),n.strokeStyle=o(i.blue,.5*e),n.lineWidth=1,n.beginPath(),n.roundRect(O.x,O.y,110,O.h*e,4),n.fill(),n.stroke(),n.globalAlpha=e,n.textBaseline=`middle`,n.font=`bold 9px 'JetBrains Mono', monospace`,n.fillStyle=i.blue,n.textAlign=`center`,n.fillText(`Base Value`,420,O.cy-6),n.font=`10px 'JetBrains Mono', monospace`,n.fillStyle=i.t1,n.fillText(`£${r}M`,420,O.cy+8),n.globalAlpha=1,n.textBaseline=`alphabetic`,u(n,420,k.cy,24,i.amber,.1*e),n.fillStyle=o(i.amber,.22*e),n.strokeStyle=o(i.amber,.4*e),n.beginPath(),n.roundRect(k.x,k.y,110,k.h*e,4),n.fill(),n.stroke(),n.globalAlpha=e,n.textBaseline=`middle`,n.font=`bold 9px 'JetBrains Mono', monospace`,n.fillStyle=i.amber,n.textAlign=`center`,n.fillText(`Variations`,420,k.cy-4),n.font=`10px 'JetBrains Mono', monospace`,n.fillStyle=i.t1,n.fillText(`£${p}M`,420,k.cy+8),n.globalAlpha=1,n.textBaseline=`alphabetic`}if(a>.5){let e=Math.min(1,(a-.5)/.5);u(n,720,A.cy,44,i.cyan,.2*e),n.fillStyle=o(i.cyan,.25*e),n.strokeStyle=o(i.cyan,.6*e),n.lineWidth=1.5,n.beginPath(),n.roundRect(A.x,A.y,110,A.h*e,6),n.fill(),n.stroke(),n.globalAlpha=e,n.textBaseline=`middle`,n.font=`9px 'JetBrains Mono', monospace`,n.fillStyle=i.t2,n.textAlign=`center`,n.fillText(`Total Commitment`,720,A.cy-12),n.font=`bold 16px 'JetBrains Mono', monospace`,n.fillStyle=i.cyan,n.fillText(`£${m}M`,720,A.cy+6),n.globalAlpha=1,n.textBaseline=`alphabetic`}j=requestAnimationFrame(M)};return M(),()=>cancelAnimationFrame(j)},[e]),(0,n.jsxs)(`div`,{"data-testid":r,style:{position:`relative`,width:nt,height:X},children:[(0,n.jsx)(`canvas`,{ref:s,role:`img`,"aria-label":`Weekly report flow — base value and variations per contractor flowing to total commitment`,style:{width:nt,height:X,display:`block`}}),(0,n.jsx)(m,{...p,parentW:nt,parentH:X})]})}function it(e,t,n,r,i,a,s,c){let l=(t+r)/2;e.beginPath(),e.moveTo(t,n-a/2),e.bezierCurveTo(l,n-a/2,l,i-a/2,r,i-a/2),e.lineTo(r,i+a/2),e.bezierCurveTo(l,i+a/2,l,n+a/2,t,n+a/2),e.closePath(),e.fillStyle=o(s,c),e.fill()}function at({config:e,className:t}){return e.type===`line`?(0,n.jsx)(Se,{rows:e.rows,className:t}):e.type===`area`?(0,n.jsx)(O,{rows:e.rows,className:t}):e.type===`bar`?(0,n.jsx)(j,{rows:e.rows,className:t}):e.type===`pie`?(0,n.jsx)(Ae,{rows:e.rows,variant:`pie`,className:t}):e.type===`donut`?(0,n.jsx)(Ae,{rows:e.rows,variant:`donut`,className:t}):e.type===`sankey`?(0,n.jsx)(Ve,{rows:e.rows,className:t}):e.type===`flow`?(0,n.jsx)(Be,{selectedEntity:e.selectedEntity,className:t}):e.type===`trend`?(0,n.jsx)(Qe,{points:e.points,className:t}):e.type===`mini-bars`?(0,n.jsx)(Te,{rows:e.rows,className:t}):e.type===`contract-value-orb`?(0,n.jsx)(ge,{data:e.data}):e.type===`contract-bars`?(0,n.jsx)(fe,{contractors:e.contractors}):e.type===`commitment-race`?(0,n.jsx)(te,{contractors:e.contractors}):e.type===`status-arc`?(0,n.jsx)(Ze,{segments:e.segments,title:e.title}):e.type===`ew-category`?(0,n.jsx)(xe,{categories:e.categories}):e.type===`contractor-rank`?(0,n.jsx)(be,{contractors:e.contractors}):e.type===`severity-bands`?(0,n.jsx)(Ye,{severities:e.severities}):e.type===`nce-tree`?(0,n.jsx)(De,{total:e.total,byContractor:e.byContractor}):e.type===`compensation-gauge`?(0,n.jsx)(ie,{pct:e.pct,confirmed:e.confirmed,total:e.total}):e.type===`variation-split`?(0,n.jsx)(tt,{contractors:e.contractors}):e.type===`quotation-balance`?(0,n.jsx)(We,{accepted:e.accepted,submitted:e.submitted}):e.type===`quotation-trend`?(0,n.jsx)(Ke,{trend:e.trend}):e.type===`weekly-flow`?(0,n.jsx)(rt,{contractors:e.contractors}):(0,n.jsx)(`div`,{className:`viz-empty`,children:`Visualization unavailable`})}var ot=[];function st(e){try{return JSON.parse(decodeURIComponent(e))}catch{return null}}function ct(){for(;ot.length;){let e=ot.pop();e&&e.unmount()}}function lt(){ct(),document.querySelectorAll(`[data-d3-viz]`).forEach(t=>{let r=t.dataset.d3Viz;if(!r)return;let i=st(r);if(!i)return;let a=(0,e.createRoot)(t);ot.push(a),a.render((0,n.jsx)(at,{config:i}))})}function ut(e){return encodeURIComponent(JSON.stringify(e))}function dt({rows:e=[],className:t,colors:r}){return(0,n.jsx)(Ae,{rows:e,variant:`donut`,className:t,colors:r})}var Z={bg:`rgba(255,255,255,0.025)`,border:`rgba(28,45,66,0.9)`,t1:`#F1F5F9`,t2:`#CBD5E1`,t3:`#94A3B8`,t4:`#64748B`,red:`#F06060`,amber:`#FBBF24`,green:`#34D399`},Q=`'JetBrains Mono', monospace`,$=`'DM Sans', sans-serif`;function ft({chips:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,gap:6,marginTop:10},children:e.map((e,t)=>(0,n.jsxs)(`div`,{style:{flex:1,display:`flex`,alignItems:`baseline`,gap:8,padding:`8px 12px`,background:Z.bg,border:`1px solid ${Z.border}`,borderRadius:5},children:[(0,n.jsx)(`span`,{style:{fontSize:13,fontWeight:700,color:e.color??Z.t1,fontFamily:Q},children:e.value}),(0,n.jsx)(`span`,{style:{fontSize:11,color:Z.t4,fontFamily:$,lineHeight:1.4},children:e.label})]},t))})}function pt({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,gap:8},children:e.map((e,t)=>(0,n.jsxs)(`div`,{style:{flex:1,padding:`12px 16px`,background:Z.bg,border:`1px solid ${Z.border}`,borderTop:`2px solid ${e.color??Z.t4}`,borderRadius:7,textAlign:`center`},children:[(0,n.jsx)(`div`,{style:{fontSize:22,fontWeight:700,color:e.color??Z.t1,fontFamily:Q,lineHeight:1.15},children:e.value}),(0,n.jsx)(`div`,{style:{fontSize:11,color:Z.t4,fontFamily:$,marginTop:5,lineHeight:1.45},children:e.label})]},t))})}function mt({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:e.map((e,t)=>(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:12,padding:`9px 14px`,background:Z.bg,border:`1px solid ${Z.border}`,borderLeft:`3px solid ${e.color}`,borderRadius:6},children:[(0,n.jsx)(`span`,{style:{fontSize:11,fontWeight:600,color:e.color,background:e.color+`22`,padding:`2px 8px`,borderRadius:4,fontFamily:$,flexShrink:0},children:e.name}),(0,n.jsx)(`span`,{style:{fontSize:18,fontWeight:700,color:e.color,fontFamily:Q,minWidth:70,flexShrink:0},children:e.value}),(0,n.jsx)(`span`,{style:{fontSize:11,color:Z.t4,fontFamily:$,flex:1,lineHeight:1.45},children:e.kpiLabel})]},t))})}function ht({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,gap:8},children:e.map((e,t)=>(0,n.jsxs)(`div`,{style:{flex:1,padding:`14px 16px`,background:Z.bg,border:`1px solid ${e.color?e.color+`30`:Z.border}`,borderRadius:7},children:[(0,n.jsx)(`div`,{style:{fontSize:26,fontWeight:700,color:e.color??Z.t1,fontFamily:Q,lineHeight:1.1},children:e.value}),(0,n.jsx)(`div`,{style:{fontSize:14,color:Z.t4,fontFamily:$,marginTop:6,lineHeight:1.5},children:e.label})]},t))})}var gt={red:Z.red,amber:Z.amber,green:Z.green};function _t({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:e.map((e,t)=>{let r=gt[e.severity];return(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:10,padding:`10px 14px`,background:r+`0C`,border:`1px solid ${r}28`,borderLeft:`3px solid ${r}`,borderRadius:6},children:[(0,n.jsx)(`span`,{style:{width:7,height:7,borderRadius:`50%`,background:r,flexShrink:0,marginTop:5}}),(0,n.jsx)(`span`,{style:{fontSize:12,color:Z.t2,fontFamily:$,lineHeight:1.6},children:e.text})]},t)})})}function vt({min:e,max:t,unit:r,dots:i,chips:a}){let o=t-e;return(0,n.jsxs)(`div`,{children:[(0,n.jsxs)(`div`,{style:{position:`relative`,height:90,marginTop:4},children:[(0,n.jsx)(`div`,{style:{position:`absolute`,top:38,left:8,right:8,height:2,background:`rgba(255,255,255,0.08)`,borderRadius:1}}),(0,n.jsxs)(`div`,{style:{position:`absolute`,top:43,left:0,fontSize:9,color:Z.t4,fontFamily:Q},children:[e,r]}),(0,n.jsxs)(`div`,{style:{position:`absolute`,top:43,right:0,fontSize:9,color:Z.t4,fontFamily:Q},children:[t,r]}),i.map((t,i)=>{let a=(t.val-e)/o*100,s=i%2==0;return(0,n.jsxs)(`div`,{style:{position:`absolute`,left:`${a}%`,top:0,transform:`translateX(-50%)`},children:[s&&(0,n.jsxs)(`div`,{style:{textAlign:`center`,marginBottom:2},children:[(0,n.jsx)(`div`,{style:{fontSize:9,color:t.color,fontFamily:$,whiteSpace:`nowrap`},children:t.name}),(0,n.jsxs)(`div`,{style:{fontSize:9,fontWeight:700,color:t.color,fontFamily:Q,whiteSpace:`nowrap`},children:[t.val,r]})]}),(0,n.jsx)(`div`,{style:{width:10,height:10,borderRadius:`50%`,background:t.color,boxShadow:`0 0 8px ${t.color}70`,margin:s?`0 auto`:`26px auto 0`}}),!s&&(0,n.jsxs)(`div`,{style:{textAlign:`center`,marginTop:4},children:[(0,n.jsx)(`div`,{style:{fontSize:9,color:t.color,fontFamily:$,whiteSpace:`nowrap`},children:t.name}),(0,n.jsxs)(`div`,{style:{fontSize:9,fontWeight:700,color:t.color,fontFamily:Q,whiteSpace:`nowrap`},children:[t.val,r]})]})]},i)})]}),a&&a.length>0&&(0,n.jsx)(ft,{chips:a})]})}function yt({leftPct:e,leftLabel:t,leftValue:r,leftColor:i,rightPct:a,rightLabel:o,rightValue:s,rightColor:c,chips:l}){return(0,n.jsxs)(`div`,{children:[(0,n.jsxs)(`div`,{style:{display:`flex`,borderRadius:6,overflow:`hidden`,height:36,marginBottom:8},children:[(0,n.jsx)(`div`,{style:{width:`${e}%`,background:i+`38`,display:`flex`,alignItems:`center`,justifyContent:`flex-end`,paddingRight:12},children:(0,n.jsx)(`span`,{style:{fontSize:12,fontWeight:700,color:i,fontFamily:Q},children:r})}),(0,n.jsx)(`div`,{style:{width:1,background:`rgba(255,255,255,0.12)`,flexShrink:0}}),(0,n.jsx)(`div`,{style:{width:`${a}%`,background:c+`2A`,display:`flex`,alignItems:`center`,paddingLeft:12},children:(0,n.jsx)(`span`,{style:{fontSize:12,fontWeight:700,color:c,fontFamily:Q},children:s})})]}),(0,n.jsxs)(`div`,{style:{display:`flex`,marginBottom:l?4:0},children:[(0,n.jsx)(`div`,{style:{width:`${e}%`},children:(0,n.jsxs)(`span`,{style:{fontSize:10,color:i,fontFamily:$},children:[e,`% `,t]})}),(0,n.jsx)(`div`,{style:{width:`${a}%`,paddingLeft:10},children:(0,n.jsxs)(`span`,{style:{fontSize:10,color:c,fontFamily:$},children:[a,`% `,o]})})]}),l&&l.length>0&&(0,n.jsx)(ft,{chips:l})]})}function bt({pct:e,label:t,color:r,chips:i}){let a=2*Math.PI*30,o=a*(1-e/100);return(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:20},children:[(0,n.jsxs)(`div`,{style:{position:`relative`,flexShrink:0,width:80,height:80},children:[(0,n.jsxs)(`svg`,{width:80,height:80,style:{transform:`rotate(-90deg)`},children:[(0,n.jsx)(`circle`,{cx:40,cy:40,r:30,fill:`none`,stroke:`rgba(255,255,255,0.07)`,strokeWidth:8}),(0,n.jsx)(`circle`,{cx:40,cy:40,r:30,fill:`none`,stroke:r,strokeWidth:8,strokeDasharray:a,strokeDashoffset:o,strokeLinecap:`round`})]}),(0,n.jsx)(`div`,{style:{position:`absolute`,top:`50%`,left:`50%`,transform:`translate(-50%, -50%)`,textAlign:`center`},children:(0,n.jsxs)(`div`,{style:{fontSize:15,fontWeight:700,color:r,fontFamily:Q},children:[e,`%`]})})]}),(0,n.jsxs)(`div`,{style:{flex:1},children:[(0,n.jsx)(`div`,{style:{fontSize:12,color:Z.t3,fontFamily:$,marginBottom:10,lineHeight:1.5},children:t}),i&&(0,n.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:i.map((e,t)=>(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`baseline`,gap:8,padding:`7px 10px`,background:Z.bg,border:`1px solid ${Z.border}`,borderRadius:5},children:[(0,n.jsx)(`span`,{style:{fontSize:13,fontWeight:700,color:e.color??Z.t1,fontFamily:Q},children:e.value}),(0,n.jsx)(`span`,{style:{fontSize:11,color:Z.t4,fontFamily:$,lineHeight:1.4},children:e.label})]},t))})]})]})}var xt={green:`#34D39918`,amber:`#FBBF2418`,red:`#F0606018`},St={green:`#34D399`,amber:`#FBBF24`,red:`#F06060`};function Ct({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:e.map((e,t)=>(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:10,padding:`8px 12px`,background:Z.bg,border:`1px solid ${Z.border}`,borderLeft:`3px solid ${e.color}`,borderRadius:6},children:[(0,n.jsx)(`span`,{style:{fontSize:11,fontWeight:600,color:e.color,background:e.color+`1A`,padding:`2px 7px`,borderRadius:4,fontFamily:$,flexShrink:0,minWidth:62,textAlign:`center`},children:e.name}),(0,n.jsx)(`div`,{style:{flex:1,height:4,background:`rgba(255,255,255,0.07)`,borderRadius:2,overflow:`hidden`},children:(0,n.jsx)(`div`,{style:{height:`100%`,width:`${e.pct}%`,background:e.color,borderRadius:2,opacity:.75}})}),(0,n.jsx)(`span`,{style:{fontSize:13,fontWeight:700,color:e.color,fontFamily:Q,flexShrink:0,minWidth:52,textAlign:`right`},children:e.value}),e.badge&&e.badgeSeverity&&(0,n.jsx)(`span`,{style:{fontSize:10,fontWeight:600,color:St[e.badgeSeverity],background:xt[e.badgeSeverity],padding:`2px 7px`,borderRadius:4,fontFamily:$,flexShrink:0,minWidth:72,textAlign:`center`},children:e.badge}),e.sublabel&&(0,n.jsx)(`span`,{style:{fontSize:10,color:Z.t4,fontFamily:$,flexShrink:0,minWidth:80,textAlign:`right`},children:e.sublabel})]},t))})}var wt={red:Z.red,amber:Z.amber,green:Z.green};function Tt({items:e}){return(0,n.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:e.map((e,t)=>{let r=wt[e.severity];return(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`flex-start`,gap:10,padding:`9px 12px`,background:r+`0A`,border:`1px solid ${r}25`,borderLeft:`3px solid ${r}`,borderRadius:6},children:[(0,n.jsx)(`span`,{style:{width:7,height:7,borderRadius:`50%`,background:r,flexShrink:0,marginTop:5}}),(0,n.jsx)(`span`,{style:{flex:1,fontSize:12,color:Z.t2,fontFamily:$,lineHeight:1.5},children:e.text}),(0,n.jsx)(`span`,{style:{fontSize:10,fontWeight:600,color:r,background:r+`20`,padding:`2px 7px`,borderRadius:4,fontFamily:$,flexShrink:0},children:e.tag}),(0,n.jsx)(`span`,{style:{fontSize:10,color:Z.t4,fontFamily:Q,flexShrink:0,marginTop:1},children:e.date})]},t)})})}function Et({columns:e,rows:t}){return(0,n.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,gap:5},children:[(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:10,padding:`0 12px 6px`,borderBottom:`1px solid ${Z.border}`},children:[(0,n.jsx)(`div`,{style:{minWidth:64}}),e.map((e,t)=>(0,n.jsx)(`div`,{style:{flex:1,fontSize:9,fontWeight:600,color:Z.t4,fontFamily:$,textTransform:`uppercase`,letterSpacing:.6},children:e},t))]}),t.map((e,t)=>(0,n.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:10,padding:`8px 12px`,background:Z.bg,border:`1px solid ${Z.border}`,borderLeft:`3px solid ${e.color??Z.t4}`,borderRadius:6},children:[(0,n.jsx)(`span`,{style:{fontSize:11,fontWeight:600,color:e.color??Z.t2,background:(e.color??Z.t4)+`1A`,padding:`2px 8px`,borderRadius:4,fontFamily:$,flexShrink:0,minWidth:64,textAlign:`center`},children:e.label}),e.cells.map((t,r)=>(0,n.jsx)(`span`,{style:{flex:1,fontSize:13,fontWeight:700,color:e.color??Z.t1,fontFamily:Q},children:t},r))]},t))]})}function Dt({text:e}){return(0,n.jsxs)(`div`,{style:{marginTop:10,padding:`8px 12px`,background:`rgba(255,255,255,0.015)`,border:`1px solid ${Z.border}`,borderLeft:`2px solid rgba(100,116,139,0.35)`,borderRadius:5},children:[(0,n.jsx)(`span`,{style:{fontSize:10,fontWeight:700,color:Z.t4,fontFamily:$,letterSpacing:.5,textTransform:`uppercase`,marginRight:8},children:`Takeaway`}),(0,n.jsx)(`span`,{style:{fontSize:11,color:Z.t3,fontFamily:$,lineHeight:1.6},children:e})]})}function Ot({block:e}){if(!e)return null;let t=(()=>{switch(e.type){case`stats`:return(0,n.jsx)(pt,{items:e.items});case`ranked`:return(0,n.jsx)(mt,{items:e.items});case`chips`:return(0,n.jsx)(ht,{items:e.items});case`badges`:return(0,n.jsx)(_t,{items:e.items});case`dot-strip`:return(0,n.jsx)(vt,{min:e.min,max:e.max,unit:e.unit,dots:e.dots,chips:e.chips});case`proportion`:return(0,n.jsx)(yt,{leftPct:e.leftPct,leftLabel:e.leftLabel,leftValue:e.leftValue,leftColor:e.leftColor,rightPct:e.rightPct,rightLabel:e.rightLabel,rightValue:e.rightValue,rightColor:e.rightColor,chips:e.chips});case`ring`:return(0,n.jsx)(bt,{pct:e.pct,label:e.label,color:e.color,chips:e.chips});case`scorecard-rows`:return(0,n.jsx)(Ct,{items:e.items});case`flags-list`:return(0,n.jsx)(Tt,{items:e.items});case`comparison-rows`:return(0,n.jsx)(Et,{columns:e.columns,rows:e.rows});default:return null}})();return e.takeaway?(0,n.jsxs)(`div`,{children:[t,(0,n.jsx)(Dt,{text:e.takeaway})]}):t}exports.AreaChart=O,exports.BarChart=j,exports.ChartFrame=r,exports.DonutChart=dt,exports.KeyHighlights=Ot,exports.LineChart=Se,exports.MiniBars=Te,exports.PieChart=Ae,exports.ProcessSankey=Be,exports.RankingSankey=Ve,exports.SankeySvg=Me,exports.SeriesChart=D,exports.TrendChart=Qe,exports.VisualizationRenderer=at,exports.cleanupVisualizationMounts=ct,exports.hydrateVisualizationMounts=lt,exports.serializeVisualizationConfig=ut;
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export { cleanupVisualizationMounts, hydrateVisualizationMounts, serializeVisualizationConfig } from './utils/mounts';
|
|
2
|
+
export { AreaChart } from './components/areaChart/AreaChart';
|
|
3
|
+
export { BarChart } from './components/barChart/BarChart';
|
|
4
|
+
export { ChartFrame } from './components/chartFrame/ChartFrame';
|
|
5
|
+
export { DonutChart } from './components/donutChart/DonutChart';
|
|
6
|
+
export { LineChart } from './components/lineChart/LineChart';
|
|
7
|
+
export { MiniBars } from './components/miniBars/MiniBars';
|
|
8
|
+
export { PieChart } from './components/pieChart/PieChart';
|
|
9
|
+
export { ProcessSankey, RankingSankey, SankeySvg } from './components/sankey';
|
|
10
|
+
export { SeriesChart } from './components/common/SeriesChart';
|
|
11
|
+
export { TrendChart } from './components/trendChart/TrendChart';
|
|
12
|
+
export { KeyHighlights } from './components/keyHighlights/KeyHighlights';
|
|
13
|
+
export { VisualizationRenderer } from './components/visualizationRenderer/VisualizationRenderer';
|
|
14
|
+
export type { BaseVisualizationConfig, KeyHighlightBlock, MiniBarRow, PointPair, SankeyLinkData, SankeyNodeData, VizRow } from './types';
|