1import{t as p,aP as v,an as d,a5 as s,m as n,i as a,F as w,ad as k,X as i,Z as b,al as z,l as m,g as r}from"./DobV_ULG.js";const y=["aria-label"],B={class:"flex items-center","aria-hidden":"true"},M=p({__name:"ProductRating",props:{rating:{default:0},count:{default:0},size:{default:"sm"},hideCount:{type:Boolean,default:!1}},setup(t){const l=t,{t:g}=v(),h=r(()=>l.count>0&&l.rating>0),o=r(()=>Math.min(5,Math.max(0,l.rating)));function f(c){return`${Math.min(1,Math.max(0,o.value-(c-1)))*100}%`}const x=r(()=>g("catalogue.rating_aria","Noté {rating} sur 5, {count} avis",{rating:String(o.value).replace(".",","),count:l.count}));return(c,e)=>d(h)?(s(),n("div",{key:0,class:"flex items-center gap-1",role:"img","aria-label":d(x)},[a("div",B,[(s(),n(w,null,k(5,u=>a("span",{key:u,class:i(["relative inline-block shrink-0",t.size==="md"?"h-4 w-4":"h-3.5 w-3.5"])},[e[1]||(e[1]=a("svg",{class:"absolute inset-0 h-full w-full fill-current text-slate-200 dark:text-slate-700",viewBox:"0 0 20 20"},[a("path",{d:"M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z"})],-1)),a("span",{class:"absolute inset-0 overflow-hidden",style:b({width:f(u)})},[(s(),n("svg",{class:i(["h-full w-full fill-current text-rating-star",t.size==="md"?"w-4":"w-3.5"]),viewBox:"0 0 20 20"},[...e[0]||(e[0]=[a("path",{d:"M9.049 2.927c.3-.921 1.603-.921 1.902 0l1.07 3.292a1 1 0 00.95.69h3.462c.969 0 1.371 1.24.588 1.81l-2.8 2.034a1 1 0 00-.364 1.118l1.07 3.292c.3.921-.755 1.688-1.54 1.118l-2.8-2.034a1 1 0 00-1.175 0l-2.8 2.034c-.784.57-1.838-.197-1.539-1.118l1.07-3.292a1 1 0 00-.364-1.118L2.98 8.72c-.783-.57-.38-1.81.588-1.81h3.461a1 1 0 00.951-.69l1.07-3.292z"},null,-1)])],2))],4)],2)),64))]),t.hideCount?m("",!0):(s(),n("span",{key:0,class:i(["text-slate-500 dark:text-slate-400",t.size==="md"?"text-xs":"text-[10px]"]),"aria-hidden":"true"},"("+z(t.count)+")",3))],8,y)):m("",!0)}}),_=Object.assign(M,{__name:"ProductRating"});export{_};
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.