1import{r as e}from"./rolldown-runtime-C60lm6uB.js";import{i as t,r as n}from"./framework-BaE7mD_r.js";var r=e(n(),1),i=t();function a(){let[e,t]=(0,r.useState)(null),[n,a]=(0,r.useState)(!1);(0,r.useEffect)(()=>{let e=!0;return(async()=>{try{let n=await fetch(`/api/review-stats`);if(!n.ok)throw Error(`Review rating is unavailable`);let r=await n.json();e&&Number.isFinite(r.rating)&&Number.isInteger(r.reviewCount)&&(t(r),a(!1))}catch{e&&a(!0)}})(),()=>{e=!1}},[]);let o=e?`${e.rating.toFixed(2)} out of 5 stars`:`Marinas.com rating`;return(0,i.jsxs)(`div`,{className:`review-proof-score`,"aria-live":`polite`,children:[(0,i.jsx)(`strong`,{children:e?e.rating.toFixed(2):`â`}),(0,i.jsx)(`span`,{"aria-label":o,children:`â
â
â
â
â
`}),(0,i.jsx)(`p`,{children:e?`${e.reviewCount.toLocaleString()} Marinas.com reviews`:`Marinas.com reviews`}),(0,i.jsx)(`small`,{children:e?`Live rating · refreshed automatically`:n?`Current rating temporarily unavailable`:`Loading current ratingâ¦`})]})}export{a as ReviewStats};
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.