1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[94661],{11332:(e,i,t)=>{t.d(i,{u:()=>l});var n=t(95155);function l(e){let{isFree:i}=e;return i?(0,n.jsx)("span",{title:"Free tier available",style:{display:"inline-flex",alignItems:"center",fontSize:9,fontWeight:700,padding:"1px 5px",borderRadius:3,background:"#16a34a22",color:"#16a34a",marginLeft:6,verticalAlign:"middle",letterSpacing:"0.03em",whiteSpace:"nowrap"},children:"FREE"}):null}},29499:(e,i,t)=>{t.d(i,{Cb:()=>o,Gv:()=>a,MO:()=>l,h2:()=>r});var n=t(41274);function l(e){return(0,n.rw)(e)}function r(e){return(0,n.YR)(e)}let a={text:"var(--fg-muted)",image:"#f59e0b",embeddings:"#6b7280",audio:"#3b82f6",video:"#8b5cf6",rerank:"#10b981",speech:"#06b6d4",transcription:"#0ea5e9",decisions:"#8b5cf6"},o={text:"æå",image:"åç",embeddings:"åµå
¥",audio:"é³è¨",video:"å½±ç",rerank:"éæ°æåº",speech:"èªé³åæ",transcription:"èªé³è½é",decisions:"è©ä¼°/決ç"}},72566:(e,i,t)=>{t.d(i,{c:()=>r});var n=t(95155),l=t(52056);function r(e){let{effectiveDeprecationDate:i}=e,t=function(e){if(!e)return null;let i=new Date(e);if(isNaN(i.getTime()))return null;let t=String(i.getUTCMonth()+1).padStart(2,"0"),n=String(i.getUTCDate()).padStart(2,"0");return"EOL ".concat(t,"/").concat(n)}(i);return t?(0,n.jsxs)("span",{title:"Scheduled for deprecation on ".concat(null==i?void 0:i.slice(0,10)),style:{display:"inline-flex",alignItems:"center",gap:3,fontSize:9,fontWeight:700,padding:"1px 5px",borderRadius:3,background:"#f59e0b22",color:"#f59e0b",marginLeft:6,verticalAlign:"middle",letterSpacing:"0.03em",whiteSpace:"nowrap"},children:[(0,n.jsx)(l.A,{size:9}),t]}):null}},94661:(e,i,t)=>{t.d(i,{I:()=>eW});var n=t(95155),l=t(12115),r=t(80003),a=t(91456),o=t(86651),s=t(38990),d=t(1659),c=t(29499),u=t(5917),p=t(75426),g=t(12108),x=t(24033),h=t(74054),f=t(33195),m=t(83850),b=t(47300),v=t(72566),j=t(11332);function y(e){let{hasUsageRebate:i}=e,{t}=(0,d.s9)();return i?(0,n.jsx)("span",{"data-usage-rebate-badge":!0,style:{display:"inline-flex",alignItems:"center",fontSize:9,fontWeight:700,padding:"1px 5px",borderRadius:3,background:"#7c3aed22",color:"#7c3aed",verticalAlign:"middle",whiteSpace:"nowrap"},children:t.models.usageRebateBadge}):null}var w=t(78541);let S={green:"#22c55e",red:"#ef4444",gray:"var(--sl2)"};function k(e){let{overallPct:i,lastProbedAt:t=null,labels:l}=e,r=null===i?["gray","gray","gray"]:i>=99?["green","green","green"]:i>=95?["green","green","gray"]:i>0?["green","gray","gray"]:["red","gray","gray"],a=function(e){let{overallPct:i,lastProbedAt:t,labels:n}=e;return null===i?n.noDataLabel:"".concat(n.hoverLabel," ").concat(i.toFixed(2),"%").concat(t?" \xb7 ".concat(t):"")}({overallPct:i,lastProbedAt:t,labels:l});return(0,n.jsx)("div",{className:"model-metrics-cell","data-testid":"uptime-indicator",title:a,"aria-label":a,style:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",padding:"0 6px"},children:(0,n.jsx)("span",{style:{display:"inline-flex",alignItems:"center",gap:2,height:12},children:r.map((e,i)=>(0,n.jsx)("span",{"data-testid":"uptime-indicator-bar","data-tone":e,style:{display:"block",width:5,height:12,borderRadius:1,background:S[e]}},i))})})}let C={fontFamily:"ui-monospace, monospace",fontVariantNumeric:"tabular-nums"},P={fontSize:11,textTransform:"uppercase",letterSpacing:"0.05em",color:"var(--fg-subtle)",fontWeight:600,padding:"8px 12px",background:"var(--sl2)",borderBottom:"1px solid var(--border)",display:"flex",alignItems:"center",gap:3,userSelect:"none",whiteSpace:"nowrap"},M={padding:"8px 0",borderBottom:"1px solid var(--border)",fontSize:12,display:"grid",alignItems:"center"},z=w.j;function R(e){let{discount:i}=e;return!i||i<=0?null:(0,n.jsxs)("span",{style:{fontSize:9,fontWeight:700,padding:"1px 5px",borderRadius:3,background:"#dc262622",color:"#dc2626",marginLeft:6,verticalAlign:"middle",letterSpacing:"0.03em"},children:["-",i,"%"]})}function A(e){let{id:i}=e,[t,r]=(0,l.useState)(!1);return(0,n.jsx)("button",{onClick:function(e){e.stopPropagation(),navigator.clipboard.writeText(i).then(()=>{r(!0),setTimeout(()=>r(!1),1600)})},title:t?"Copied!":"Copy: ".concat(i),style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:20,height:20,borderRadius:4,flexShrink:0,border:"none",background:"none",color:t?"#16a34a":"var(--fg-subtle)",cursor:"pointer",opacity:+!!t,transition:"opacity 0.1s, color 0.1s",padding:0},children:t?(0,n.jsx)(u.A,{size:11}):(0,n.jsx)(p.A,{size:11})})}let I="36px";function T(e){let{models:i,selection:t}=e,l=i.filter(e=>!t.disabled(e.id)).map(e=>e.id),r=l.length>0&&l.every(e=>t.selected.has(e)),a=!r&&l.some(e=>
1t.selected.has(e));return(0,n.jsx)("div",{style:{...P,justifyContent:"center",padding:"8px 6px"},children:(0,n.jsx)("input",{type:"checkbox","aria-label":"Select all visible models",checked:r,disabled:0===l.length,ref:e=>{e&&(e.indeterminate=a)},onChange:()=>t.onToggleMany(l,!r),style:{cursor:0===l.length?"not-allowed":"pointer"}})})}function W(e){let{model:i,selection:t}=e,l=t.disabled(i.id);return(0,n.jsx)("div",{style:{display:"flex",justifyContent:"center",padding:"0 6px"},title:l?t.disabledReason:void 0,onClick:e=>e.stopPropagation(),children:(0,n.jsx)("input",{type:"checkbox","aria-label":i.id,checked:t.selected.has(i.id),disabled:l,onChange:()=>t.onToggle(i.id),style:{cursor:l?"not-allowed":"pointer"}})})}function L(e){var i;let{model:t,onClick:l}=e,r=null!=(i=t.id.split("/")[0])?i:"";return(0,n.jsxs)("button",{className:"model-name-btn",onClick:e=>{e.stopPropagation(),l()},style:{display:"flex",alignItems:"center",gap:8,background:"none",border:"none",cursor:"pointer",padding:0,textAlign:"left",width:"100%",overflow:"hidden"},children:[(0,n.jsx)(f.Ay,{provider:r,size:16}),(0,n.jsxs)("span",{className:"model-name-text",style:{...C,fontSize:12,color:"var(--fg)"},children:[(0,n.jsxs)("span",{style:{color:"var(--fg-subtle)"},children:[t.provider,":"]})," ",(0,n.jsx)("span",{style:{fontWeight:500},children:t.label}),(0,n.jsx)(R,{discount:t.discount})]})]})}function D(e){let{label:i,active:t,dir:l,onClick:r,align:a="left"}=e,o=t?"asc"===l?g.A:x.A:h.A;return(0,n.jsxs)("div",{onClick:r,style:{...P,cursor:"pointer",justifyContent:"right"===a?"flex-end":"center"===a?"center":"flex-start",color:t?"var(--fg)":"var(--fg-subtle)",fontWeight:t?700:600},children:[i," ",(0,n.jsx)(o,{size:10,style:{opacity:t?1:.4,flexShrink:0}})]})}function O(e){let{current:i,original:t}=e,l=null!=t&&null!=i&&t>i;return(0,n.jsxs)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",whiteSpace:"nowrap"},children:[l&&(0,n.jsx)("span",{style:{color:"var(--fg-subtle)",textDecoration:"line-through",marginRight:6,fontSize:11},children:z(t)}),(0,n.jsx)("span",{style:{color:l?"#dc2626":"var(--fg)",fontWeight:l?600:400},children:z(i)})]})}function N(e){let i=e.id.indexOf("/");return i>=0?e.id.slice(i+1):e.id}function F(e){let{model:i,onRowClick:t,getApiId:r}=e,[a,o]=(0,l.useState)(!1);return(0,n.jsxs)("div",{className:"model-name-cell",style:{...$,display:"flex",alignItems:"center",gap:4},onMouseEnter:()=>o(!0),onMouseLeave:()=>o(!1),children:[(0,n.jsx)(L,{model:i,onClick:t}),(0,n.jsxs)("span",{className:"model-name-meta",style:{display:"inline-flex",alignItems:"center",gap:4},children:[(0,n.jsx)(b.ModalityIcons,{inputModalities:i.inputModalities,outputModalities:i.outputModalities}),(0,n.jsx)(v.c,{effectiveDeprecationDate:i.effectiveDeprecationDate}),(0,n.jsx)(j.u,{isFree:i.isFree}),(0,n.jsx)(y,{hasUsageRebate:i.hasUsageRebate}),(0,n.jsx)("span",{style:{opacity:+!!a,transition:"opacity 0.1s",display:"inline-flex"},children:(0,n.jsx)(A,{id:r(i)})})]})]})}function B(e){let{children:i,cols:t,onClick:l,dimmed:r}=e;return(0,n.jsx)("div",{className:"model-row",onClick:l,style:{...M,gridTemplateColumns:t,cursor:l?"pointer":void 0,opacity:r?.45:void 0},children:i})}function _(e){let{cols:i,children:t}=e;return(0,n.jsx)("div",{style:{display:"grid",gridTemplateColumns:i,position:"sticky",top:0,zIndex:1},children:t})}function E(e){let{cols:i,children:t}=e;return(0,n.jsxs)("div",{style:{overflowX:"auto",WebkitOverflowScrolling:"touch"},children:[(0,n.jsx)("style",{children:"\n.model-name-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }\n@media (max-width: 768px) {\n .model-name-cell { flex-wrap: wrap; row-gap: 2px; }\n .model-name-btn { flex-basis: 100%; }\n .model-name-text {\n white-space: normal;\n overflow-wrap: anywhere;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n }\n .model-row { padding: 10px 0; }\n .model-metrics-cell, .model-metrics-header { display: none !important; }\n}"}),(0,n.jsx)("div",{"data-testid":"model-table-inner",style:{width:"100%",minWidth:function(e){let i=0;for(let n of e.matchAll(/minmax\(\s*(\d+(?:\.\d+)?)px[^)]*\)|(\d+(?:\.\d+)?)px/g)){var t;i+=Number(null!=(t=n[1])?t:n[2])}return i}(i)},children:t})]})}let $={padding:"0 12px",overflow:"hidden",minWidth:0};function J(e,i){return i?"".concat(e," ").concat("52px"):e}function U(e){let{labels:i}=e;return i?(0,n.jsx)("div",{className:"model-metrics-header",title:i.hoverLabel,style:{...P,justifyContent:"center",padding:"8px 4px",overflow:"hidden",textOverflow:"ellipsis"},children:"24h"}):null}function H(e){var i;let{model:t,metricsSummary:l,labels:r}=e;if(!r)return null;let a=null==l?void 0:l.get(t.id);return(0,n.jsx)(k,{overallPct:null!=(i=null==a?void 0:a.overallPct)?i:null,lastProbedAt:null==a?void 0:a.lastProbedAt,labels:r})}function K(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c,unitFallback:u}=e,p=J((s?I+" ":"")+"minmax(240px, 1fr) 140px 140px 130px 130px 90px",c);return(0,n.jsxs)(E,{cols:p,children:[(0,n.jsxs)(_,{cols:p,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}
1),(0,n.jsx)(D,{label:"Input $/M",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(D,{label:"Output $/M",active:"output"===l,dir:r,onClick:()=>a("output"),align:"right"}),(0,n.jsx)(D,{label:"Cache R $/M",active:"cacheRead"===l,dir:r,onClick:()=>a("cacheRead"),align:"right"}),(0,n.jsx)(D,{label:"Cache W $/M",active:"cacheWrite"===l,dir:r,onClick:()=>a("cacheWrite"),align:"right"}),(0,n.jsx)(D,{label:"Context",active:"context"===l,dir:r,onClick:()=>a("context"),align:"right"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>{var i;let l=u&&null==e.inputPrice&&null==e.outputPrice?Y(e):null;return(0,n.jsxs)(B,{cols:p,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),null!=l?(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",whiteSpace:"nowrap"},children:l}):(0,n.jsx)(O,{current:e.inputPrice,original:e.originalInputPrice}),null!=l?(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",color:"var(--fg-subtle)"},children:"â"}):(0,n.jsx)(O,{current:e.outputPrice,original:e.originalOutputPrice}),(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",color:"var(--fg-muted, var(--fg-subtle))",whiteSpace:"nowrap"},children:z(e.cacheReadPrice)}),(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",color:"var(--fg-muted, var(--fg-subtle))",whiteSpace:"nowrap"},children:z(e.cacheWritePrice)}),(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",color:"var(--fg-muted, var(--fg-subtle))",whiteSpace:"nowrap"},children:null==(i=e.contextLength)?"â":i>=1e6?"".concat((i/1e6).toFixed(0),"M"):i>=1e3?"".concat((i/1e3).toFixed(0),"K"):String(i)}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id)})]})}function Y(e){let i=(0,m.r)(e);if(null!=i)return"".concat(z(i),"/min");if(null!=e.pricePerImage)return"".concat(z(e.pricePerImage),"/image");let t=q(e.pricePerImageTiersJson);if(t)return"".concat(t,"/image");if(null!=e.pricePerMegapixel)return"".concat(z(e.pricePerMegapixel),"/MP");let n=function(e){var i,t;let n=Q(e,"720p");if(null!=n)return n;for(let n of[null==(i=e.pricePerSecondJson)?void 0:i.withAudio,null==(t=e.pricePerSecondJson)?void 0:t.withoutAudio])if(n)for(let e of Object.keys(n)){let i=n[e];if(null!=i)return i}return null}(e);return null!=n?"".concat(z(n),"/s"):null!=e.pricePerCharacter?"".concat(z(e.pricePerCharacter),"/1M chars"):null!=e.pricePerSearch?"".concat(z(e.pricePerSearch),"/search"):null!=e.pricePerRequest?"".concat(z(e.pricePerRequest),"/request"):null}function q(e){if(!e)return null;let i=Object.values(e).filter(e=>"number"==typeof e);if(0===i.length)return null;let t=Math.min(...i),n=Math.max(...i);return t===n?z(t):"".concat(z(t),"â").concat(z(n))}function V(e){let{models:i,onRowClick:t,getApiId:l=N,selection:r,metricsSummary:a,metricsLabels:o}=e,s=J((r?I+" ":"")+"minmax(240px, 1fr) 200px minmax(140px, 200px)",o);return(0,n.jsxs)(E,{cols:s,children:[(0,n.jsxs)(_,{cols:s,children:[r&&(0,n.jsx)(T,{models:i,selection:r}),(0,n.jsx)("div",{style:P,children:"Model"}),(0,n.jsx)("div",{style:{...P,justifyContent:"flex-end"},children:"Price"}),(0,n.jsx)("div",{style:P,children:"Capabilities"}),(0,n.jsx)(U,{labels:o})]}),i.map(e=>(0,n.jsxs)(B,{cols:s,onClick:()=>t(e),dimmed:null==r?void 0:r.disabled(e.id),children:[r&&(0,n.jsx)(W,{model:e,selection:r}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:l}),(0,n.jsx)("div",{style:{...C,textAlign:"right",fontSize:12,padding:"0 12px",whiteSpace:"nowrap"},children:function(e){var i;if(e.billingModel&&"token"!==e.billingModel){let i=Y(e);if(i)return i}return null!=e.inputPrice||null!=e.outputPrice?null!=e.inputPrice&&null!=e.outputPrice?"".concat(z(e.inputPrice),"/M in \xb7 ").concat(z(e.outputPrice),"/M out"):null!=e.inputPrice?"".concat(z(e.inputPrice),"/M in"):"".concat(z(e.outputPrice),"/M out"):null!=(i=Y(e))?i:"â"}(e)}),(0,n.jsx)("div",{style:{padding:"0 12px",color:"var(--fg-muted)",fontSize:11},children:e.outputModalities||"Unknown"}),(0,n.jsx)(H,{model:e,metricsSummary:a,labels:o})]},e.id))]})}function X(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c}=e,u=J((s?I+" ":"")+"minmax(240px, 1fr) 140px",c);return(0,n.jsxs)(E,{cols:u,children:[(0,n.jsxs)(_,{cols:u,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}
1),(0,n.jsx)(D,{label:"Input $/M",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>(0,n.jsxs)(B,{cols:u,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),(0,n.jsx)(O,{current:e.inputPrice,original:e.originalInputPrice}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id))]})}function G(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c}=e,u=J((s?I+" ":"")+"minmax(240px, 1fr) 100px 160px",c);return(0,n.jsxs)(E,{cols:u,children:[(0,n.jsxs)(_,{cols:u,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}),(0,n.jsx)(D,{label:"Type",active:!1,dir:r,onClick:()=>{}}),(0,n.jsx)(D,{label:"Price",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>{let i="â",l="â",r=q(e.pricePerImageTiersJson);return null!=e.pricePerMegapixel?(i="megapixel",l="".concat(z(e.pricePerMegapixel)," / MP")):null!=e.pricePerImage?(i="per-image",l="".concat(z(e.pricePerImage)," / image")):r&&(i="tiered",l="".concat(r," / image")),(0,n.jsxs)(B,{cols:u,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),(0,n.jsx)("div",{style:{padding:"0 12px",color:"var(--fg-subtle)",fontSize:11},children:i}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:l}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id)})]})}function Q(e,i){var t,n,l,r,a;let o=null==(n=e.pricePerSecondJson)||null==(t=n.withAudio)?void 0:t[i],s=null==(r=e.pricePerSecondJson)||null==(l=r.withoutAudio)?void 0:l[i];return null!=(a=null!=o?o:s)?a:null}function Z(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c}=e,u=J((s?I+" ":"")+"minmax(220px, 1fr) 100px 100px 100px 80px",c);return(0,n.jsxs)(E,{cols:u,children:[(0,n.jsxs)(_,{cols:u,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}
1),(0,n.jsx)(D,{label:"480p $/s",active:!1,dir:r,onClick:()=>{},align:"right"}),(0,n.jsx)(D,{label:"720p $/s",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(D,{label:"1080p $/s",active:!1,dir:r,onClick:()=>{},align:"right"}),(0,n.jsx)(D,{label:"+Audio",active:!1,dir:r,onClick:()=>{},align:"center"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>{var i;let l=!!(null==(i=e.pricePerSecondJson)?void 0:i.withAudio);return(0,n.jsxs)(B,{cols:u,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:z(Q(e,"480p"))}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:z(Q(e,"720p"))}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:z(Q(e,"1080p"))}),(0,n.jsx)("div",{style:{padding:"0 12px",textAlign:"center",fontSize:11},children:l?(0,n.jsx)("span",{style:{padding:"1px 6px",borderRadius:3,background:"#dbeafe",color:"#1d4ed8",fontWeight:600},children:"YES"}):(0,n.jsx)("span",{style:{color:"var(--fg-subtle)"},children:"â"})}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id)})]})}function ee(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c}=e,u=J((s?I+" ":"")+"minmax(240px, 1fr) 160px",c);return(0,n.jsxs)(E,{cols:u,children:[(0,n.jsxs)(_,{cols:u,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}
1),(0,n.jsx)(D,{label:"$ / 1M chars",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>(0,n.jsxs)(B,{cols:u,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:z(e.pricePerCharacter)}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id))]})}function ei(e){let{models:i,onRowClick:t,sortKey:l,sortDir:r,onSort:a,getApiId:o=N,selection:s,metricsSummary:d,metricsLabels:c}=e,u=J((s?I+" ":"")+"minmax(240px, 1fr) 160px",c);return(0,n.jsxs)(E,{cols:u,children:[(0,n.jsxs)(_,{cols:u,children:[s&&(0,n.jsx)(T,{models:i,selection:s}),(0,n.jsx)(D,{label:"Model",active:"name"===l,dir:r,onClick:()=>a("name")}),(0,n.jsx)(D,{label:"$ / search",active:"input"===l,dir:r,onClick:()=>a("input"),align:"right"}),(0,n.jsx)(U,{labels:c})]}),i.map(e=>(0,n.jsxs)(B,{cols:u,onClick:()=>t(e),dimmed:null==s?void 0:s.disabled(e.id),children:[s&&(0,n.jsx)(W,{model:e,selection:s}),(0,n.jsx)(F,{model:e,onRowClick:()=>t(e),getApiId:o}),(0,n.jsx)("div",{style:{...C,padding:"0 12px",textAlign:"right",fontSize:12},children:z(e.pricePerSearch)}),(0,n.jsx)(H,{model:e,metricsSummary:d,labels:c})]},e.id))]})}var et=t(25016),en=t(44963);let el={fontFamily:"ui-monospace, monospace",fontVariantNumeric:"tabular-nums"};function er(e){let i=e.id.indexOf("/");return i>=0?e.id.slice(i+1):e.id}function ea(e){let{discount:i}=e;return!i||i<=0?null:(0,n.jsxs)("span",{style:{fontSize:9,fontWeight:700,padding:"1px 5px",borderRadius:3,background:"#dc262622",color:"#dc2626",letterSpacing:"0.03em",whiteSpace:"nowrap"},children:["-",i,"%"]})}function eo(e){let{id:i,copyLabel:t,copiedLabel:r}=e,[a,o]=(0,l.useState)(!1);async function s(e){var t;e.stopPropagation(),(null==(t=navigator.clipboard)?void 0:t.writeText)&&await navigator.clipboard.writeText(i),o(!0),window.setTimeout(()=>o(!1),1600)}return(0,n.jsx)("button",{type:"button",title:a?r:t,"aria-label":a?r:t,onClick:s,onKeyDown:e=>e.stopPropagation(),style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:26,height:26,flexShrink:0,padding:0,border:"1px solid var(--border)",borderRadius:5,background:"var(--bg)",color:a?"#16a34a":"var(--fg-subtle)",cursor:"pointer"},children:a?(0,n.jsx)(u.A,{size:12}):(0,n.jsx)(p.A,{size:12})})}function es(e){let{value:i,dateLocale:t}=e;if(!i)return(0,n.jsx)("span",{children:"â"});let l=new Date(i);return Number.isNaN(l.getTime())?(0,n.jsx)("span",{children:"â"}):(0,n.jsx)("span",{children:l.toLocaleDateString(t,{year:"numeric",month:"2-digit",day:"2-digit"})})}function ed(e){let{current:i,original:t,native:l}=e;if(null!=l)return(0,n.jsx)("span",{style:{...el,overflowWrap:"anywhere"},children:l});if(null==i)return(0,n.jsx)("span",{style:{...el,color:"var(--fg-subtle)"},children:"â"});let r=null!=t&&t>i;return(0,n.jsxs)("span",{style:{...el,display:"inline-flex",flexWrap:"wrap",gap:6,alignItems:"baseline"},children:[r&&(0,n.jsx)("span",{style:{color:"var(--fg-subtle)",textDecoration:"line-through",fontSize:11},children:(0,w.j)(t)}),(0,n.jsx)("span",{style:{color:r?"#dc2626":"var(--fg)",fontWeight:r?600:400},children:(0,w.j)(i)})]})}function ec(e){let{section:i,label:t,children:l}=e;return(0,n.jsxs)("div",{"data-card-section":i,style:{display:"flex",justifyContent:"space-between",gap:12,alignItems:"baseline",paddingTop:8},children:[(0,n.jsx)("span",{style:{color:"var(--fg-subtle)",fontSize:11,flexShrink:0},children:t}),(0,n.jsx)("span",{style:{minWidth:0,textAlign:"right",overflowWrap:"anywhere"},children:l})]})}function eu(e){let{label:i,children:t}=e;return(0,n.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:3,minWidth:0},children:[(0,n.jsx)("span",{style:{color:"var(--fg-subtle)",fontSize:10},children:i}),(0,n.jsx)("span",{style:{...el,fontSize:12,overflowWrap:"anywhere"},children:t})]})}function ep(e){let{label:i,active:t,sortDir:l,onClick:r}=e;return(0,n.jsxs)("button",{type:"button","aria-pressed":t,onClick:r,style:{display:"inline-flex",alignItems:"center",gap:4,minHeight:30,padding:"0 9px",border:"1px solid var(--border)",borderRadius:6,background:t?"var(--sl3)":"var(--bg)",color:t?"var(--fg)":"var(--fg-muted)",fontSize:11.5,cursor:"pointer",whiteSpace:"nowrap"},children:[i,t?"asc"===l?" â":" â":""]})}function eg(e){let{sortKey:i,sortDir:t,onSort:l}=e,{t:r}=(0,d.s9)(),a=r.models,o=[["name",a.colModel],["input",a.colInput],["output",a.colOutput],["cacheRead",a.detail.cacheReadPrice],["cacheWrite",a.detail.cacheWritePrice],["context",a.
1colContext]];return(0,n.jsx)("div",{"data-card-sort-controls":!0,style:{display:"flex",flexWrap:"wrap",gap:6,marginBottom:12},children:o.map(e=>{let[r,a]=e;return(0,n.jsx)(ep,{label:a,active:i===r,sortDir:t,onClick:()=>l(r)},r)})})}function ex(e){var i,t,l;let{model:r,onCardClick:a,getApiId:o=er,selection:s,metricsSummary:c,metricsLabels:u}=e,{t:p,locale:g}=(0,d.s9)(),x=p.models,h=(0,en.y)(g),m=o(r),S=r.billingModel&&"token"!==r.billingModel||null==r.inputPrice&&null==r.outputPrice?Y(r):null,C=null==c?void 0:c.get(r.id),P=null!=(i=null==s?void 0:s.disabled(r.id))&&i;function M(){if(s){P||s.onToggle(r.id);return}a(r)}return(0,n.jsx)("article",{"data-model-card":!0,className:"model-card",tabIndex:P?-1:0,"aria-label":"".concat(r.provider,": ").concat(r.label),onClick:M,onKeyDown:e=>{e.target===e.currentTarget&&("Enter"===e.key||" "===e.key)&&(e.preventDefault(),M())},style:{opacity:P?.45:1},children:(0,n.jsxs)("div",{style:{padding:"16px 16px 14px"},children:[(0,n.jsxs)("div",{"data-card-section":"model",style:{display:"flex",alignItems:"flex-start",gap:8},children:[s&&(0,n.jsx)("input",{type:"checkbox","aria-label":r.id,checked:s.selected.has(r.id),disabled:P,onChange:()=>s.onToggle(r.id),onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),style:{marginTop:3,flexShrink:0}}),(0,n.jsx)(f.Ay,{provider:null!=(t=r.id.split("/")[0])?t:"",size:20}),(0,n.jsxs)("div",{style:{minWidth:0,flex:1},children:[(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",flexWrap:"wrap",gap:5,lineHeight:1.45},children:[(0,n.jsxs)("span",{style:{...el,color:"var(--fg-subtle)",fontSize:11},children:[r.provider,":"]}),(0,n.jsx)("strong",{style:{fontSize:14,fontWeight:600,overflowWrap:"anywhere"},children:r.label}),(0,n.jsx)(ea,{discount:r.discount}),(0,n.jsx)(v.c,{effectiveDeprecationDate:r.effectiveDeprecationDate}),(0,n.jsx)(j.u,{isFree:r.isFree}),(0,n.jsx)(y,{hasUsageRebate:r.hasUsageRebate}),(0,n.jsx)(b.ModalityIcons,{inputModalities:r.inputModalities,outputModalities:r.outputModalities})]}),(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:6,marginTop:5,minWidth:0},children:[(0,n.jsx)("code",{"data-model-api-id":!0,style:{...el,color:"var(--fg-muted)",fontSize:11,overflowWrap:"anywhere"},children:m}),(0,n.jsx)(eo,{id:m,copyLabel:h.copyModelId,copiedLabel:h.copied})]})]})]}),(0,n.jsx)("div",{"data-card-section":"description",style:{marginTop:14,color:r.description?"var(--fg-muted)":"var(--fg-subtle)",fontSize:12.5,lineHeight:1.55,overflowWrap:"anywhere"},children:r.description||x.detail.noDescription}),(0,n.jsxs)("div",{"data-card-section":"provider-date",style:{display:"flex",justifyContent:"space-between",gap:12,marginTop:13,paddingTop:10,borderTop:"1px solid var(--border)",color:"var(--fg-muted)",fontSize:11.5},children:[(0,n.jsxs)("span",{children:[(0,n.jsxs)("span",{style:{color:"var(--fg-subtle)"},children:[x.colProvider,": "]}),r.provider]}),(0,n.jsxs)("span",{children:[(0,n.jsxs)("span",{style:{color:"var(--fg-subtle)"},children:[x.cols.released,": "]}),(0,n.jsx)(es,{value:r.releasedAt,dateLocale:h.dateLocale})]})]}),(0,n.jsx)(ec,{section:"context",label:x.colContext,children:(0,n.jsx)("span",{style:el,children:(0,et.FO)(r.contextLength)})}),(0,n.jsx)(ec,{section:"input",label:S?x.detail.inputPrice:x.colInput,children:(0,n.jsx)(ed,{current:r.inputPrice,original:r.originalInputPrice,native:S})}),(0,n.jsx)(ec,{section:"output",label:S?x.detail.outputPrice:x.colOutput,children:(0,n.jsx)(ed,{current:S?null:r.outputPrice,original:S?null:r.originalOutputPrice})}),(0,n.jsxs)("div",{"data-card-section":"secondary",style:{display:"grid",gridTemplateColumns:"repeat(3, minmax(0, 1fr))",gap:10,marginTop:14,paddingTop:12,borderTop:"1px solid var(--border)"},children:[(0,n.jsx)(eu,{label:x.detail.cacheReadPrice,children:null==r.cacheReadPrice?"â":(0,w.j)(r.cacheReadPrice)}),(0,n.jsx)(eu,{label:x.detail.cacheWritePrice,children:null==r.cacheWritePrice?"â":(0,w.j)(r.cacheWritePrice)}),u&&(0,n.jsx)(eu,{label:"24h",children:(0,n.jsx)(k,{overallPct:null!=(l=null==C?void 0:C.overallPct)?l:null,lastProbedAt:null==C?void 0:C.lastProbedAt,labels:u})})]})]})})}function eh(e){let{models:i,onCardClick:t,getApiId:l,selection:r,metricsSummary:a,metricsLabels:o}=e;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("style",{children:"\n.model-card-grid {\n display: grid;\n grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));\n gap: 12px;\n align-items: stretch;\n}\n.model-card {\n min-width: 0;\n box-sizing: border-box;\n overflow: hidden;\n border: 1px solid var(--border);\n border-radius: 10px;\n background: var(--bg);\n color: var(--fg);\n cursor: pointer;\n outline: none;\n transition: background 0.12s, border-color 0.12s;\n}\n.model-card:hover { background: var(--sl2); border-color: var(--border-hi); }\n.model-card:focus-visible { outline: 1.5px solid var(--sl9); outline-offset: 2px; }\n.model-card-grid .model-card * { min-width: 0; }\n@media (max-width: 767px) {\n .model-card-grid { grid-template-columns: 1fr; }\n .model-card { border-radius: 8px; }\n}\n"}),(0,n.jsx)("div",{className:"model-card-grid","data-mobile-columns":"1",children:i.map(e=>(0,n.jsx)(ex,{model:e,onCardClick:t,getApiId:l,selection:r,metricsSummary:a,metricsLabels:o},e.id))})]})}let ef=["text","image","file","audio","video"],em=["chat","vision","reasoning","tools","longContext","coding"],eb=["token","image","second","character","megapixel","search"];function ev(e){if(!e)return new Set;let i=new Set(ef);return new Set(e.split(",").map(e=>e.trim().toLowerCase()).filter(e=>i.has(e)))}function ej(e){var i;return null!=(i=e.billingModel)?i:"token"}function ey(e){return e.inputPrice}function ew(e){if(null!=e.inputPrice)return e.inputPrice;if(null!=e.pricePerCharacter)return e.pricePerCharacter;if(null!=e.pricePerSearch)return e.pricePerSearch;if(null!=e.pricePerMegapixel)return e.pricePerMegapixel;if(null!=e.pricePerImage)return e.pricePerImage;if(e.pricePerSecondJson){var i,t;let n=[...Object.values(null!=(i=e.pricePerSecondJson.withoutAudio)?i:{}),...Object.values(null!=(t=e.pricePerSecondJson.withAudio)?t:{})].filter(e=>"number"==typeof e);return n.length?Math.min(...n):null}return null}function eS(e){return(0,et.th)(e.id)}function ek(e){var i,t;let n=new Set;e.__cats.includes("text")&&n.add("chat"),ev(e.inputModalities).has("image")&&n.add("vision");let l=(null!=(i=e.supportedParameters)?i:"").toLowerCase();return l.includes("reasoning")&&n.add("reasoning"),l.includes("tool")&&n.add("tools"),(null!=(t=e.contextLength)?t:0)>=2e5&&n.add("longContext"),e.category.includes("coding")&&n.add("coding"),n}function eC(e,i){if(0===i.size)return!0;for(let t of i)if(e.has(t))return!0;return!1}function eP(e,i){return null===i||null===e||e>=i[0]&&e<=i[1]}function eM(e,i){if(i.rebateOnly&&!e.hasUsageRebate)return!1;if(i.search){let t=i.search.toLowerCase();if(!e.id.toLowerCase().includes(t)&&!e.label.toLowerCase().includes(t))return!1}return!!eC(ev(e.inputModalities),i.modalities)&&!!eC(ek(e),i.capabilities)&&(!(i.billing.size>0)||!!i.billing.has(ej(e)))&&(!(i.providers.size>0)||!!i.providers.has(eS(e)))&&!!eP(e.contextLength,i.contextRange)&&!!eP(ey(e),i.priceRange)}function ez(e){let i=0;return e.rebateOnly&&i++,e.search&&i++,e.modalities.size&&i++,e.capabilities.size&&i++,e.billing.size&&i++,e.providers.size&&i++,e.contextRange&&i++,e.priceRange&&i++,i}function eR(e){var i;return null!=e.effectiveDeprecationDate?0:e.isFree?1:(null!=(i=e.discount)?i:0)>0?2:3}
1function eA(e){let{min:i,max:t,value:l,onChange:r,step:a=1,format:o}=e,[s,d]=l;return i>=t?null:(0,n.jsxs)("div",{style:{padding:"2px 4px 0"},children:[(0,n.jsxs)("div",{style:{position:"relative",height:24},children:[(0,n.jsx)("input",{type:"range",min:i,max:t,step:a,value:s,onChange:e=>r([Math.min(Number(e.target.value),d),d]),"aria-label":"minimum",style:{position:"absolute",width:"100%",pointerEvents:"auto",background:"none",appearance:"none",WebkitAppearance:"none",margin:0}}),(0,n.jsx)("input",{type:"range",min:i,max:t,step:a,value:d,onChange:e=>r([s,Math.max(Number(e.target.value),s)]),"aria-label":"maximum",style:{position:"absolute",width:"100%",pointerEvents:"auto",background:"none",appearance:"none",WebkitAppearance:"none",margin:0}})]}),(0,n.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",fontSize:11,color:"var(--fg-subtle)",marginTop:2},children:[(0,n.jsx)("span",{children:o(s)}),(0,n.jsx)("span",{children:o(d)})]})]})}function eI(e){var i,t;let{filters:l,onChange:r,counts:a,bounds:o,providers:s}=e,{t:c}=(0,d.s9)(),u=c.models.filters;function p(e,i){let t=new Set(e);return t.has(i)?t.delete(i):t.add(i),t}let g=(e,i,t,l,r)=>{let a=(null!=l?l:0)===0;return(0,n.jsxs)("label",{style:{display:"flex",alignItems:"center",gap:8,padding:"3px 0",fontSize:13,cursor:a?"default":"pointer",color:a?"var(--fg-subtle)":"var(--fg)",opacity:a?.5:1},children:[(0,n.jsx)("input",{type:"checkbox",checked:t,disabled:a&&!t,onChange:r}),(0,n.jsx)("span",{style:{flex:1},children:e}),(0,n.jsx)("span",{style:{fontSize:11,color:"var(--fg-subtle)"},children:null!=l?l:0})]},i)},x=(e,i)=>(0,n.jsxs)("div",{style:{padding:"12px 0",borderBottom:"1px solid var(--border)"},children:[(0,n.jsx)("div",{style:{fontSize:12,fontWeight:600,color:"var(--fg-muted)",marginBottom:6,textTransform:"uppercase",letterSpacing:"0.04em"},children:e}),i]}),h=ez(l);return(0,n.jsxs)("aside",{style:{width:"100%",fontSize:13},children:[(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",paddingBottom:8},children:[(0,n.jsx)("span",{style:{fontSize:14,fontWeight:600,color:"var(--fg)"},children:u.heading}),h>0&&(0,n.jsxs)("button",{onClick:()=>r({...l,rebateOnly:!1,modalities:new Set,capabilities:new Set,billing:new Set,providers:new Set,contextRange:null,priceRange:null,search:l.search}),style:{fontSize:12,color:"#2563eb",background:"none",border:"none",cursor:"pointer"},children:[u.clearAll," (",h,")"]})]}),(0,n.jsx)("div",{style:{padding:"12px 0",borderBottom:"1px solid var(--border)"},children:g(u.usageRebateOnly,"usage-rebate",!!l.rebateOnly,a.rebateOnly,()=>r({...l,rebateOnly:!l.rebateOnly}))}),x(u.modalitiesTitle,ef.map(e=>g(u.modality[e],e,l.modalities.has(e),a.modalities[e],()=>r({...l,modalities:p(l.modalities,e)})))),x(u.capabilitiesTitle,(0,n.jsxs)(n.Fragment,{children:[em.map(e=>g(u.capability[e],e,l.capabilities.has(e),a.capabilities[e],()=>r({...l,capabilities:p(l.capabilities,e)}))),(0,n.jsx)("div",{style:{fontSize:10.5,color:"var(--fg-subtle)",marginTop:4},children:u.codingHint})]})),x(u.billingTitle,eb.map(e=>g(u.billing[e],e,l.billing.has(e),a.billing[e],()=>r({...l,billing:p(l.billing,e)})))),o.context&&x(u.contextTitle,(0,n.jsx)(eA,{min:o.context[0],max:o.context[1],step:1e3,value:null!=(i=l.contextRange)?i:o.context,format:e=>(0,et.FO)(e),onChange:e=>r({...l,contextRange:e[0]===o.context[0]&&e[1]===o.context[1]?null:e})})),o.price&&x(u.priceTitle,(0,n.jsx)(eA,{min:o.price[0],max:o.price[1],step:.01,value:null!=(t=l.priceRange)?t:o.price,format:e=>"$".concat(e.toFixed(2)),onChange:e=>r({...l,priceRange:e[0]===o.price[0]&&e[1]===o.price[1]?null:e})})),x(u.providersTitle,s.map(e=>g(e,e,l.providers.has(e),a.providers[e],()=>r({...l,providers:p(l.providers,e)}))))]})}let eT=["all","text","image","embeddings","audio","video","rerank","speech","transcription","decisions"];function eW(e){let{models:i,presentation:t="table",onPresentationChange:u,titleSlot:p,onRowClick:g,getApiId:x,selection:h,metricsSummary:f,tableMaxHeight:m,hideFilters:b=!1}=e,{t:v}=(0,d.s9)(),j=v.models,y=(0,s.a)(),w=f||"cards"===t?{hoverLabel:v.seo.modelDetail.availability.listColumnAvailability,noDataLabel:v.seo.modelDetail.availability.listColumnNoData}:void 0,[S,k]=(0,l.useState)({search:"",rebateOnly:!1,modalities:new Set,capabilities:new Set,billing:new Set,providers:new Set,contextRange:null,priceRange:null}),[C,P]=(0,l.useState)(!1),[M,z]=(0,l.useState)("all"),[R,A]=(0,l.useState)("name"),[I,T]=(0,l.useState)("asc"),W=S.search,L=(0,l.useMemo)(()=>i.map(e=>{let i=(0,c.MO)({outputModalities:e.outputModalities,billingModel:e.billingModel,canonicalId:e.id});return{...e,__cats:i}}),[i]),D=(0,l.useMemo)(()=>Array.from(new Set(L.map(e=>{var i;return null!=(i=e.id.split("/")[0])?i:""}
1))).filter(Boolean).sort(),[L]),O=(0,l.useMemo)(()=>{let e={all:L.length,text:0,image:0,embeddings:0,audio:0,video:0,rerank:0,speech:0,transcription:0,decisions:0};for(let i of L)for(let t of i.__cats)e[t]+=1;return e},[L]),N=(0,l.useMemo)(()=>{let e=L.filter(e=>("all"===M||e.__cats.includes(M))&&eM(e,S)),i="asc"===I?1:-1;return[...e].sort((e,t)=>{var n,l,r,a,o,s,d,c,u,p;let g=eR(e),x=eR(t);if(g!==x)return g-x;if("all"===M&&("input"===R||"output"===R||"cacheRead"===R||"cacheWrite"===R)){let i=null!=e.inputPrice||null!=e.outputPrice;if(i!==(null!=t.inputPrice||null!=t.outputPrice))return i?-1:1}let h=0;switch(R){case"input":h=i*((null!=(n=ew(e))?n:1/0)-(null!=(l=ew(t))?l:1/0));break;case"output":h=i*((null!=(r=e.outputPrice)?r:0)-(null!=(a=t.outputPrice)?a:0));break;case"cacheRead":h=i*((null!=(o=e.cacheReadPrice)?o:0)-(null!=(s=t.cacheReadPrice)?s:0));break;case"cacheWrite":h=i*((null!=(d=e.cacheWritePrice)?d:0)-(null!=(c=t.cacheWritePrice)?c:0));break;case"context":h=i*((null!=(u=e.contextLength)?u:0)-(null!=(p=t.contextLength)?p:0));break;case"name":h=i*e.label.localeCompare(t.label);break;default:h=0}if(0!==h)return h;let f=e.label.localeCompare(t.label);return 0!==f?f:e.id.localeCompare(t.id)})},[L,S,M,R,I]),F=(0,l.useMemo)(()=>(function(e){let i=e.map(e=>e.contextLength).filter(e=>null!=e),t=e.map(ey).filter(e=>null!=e);return{context:i.length?[Math.min(...i),Math.max(...i)]:null,price:t.length?[Math.min(...t),Math.max(...t)]:null}})(L),[L]),B=(0,l.useMemo)(()=>(function(e,i){var t,n,l,r;let a=e=>({...i,[e]:new Set}),o={},s={},d={},c={};for(let i of e.filter(e=>eM(e,a("modalities"))))for(let e of ev(i.inputModalities))o[e]=(null!=(t=o[e])?t:0)+1;for(let i of e.filter(e=>eM(e,a("capabilities"))))for(let e of ek(i))s[e]=(null!=(n=s[e])?n:0)+1;for(let i of e.filter(e=>eM(e,a("billing")))){let e=ej(i);d[e]=(null!=(l=d[e])?l:0)+1}for(let i of e.filter(e=>eM(e,a("providers")))){let e=eS(i);c[e]=(null!=(r=c[e])?r:0)+1}let u={...i,rebateOnly:!1};return{modalities:o,capabilities:s,billing:d,providers:c,rebateOnly:e.filter(e=>e.hasUsageRebate&&eM(e,u)).length}})(L,S),[L,S]);function _(e){R===e?T(e=>"asc"===e?"desc":"asc"):(A(e),T("asc"))}let E=null!=m;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",justifyContent:p?"space-between":"flex-end",marginBottom:14,gap:12,flexWrap:"wrap"},children:[p,(0,n.jsxs)("div",{style:{display:"flex",alignItems:"center",gap:8,width:y?"100%":void 0},children:[u&&(0,n.jsxs)("div",{"data-testid":"models-view-toggle",role:"group","aria-label":j.viewToggle.label,style:{display:"inline-flex",alignItems:"center",gap:2,flexShrink:0,height:34,padding:2,border:"1px solid var(--border)",borderRadius:8,background:"var(--sl1)"},children:[(0,n.jsx)("button",{type:"button","data-testid":"models-view-table","aria-label":j.viewToggle.table,title:j.viewToggle.table,"aria-pressed":"table"===t,onClick:()=>u("table"),style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:30,height:28,padding:0,border:0,borderRadius:6,background:"table"===t?"var(--sl3)":"transparent",color:"var(--fg)",cursor:"pointer"},children:(0,n.jsx)(r.A,{size:16,"aria-hidden":"true"})}),(0,n.jsx)("button",{type:"button","data-testid":"models-view-cards","aria-label":j.viewToggle.cards,title:j.viewToggle.cards,"aria-pressed":"cards"===t,onClick:()=>u("cards"),style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:30,height:28,padding:0,border:0,borderRadius:6,background:"cards"===t?"var(--sl3)":"transparent",color:"var(--fg)",cursor:"pointer"},children:(0,n.jsx)(a.A,{size:16,"aria-hidden":"true"})})]}),(0,n.jsxs)("div",{style:{position:"relative",flex:y?1:void 0},children:[(0,n.jsx)(o.A,{size:14,style:{position:"absolute",left:10,top:"50%",transform:"translateY(-50%)",color:"var(--fg-subtle)",pointerEvents:"none"}}),(0,n.jsx)("input",{value:W,onChange:e=>{let i;return i=e.target.value,k(e=>({...e,search:i}))},placeholder:j.searchPlaceholder,style:{height:34,width:y?"100%":240,fontSize:13,paddingLeft:32,paddingRight:10,border:"1px solid var(--border)",borderRadius:8,background:"var(--sl1)",color:"var(--fg)",outline:"none",transition:"border-color 0.15s",boxSizing:"border-box"}})]}),y&&!b&&(0,n.jsxs)("button",{onClick:()=>P(!0),style:{height:34,padding:"0 12px",fontSize:13,flexShrink:0,border:"1px solid var(--border)",borderRadius:8,background:"var(--sl1)",color:"var(--fg)",cursor:"pointer"},children:[j.filters.mobileToggle,ez(S)>0?" (".concat(ez(S),")"):""]})]})]}),(0,n.jsxs)("div",{style:{display:"flex",gap:20,alignItems:"flex-start"},children:[!y&&!b&&(0,n.jsx)("div",{style:{width:240,flexShrink:0,position:"sticky",top:72*!E,marginLeft:20,maxHeight:"calc(100vh - 88px)",overflowY:"auto",overscrollBehavior:"contain",paddingRight:4},children:(0,n.jsx)(eI,{filters:S,onChange:k,counts:B,bounds:F,providers:D})}),(0,n.jsxs)("div",{style:{flex:1,minWidth:0},children:[(0,n.jsx)("div",{style:{display:"flex",gap:4,borderBottom:"1px solid var(--border)",marginBottom:12,overflowX:"auto",paddingBottom:0},children:eT.map(e=>{var i,t,l,r;let a=O[e];if("all"!==e&&0===a)return null;let o=M===e,s="all"===e?null!=(l=null==(i=j.tabs)?void 0:i.all)?l:"All":null!=(r=null==(t=j.tabs)?void 0:t[e])?r:c.Cb[e];return(0,n.jsxs)("button",{onClick:()=>z(e),style:{padding:"8px 12px",fontSize:13,fontWeight:o?600:500,background:"none",border:"none",cursor:"pointer",color:o?"var(--fg)":"var(--fg-muted)",borderBottom:o?"2px solid var(--fg)":"2px solid transparent",marginBottom:-1,whiteSpace:"nowrap",transition:"color 0.12s, border-color 0.12s"},children:[s," ",(0,n.jsx)("span",{style:{color:"var(--fg-subtle)",fontWeight:400},children:a})]},e)})}),"cards"===t?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(eg,{sortKey:R,sortDir:I,onSort:_}),(0,n.jsx)(eh,{models:N,onCardClick:function(e){if(h){h.disabled(e.id)||h.onToggle(e.id);return}null==g||g(e)},getApiId:x,selection:h,metricsSummary:f,metricsLabels:w})]}):(0,n.jsx)("div",{style:{border:"1px solid var(--border)",borderRadius:8,overflow:"hidden",background:"var(--bg)",boxShadow:"0 1px 4px rgba(0,0,0,0.04)",...E?{maxHeight:m,overflowY:"auto"}:null},children:function(){let e={models:N,onRowClick:h?e=>{h.disabled(e.id)||h.onToggle(e.id)}:e=>{null==g||g(e)},sortKey:R,sortDir:I,onSort:_,getApiId:x,selection:h,metricsSummary:f,metricsLabels:w};switch(M){case"image":return(0,n.jsx)(G,{...e});case"video":return(0,n.jsx)(Z,{...e});case"audio":default:return(0,n.jsx)(K,{...e});case"speech":return(0,n.jsx)(ee,{...e});case"embeddings":return(0,n.jsx)(X,{...e});case"rerank":return(0,n.jsx)(ei,{...e});case"transcription":case"decisions":return(0,n.jsx)(V,{...e});case"all":return(0,n.jsx)(K,{...e,unitFallback:!0})}}()}),(0,n.jsxs)("div",{style:{marginTop:8,fontSize:11.5,color:"var(--fg-subtle)"}
1,children:[N.length.toLocaleString()," / ",L.length.toLocaleString()," models"]})]})]}),y&&!b&&C&&(0,n.jsxs)("div",{style:{position:"fixed",inset:0,zIndex:50,background:"var(--bg)",overflow:"auto",padding:16},children:[(0,n.jsx)("div",{style:{display:"flex",justifyContent:"flex-end"},children:(0,n.jsx)("button",{onClick:()=>P(!1),style:{background:"none",border:"none",fontSize:22,color:"var(--fg-muted)",cursor:"pointer"},children:"\xd7"})}),(0,n.jsx)(eI,{filters:S,onChange:k,counts:B,bounds:F,providers:D}),(0,n.jsxs)("button",{onClick:()=>P(!1),style:{width:"100%",marginTop:16,height:40,borderRadius:8,border:"none",background:"var(--fg)",color:"var(--bg)",fontSize:14,fontWeight:600,cursor:"pointer"},children:[N.length.toLocaleString()," / ",L.length.toLocaleString()]})]})]})}}}]);
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.