import{a as e,n as t}from"./chunk-BneVvdWh.js";import{t as n}from"./react-C7IZe2D1.js";import{t as r}from"./jsx-runtime-C2wGStra.js";import{n as i,t as a}from"./render-icon-CUp_n6rD.js";import{o,r as s}from"./lib-8ue2PVWI.js";import{i as c,n as l,r as u,t as d}from"./TokyoUIStarFilled-DiQeedTx.js";var f,p,m,h,g=t((()=>{f=`rating__r-A71`,p=`ratingInput__fyzyf`,m=`stars__qShgt`,h={rating:f,"rating--size-small":`rating--size-small__wMRnt`,"rating--size-medium":`rating--size-medium__oVHgE`,"rating--size-large":`rating--size-large__sNU-A`,"rating--narrow-l--size-small":`rating--narrow-l--size-small__GL-Ad`,"rating--narrow-l--size-medium":`rating--narrow-l--size-medium__DaviF`,"rating--narrow-l--size-large":`rating--narrow-l--size-large__JfbP9`,"rating--medium-s--size-small":`rating--medium-s--size-small__s8Ddw`,"rating--medium-s--size-medium":`rating--medium-s--size-medium__USqaj`,"rating--medium-s--size-large":`rating--medium-s--size-large__T5Pq-`,"rating--medium-l--size-small":`rating--medium-l--size-small__Gf1HV`,"rating--medium-l--size-medium":`rating--medium-l--size-medium__FpwUM`,"rating--medium-l--size-large":`rating--medium-l--size-large__-0tSD`,"rating--wide-s--size-small":`rating--wide-s--size-small__lolFo`,"rating--wide-s--size-medium":`rating--wide-s--size-medium__815IL`,"rating--wide-s--size-large":`rating--wide-s--size-large__47sdo`,"rating--wide-l--size-small":`rating--wide-l--size-small__QL-Ls`,"rating--wide-l--size-medium":`rating--wide-l--size-medium__DnsTd`,"rating--wide-l--size-large":`rating--wide-l--size-large__mpRTc`,ratingInput:p,stars:m,"focus-style":`focus-style__cDthQ`}}));function _(e){return Math.round(e*2)/2}var v=t((()=>{}));function y(e){let{formatMessage:t}=o();return{ariaValueText:t({id:`preply-ds.rating.value-text`,defaultMessage:`{currentValue} out of {maxValue}`,description:`The current rating. Will be announced by screen readers as '4 out of 5'.`},{currentValue:e,maxValue:5})}}var b=t((()=>{s()}));function x({filledPerc:e}){return(0,w.jsxs)(`div`,{"data-filled":`true`,style:{width:`${e*100}%`},children:[i(d),i(d),i(d),i(d),i(d)]})}function S(){return(0,w.jsxs)(`div`,{"data-filled":`false`,children:[i(u),i(u),i(u),i(u),i(u)]})}function C({filledPerc:e}){return(0,w.jsxs)(`div`,{className:h.stars,"aria-hidden":`true`,children:[(0,w.jsx)(x,{filledPerc:e}),(0,w.jsx)(S,{})]})}var w,T=t((()=>{e(n(),1),c(),l(),g(),a(),w=r();try{C.displayName=`Stars`,C.__docgenInfo={description:``,displayName:`Stars`,props:{filledPerc:{defaultValue:null,description:`0-1 value`,name:`filledPerc`,required:!0,type:{name:`number`}}}}}catch{}}));export{v as a,g as c,y as i,T as n,_ as o,b as r,h as s,C as t};