1import{r as l,j as e,C as o,b as i,p as n,a as t,d as c,af as d,ab as x,z as m}from"./index-CT3mG8No.js";import{F as p}from"./factory-BrNm9KyS.js";import{T as h}from"./truck-7wsFOvIT.js";const N=({symbol:u})=>{const r=l.useMemo(()=>({totalBacklog:2458e8,backlogChange:8.5,averageLeadTime:42,leadTimeChange:-5.2,capacityUtilization:87.5,yoyOrderGrowth:12.4,quarterlyOrders:[{quarter:"Q1 23",orders:625e8,delivered:582e8,backlog:2185e8},{quarter:"Q2 23",orders:682e8,delivered:614e8,backlog:2253e8},{quarter:"Q3 23",orders:718e8,delivered:648e8,backlog:2323e8},{quarter:"Q4 23",orders:754e8,delivered:672e8,backlog:2405e8},{quarter:"Q1 24",orders:782e8,delivered:729e8,backlog:2458e8}],productMix:[{product:"iPhone",orders:42.5,revenue:48.2,margin:38.5},{product:"Mac",orders:18.2,revenue:22.1,margin:32.4},{product:"iPad",orders:12.8,revenue:10.5,margin:28.6},{product:"Wearables",orders:15.4,revenue:12.8,margin:35.2},{product:"Services",orders:11.1,revenue:6.4,margin:72.1}],regionBreakdown:[{region:"Americas",share:42.5,growth:8.2},{region:"Europe",share:24.8,growth:5.4},{region:"Greater China",share:18.4,growth:-2.1},{region:"Japan",share:6.8,growth:12.5},{region:"Rest of Asia Pacific",share:7.5,growth:15.8}],supplierHealth:{onTimeDelivery:94.2,qualityScore:98.5,riskScore:"low",criticalSuppliers:12,atRiskSuppliers:2},inventoryMetrics:{daysOnHand:8.5,turnover:42.8,channelInventory:"lean",weeksCoverage:4.2}}),[]);return e.jsxs(o,{className:"bg-card/50 border-border/50",children:[e.jsx(i,{className:"pb-3",children:e.jsxs(n,{className:"flex items-center gap-2 text-base",children:[e.jsx(p,{className:"w-4 h-4 text-primary"}),"Factory Orders & Production Intelligence",e.jsxs(t,{variant:"default",className:"ml-auto text-[10px]",children:["+",r.yoyOrderGrowth,"% YoY"]})]})}),e.jsxs(c,{className:"space-y-4",children:[e.jsxs("div",{className:"grid grid-cols-4 gap-2",children:[e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsx("p",{className:"text-[10px] text-muted-foreground uppercase",children:"Order Backlog"}),e.jsxs("p",{className:"font-mono font-bold text-foreground",children:["$",(r.totalBacklog/1e9).toFixed(1),"B"]}),e.jsxs("p",{className:`text-[9px] ${r.backlogChange>0?"text-profit":"text-loss"}`,children:[r.backlogChange>0?"+":"",r.backlogChange,"% QoQ"]})]}),e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsx("p",{className:"text-[10px] text-muted-foreground uppercase",children:"Lead Time"}),e.jsxs("p",{className:"font-mono font-bold text-foreground",children:[r.averageLeadTime," days"]}),e.jsxs("p",{className:`text-[9px] ${r.leadTimeChange<0?"text-profit":"text-loss"}`,children:[r.leadTimeChange,"% vs avg"]})]}),e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsx("p",{className:"text-[10px] text-muted-foreground uppercase",children:"Capacity Util"}),e.jsxs("p",{className:"font-mono font-bold text-foreground",children:[r.capacityUtilization,"%"]}),e.jsx(d,{value:r.capacityUtilization,className:"h-1 mt-1"})]}),e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsx("p",{className:"text-[10px] text-muted-foreground uppercase",children:"Inventory DOH"}),e.jsx("p",{className:"font-mono font-bold text-foreground",children:r.inventoryMetrics.daysOnHand}),e.jsx(t,{variant:"outline",className:"text-[8px]",children:r.inventoryMetrics.channelInventory})]})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx("p",{className:"text-xs font-medium text-foreground",children:"Quarterly Orders vs Deliveries"}),e.jsx("div",{className:"flex items-end gap-1 h-20",children:r.quarterlyOrders.map((s,a)=>e.jsxs("div",{className:"flex-1 flex flex-col items-center gap-0.5",children:[e.jsxs("div",{className:"w-full flex gap-0.5 items-end h-14",children:[e.jsx("div",{className:"flex-1 bg-primary/60 rounded-t",style:{height:`${s.orders/8e10*100}%`},title:`Orders: $${(s.orders/1e9).toFixed(1)}B`}),e.jsx("div",{className:"flex-1 bg-profit/60 rounded-t",style:{height:`${s.delivered/8e10*100}%`},title:`Delivered: $${(s.delivered/1e9).toFixed(1)}B`})]}),e.jsx("span",{className:"text-[8px] text-muted-foreground",children:s.quarter})]},a))}),e.jsxs("div",{className:"flex justify-center gap-4 text-[9px]",children:[e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx("span",{className:"w-2 h-2 bg-primary/60 rounded"})," Orders"]}),e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx("span",{className:"w-2 h-2 bg-profit/60 rounded"})," Delivered"]})]})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx("p",{className:"text-xs font-medium text-foreground",children:"Product Mix Analysis"}),e.jsx("div",{className:"space-y-1.5",children:r.productMix.map((s,a)=>e.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[e.jsx("span",{className:"w-16 text-muted-foreground",children:s.product}),e.jsx("div",{className:"flex-1 h-2 bg-secondary rounded overflow-hidden",children:e.jsx("div",{className:"h-full bg-primary/60 rounded",style:{width:`${s.orders}%`}})}),e.jsxs("span",{className:"font-mono text-foreground w-10 text-right",children:[s.orders,"%"]}),e.jsxs("span",{className:"font-mono text-profit w-12 text-right",children:[s.margin,"%"]})]},a))}),e.jsxs("div",{className:"flex justify-end gap-4 text-[9px] text-muted-foreground",children:[e.jsx("span",{children:"Order Share"}),e.jsx("span",{children:"Margin"})]})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsxs("p",{className:"text-xs font-medium text-foreground flex items-center gap-1",children:[e.jsx(x,{className:"w-3 h-3"})," Regional Order Distribution"]}
1),e.jsx("div",{className:"grid grid-cols-5 gap-1.5",children:r.regionBreakdown.map((s,a)=>e.jsxs("div",{className:"bg-background/50 p-1.5 rounded border border-border/30 text-center",children:[e.jsx("p",{className:"text-[9px] text-muted-foreground truncate",children:s.region}),e.jsxs("p",{className:"font-mono font-bold text-xs text-foreground",children:[s.share,"%"]}),e.jsxs("p",{className:`text-[9px] ${s.growth>0?"text-profit":"text-loss"}`,children:[s.growth>0?"+":"",s.growth,"%"]})]},a))})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsxs("p",{className:"text-xs font-medium text-foreground flex items-center gap-1",children:[e.jsx(h,{className:"w-3 h-3"})," Supply Chain Health"]}),e.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsxs("div",{className:"flex justify-between text-xs",children:[e.jsx("span",{className:"text-muted-foreground",children:"On-Time Delivery"}),e.jsxs("span",{className:"font-mono text-profit",children:[r.supplierHealth.onTimeDelivery,"%"]})]}),e.jsx(d,{value:r.supplierHealth.onTimeDelivery,className:"h-1 mt-1"})]}),e.jsxs("div",{className:"bg-background/50 p-2 rounded border border-border/30",children:[e.jsxs("div",{className:"flex justify-between text-xs",children:[e.jsx("span",{className:"text-muted-foreground",children:"Quality Score"}),e.jsxs("span",{className:"font-mono text-profit",children:[r.supplierHealth.qualityScore,"%"]})]}),e.jsx(d,{value:r.supplierHealth.qualityScore,className:"h-1 mt-1"})]})]}),e.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[e.jsxs("span",{className:"text-muted-foreground",children:["Critical Suppliers: ",e.jsx("span",{className:"font-mono text-foreground",children:r.supplierHealth.criticalSuppliers})]}),r.supplierHealth.atRiskSuppliers>0&&e.jsxs(t,{variant:"destructive",className:"text-[9px] flex items-center gap-1",children:[e.jsx(m,{className:"w-3 h-3"}),r.supplierHealth.atRiskSuppliers," at risk"]})]})]})]})]})};export{N as FactoryOrdersPanel};
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.