PageSourceSearch

https://cdn.wisgate.ai/wisgate/_nuxt/BAqcsrnn.js

js wisgate.ai collected 2026-10-04 13:25:13 UTC 11,829 bytes, 1 lines download raw bytes

1import{d as ae,u as ie,g as le,r as u,bF as ne,a as w,v as re,bU as de,w as ce,j as r,o as d,l as e,k as c,q as S,p as a,m as l,Q as D,n as pe,Y as ue,ay as B,F as g,x as U,K as $,s as z,bH as _e,cs as me,y as ve,bN as xe,W as ge}from"./DZ7mik94.js";import{_ as fe}from"./BDcM2FMb.js";import be from"./V_uJWu5o.js";import{M as ye}from"./D-7PkliZ.js";import{i as he,c as q,d as we,f as ke,g as Pe,b as Me,p as _}from"./y0XJ1xRd.js";import{d as Ce}from"./CIZylvxh.js";const Te={class:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8"},Le={class:"text-4xl font-bold text-slate-900 font-sans mb-4"},Se={class:"text-lg text-slate-500"},ze={class:"relative w-full md:w-96"},Ie=["placeholder"],je={class:"flex gap-3 w-full md:w-auto"},De={class:"relative"},Ue={value:""},$e=["value"],Fe={class:"relative"},Re={value:""},Ve=["value"],Be={key:0,class:"absolute inset-0 bg-white/70 backdrop-blur-sm z-10 flex items-center justify-center"},qe={key:0,class:"flex flex-col items-center justify-center h-64 text-slate-500"},Ae={key:1,class:"overflow-x-auto"},Ee={class:"w-full text-left border-collapse"},Ne={class:"bg-slate-50 border-b border-slate-200 text-xs font-semibold text-slate-500 uppercase tracking-wider"},Ge={class:"px-6 py-4 min-w-[300px]"},Oe={class:"px-6 py-4 min-w-[150px]"},Ye={class:"px-6 py-4 min-w-[150px]"},Qe={key:0,class:"px-6 py-4 min-w-[170px]"},We=["data-index","onClick"],He={class:"px-6 py-2"},Ke={class:"flex items-center justify-between"},Je={class:"flex-1 flex items-center gap-3"},Xe={class:"size-9 rounded-lg bg-slate-50 flex items-center justify-center p-1.5"},Ze={class:"flex-1 w-full overflow-hidden"},et={class:"font-medium text-sm text-slate-900 line-clamp-1 overflow-hidden w-full"},tt={class:"text-xs text-slate-500 font-mono mt-0.5 gap-1.5 line-clamp-1 overflow-hidden w-full"},st={key:0,class:"px-6 py-4 text-center",colspan:"2"},ot={class:"text-sm font-semibold text-blue-500"},at={key:1,class:"px-6 py-4 text-center",colspan:"2"},it={class:"text-sm font-semibold text-amber-500"},lt={class:"px-6 py-4 text-slate-600 font-mono text-sm"},nt={class:"text-xs text-slate-500 font-mono mt-0.5"},rt={class:"px-6 py-4 text-slate-600 font-mono text-sm"},dt={class:"text-xs text-slate-500 leading-relaxed"},ct={class:"px-6 py-4 text-slate-600 font-mono text-sm"},pt={class:"text-xs text-slate-500 font-mono mt-0.5 flex items-center gap-1.5"},ut={class:"px-6 py-4 text-slate-600 font-mono text-sm"},_t={class:"text-xs text-slate-500 font-mono mt-0.5 flex items-center gap-1.5"},mt={class:"px-6 py-4 text-slate-600 font-mono text-sm"},vt={class:"text-xs text-slate-500 font-mono mt-0.5 flex items-center gap-1.5"},xt={key:5,class:"px-6 py-4"},gt={key:2,class:"px-6 py-4 border-t border-slate-200 bg-slate-50 flex justify-between items-center"},ft={class:"text-sm text-slate-500"},bt={class:"flex gap-2"},yt=["disabled"],ht=["disabled"],wt=ae({__name:"ModelPricingList",setup(kt){const{t:i}=ie(),F=le(),m=u(!1),I=u(null),j=ne(),k=u(!1),P=u([]),v=u(0),p=u(1),f=u(10),M=u(""),b=u(""),y=u(""),C=u(null),A=w(()=>j.providers),E=w(()=>j.categories),R=w(()=>j.isAvailabilityGridEnabled);re(async()=>{const s=new IntersectionObserver(([o])=>{o?.isIntersecting&&(m.value=!0,s.disconnect())},{threshold:.1});I.value&&s.observe(I.value),await Promise.all([h()])});const h=async()=>{k.value=!0;try{const s={page:p.value,page_size:f.value,sort_by:"input_price",sort_order:"asc"};M.value&&(s.search=M.value),b.value&&(s.provider=b.value),y.value&&(s.category=y.value);const o=await de.getModels(s);P.value=o.data||[],o.total!==void 0&&(v.value=o.total)}catch(s){console.error("Failed to load models:",s),P.value=[],v.value=0}finally{k.value=!1}};ce([b,y],()=>{p.value=1,h()});const V=Ce(()=>{p.value=1,h()},500),N=()=>{p.value*f.value<v.value&&(p.value++,h())},G=()=>{p.value>1&&(p.value--,h())},O=s=>{window.open(F(`/models/${s}`),"_blank")},T=s=>s==null?"-":ke(s,{currency:"$",freeLabel:i("site.model_pricing.price.free"),naLabel:"-"}),L=s=>{if(!s)return"";const o=i("common.units."+s);return o!=="common.units."+s?o:s},Y=s=>{const o=q(s),n=Me(o);return n==="per-second"?i("model_detail.pricing.per_second"):n==="per-image"?i("model_detail.pricing.per_image"):n==="per-video-second"?i("model_detail.pricing.per_video_second"):n==="per-video"?i("model_detail.pricing.per_video"):n==="per-1m-video-tokens"?i("model_detail.pricing.per_million_video_tokens"):L(s?.pricing?.unit)},Q=s=>{const n={[_.perToken]:"model_detail.pricing.modes.per_token",[_.perRequest]:"model_detail.pricing.modes.per_request",[_.perSecond]:"model_detail.pricing.modes.per_second",[_.imageBaseRatio]:"model_detail.pricing.modes.image_base_ratio",[_.imageFixed]:"model_detail.pricing.modes.image_fixed",[_.videoBaseRatio]:"model_detail.pricing.modes.video_base_ratio",[_.videoFixed]:"model_detail.pricing.modes.video_fixed",[_.videoTokenTier]:"model_detail.pricing.modes.video_token_tier"}[s];if(!n)return s;const x=i(n);return x===n?s:x},W=s=>T(Pe(s)),H=w(()=>(p.value-1)*f.value+1),K=w(()=>Math.min(p.value*f.value,v.value)),J=async s=>{try{await navigator.clipboard.writeText(s),C.value=s,setTimeout(()=>{C.value=null},2e3)}catch(o){console.error("Failed to copy:",o)}},X=s=>{const o=s;o.style.opacity="0",o.style.transform="translateY(-15px)"},Z=(s,o)=>{const n=s,x=parseInt(n.dataset.index||"0");setTimeout(()=>{n.style.transition="all 0.35s ease-out",n.style.opacity="1",n.style.transform="translateY(0)",setTimeout(o,350)},x*50)};return(s,o)=>{const n=pe,x=fe,ee=be,te=xe;return d(),r("section",{class:"py-24 bg-slate-50 overflow-hidden",ref_key:"sectionRef",ref:I},[e("div",Te,[e("div",{class:S(["mb-10 transition-all duration-700 transform text-center",{"opacity-100 translate-y-0":m.value,"opacity-0 translate-y-8":!m.value}])},[e("h2",Le,a(l(i)("site.model_pricing.title")),1),e("p",Se,a(l(i)("site.model_pricing.subtitle")),1)],2),e("div",{class:S(["flex flex-col md:flex-row justify-between items-center gap-4 mb-8 transition-all duration-700 delay-100 transform",{"opacity-100 translate-y-0":m.value,"opacity-0 translate-y-8":!m.value}])},[e("div",ze,[c(n,{name:"lucide:search",size:"16",class:"absolute left-3 top-1/2 transform -translate-y-1/2 text-slate-400"}),D(e("input",{type:"text",placeholder:l(i)("site.model_pricing.search_placeholder"),"onUpdate:modelValue":o[0]||(o[0]=t=>M.value=t),onInput:o[1]||(o[1]=(...t)=>l(V)&&l(V)(...t)),class:"w-full pl-10 pr-4 py-2.5 bg-white border border-slate-200 rounded-lg focus:outline-none focus:border-slate-400 focus:ring-1 focus:ring-slate-400 transition-all text-slate-700 placeholder-slate-400 shadow-sm"},null,40,Ie),[[ue,M.value]])]),e("div",je,[e("div",De,[D(e("select",{"onUpdate:modelValue":o[2]||(o[2]=t=>b.value=t),"aria-label":"provider",class:"appearance-none px-4 py-2.5 bg-white border border-slate-200 rounded-lg text-slate-600 text-sm font-medium hover:bg-slate-50 flex items-center gap-2 shadow-sm pr-8 focus:outline-none cursor-pointer"},[e("option",Ue,a(l(i)("site.model_pricing.all_providers")),1),(d(!0),r(g,null,U(A.value,t=>(d(),r("option",{key:t,value:t},a(t),9,$e))),128))],512),[[B,b.value]]),c(n,{name:"lucide:chevron-down",size:"12",class:"absolute right-3 top-1/2 transform -translate-y-1/2 text-slate-400 pointer-events-none"})]),e("div",Fe,[D(e("select",{"onUpdate:modelValue":o[3]||(o[3]=t=>y.value=t),"aria-label":"category",class:"appearance-none px-4 py-2.5 bg-white border border-slate-200 rounded-lg text-slate-600 text-sm font-medium hover:bg-slate-50 flex items-center gap-2 shadow-sm pr-8 focus:outline-none cursor-pointer"},[e("option",Re,a(l(i)("site.model_pricing.all_categories")),1),(d(!0),r(g,null,U(E.value,t=>(d(),r("option",{key:t,value:t},a(l(i)("common.categories."+t)!=="common.categories."+t?l(i)("common.categories."+t):t.charAt(0).toUpperCase()+t.slice(1)),9,Ve))),128))],512),[[B,y.value]]),c(n,{name:"lucide:chevron-down",size:"12",class:"absolute right-3 top-1/2 transform -translate-y-1/2 text-slate-400 pointer-events-none"})])])],2),c(te,null,{default:$(()=>[e("div",{class:S(["bg-white rounded-xl border border-slate-200 shadow-sm overflow-hidden transition-all duration-700 delay-200 transform min-h-[400px] relative",{"opacity-100 translate-y-0":m.value,"opacity-0 translate-y-8":!m.value}])},[c(_e,{name:"fade"},{default:$(()=>[k.value?(d(),r("div",Be,[c(n,{name:"lucide:loader-2",size:"24",class:"animate-spin text-slate-400"})])):z("",!0)]),_:1}),P.value.length===0&&!k.value?(d(),r("div",qe,[c(n,{name:"lucide:inbox",size:"32",class:"mb-2 text-slate-300"}),e("p",null,a(l(i)("site.model_pricing.no_models")),1)])):(d(),r("div",Ae,[e("table",Ee,[e("thead",null,[e("tr",Ne,[e("th",Ge,a(l(i)("site.model_pricing.table.model")),1),e("th",Oe,a(l(i)("site.model_pricing.table.input_price")),1),e("th",Ye,a(l(i)("site.model_pricing.table.output_price")),1),R.value?(d(),r("th",Qe,a(l(i)("model_detail.availability.title")),1)):z("",!0)])]),c(me,{name:"list",tag:"tbody",class:"divide-y divide-slate-100",onBeforeEnter:X,onEnter:Z,mode:"out-in"},{default:$(()=>
1[(d(!0),r(g,null,U(P.value,(t,se)=>(d(),r("tr",{key:t.id,"data-index":se,class:"hover:bg-slate-50/50 transition-colors group cursor-pointer list-row",onClick:oe=>O(`${t.id}`)},[e("td",He,[e("div",Ke,[e("div",Je,[e("div",Xe,[c(x,{name:`${t.provider}`.toLocaleLowerCase(),alt:t.provider,class:"w-full h-full object-contain"},null,8,["name","alt"])]),e("div",Ze,[e("div",et,a(t.display_name||t.name),1),e("div",tt,a(t.id),1)])]),c(n,{name:C.value===String(t.id)?"lucide:check":"lucide:copy",size:"14",class:S([C.value===String(t.id)?"text-green-500":"text-slate-500 hover:text-slate-600","p-2 transition-all cursor-pointer"]),onClick:ve(oe=>J(String(t.id)),["stop"])},null,8,["name","class","onClick"])])]),t.status===1?(d(),r("td",st,[e("span",ot,a(l(i)("model_detail.status.coming_soon")),1)])):t.status===2?(d(),r("td",at,[e("span",it,a(l(i)("model_detail.status.delisted")),1)])):l(he)(t)?(d(),r(g,{key:2},[e("td",lt,[e("div",null,a(W(t)),1),e("div",nt,a(Y(t)),1)]),e("td",rt,[e("div",dt,a(Q(l(q)(t))),1)])],64)):l(we)(t)?(d(),r(g,{key:3},[e("td",ct,[e("div",null,a(T(t?.pricing?.input_price||t?.input_price)),1),e("div",pt,a(L(t?.pricing?.unit)||l(i)("site.model_pricing.price.per_request")),1)]),o[5]||(o[5]=e("td",{class:"px-6 py-4 text-slate-400 font-mono text-sm"},[e("div",null,"-")],-1))],64)):(d(),r(g,{key:4},[e("td",ut,[e("div",null,a(T(t?.pricing?.input_price)),1),e("div",_t,a(L(t?.pricing?.unit)),1)]),e("td",mt,[e("div",null,a(T(t?.pricing?.output_price)),1),e("div",vt,a(L(t?.pricing?.unit)),1)])],64)),R.value?(d(),r("td",xt,[c(ye,{"model-id":t.id,"model-name":t.name,"model-status":t.status,"availability-hidden":!!t.availability_hidden,"show-title":!1},null,8,["model-id","model-name","model-status","availability-hidden"])])):z("",!0)],8,We))),128))]),_:1})])])),v.value>0?(d(),r("div",gt,[e("div",ft,a(l(i)("site.model_pricing.pagination.showing",{start:H.value,end:K.value,total:v.value})),1),e("div",bt,[e("button",{onClick:o[4]||(o[4]=t=>s.$router.push(l(F)("/models"))),class:"px-3 py-1.5 bg-white border border-slate-200 rounded text-slate-600 text-sm hover:bg-slate-50 disabled:opacity-50 disabled:cursor-not-allowed"},a(l(i)("site.model_pricing.pagination.more")),1),c(ee,{layout:"vertical"}),e("button",{onClick:G,disabled:p.value===1,class:"px-3 py-1.5 bg-white border border-slate-200 rounded text-slate-600 text-sm hover:bg-slate-50 disabled:opacity-50 disabled:cursor-not-allowed"},a(l(i)("site.model_pricing.pagination.previous")),9,yt),e("button",{onClick:N,disabled:p.value*f.value>=v.value,class:"px-3 py-1.5 bg-white border border-slate-200 rounded text-slate-600 text-sm hover:bg-slate-50 disabled:opacity-50 disabled:cursor-not-allowed"},a(l(i)("site.model_pricing.pagination.next")),9,ht)])])):z("",!0)],2)]),_:1})])],512)}}}),zt=Object.assign(ge(wt,[["__scopeId","data-v-8c8cd418"]]),{__name:"ModelPricingList"});export{zt as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.