1(function(root){'use strict';function renderIconMarkup(icon){if(!icon)return'';icon=icon.trim();const isImage=icon!==''&&/^(https?:\/\/|\/\/|\/)/.test(icon);if(isImage){return `<img src="${icon}" alt="" class="yayrev-rating-icon-image" />`} 2return icon} 3function render(rating,ratingType){const parts=[];const append=(html)=>parts.push(html);if(rating&&ratingType){const displayLevel=ratingType.displayLevel||rating;const levels=ratingType.levels||5;const displayMode=ratingType.displayMode||'progressive';const icons=ratingType.icons||{};const labels=ratingType.labels||{};if(displayMode==='single'){const icon=icons[displayLevel]||'â';const label=labels[displayLevel]||'';const iconMarkup=renderIconMarkup(icon);if(ratingType.type==='emoji'){append(` 4 <span class="yayrev-rating-icon yayrev-rating-icon--filled" title="${label}"> 5 ${iconMarkup} 6 </span> 7 `)}else if(ratingType.type==='lucide'){append(` 8 <span class="yayrev-rating-icon yayrev-rating-icon--filled yayrev-rating-icon--lucide" data-icon="${icon}" title="${label}"> 9 ${iconMarkup} 10 </span> 11 `)}else{append(` 12 <svg class="yayrev-star filled" width="18" height="18" viewBox="0 0 24 24" fill="currentColor" stroke="currentColor" stroke-width="2"> 13 <polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/> 14 </svg> 15 `)}}else{for(let level=1;level<=levels;level++){const isFilled=level<=displayLevel;const icon=icons[level]||'â';const label=labels[level]||'';const className=isFilled?'filled':'empty';const iconMarkup=renderIconMarkup(icon);if(ratingType.type==='emoji'){append(` 16 <span class="yayrev-rating-icon yayrev-rating-icon--${className}" title="${label}"> 17 ${iconMarkup} 18 </span> 19 `)}else if(ratingType.type==='lucide'){append(` 20 <span class="yayrev-rating-icon yayrev-rating-icon--${className} yayrev-rating-icon--lucide" data-icon="${icon}" title="${label}"> 21 ${iconMarkup} 22 </span> 23 `)}else{const fill=isFilled?'currentColor':'none';append(` 24 <svg class="yayrev-star ${className}" width="18" height="18" viewBox="0 0 24 24" fill="${fill}" stroke="currentColor" stroke-width="2"> 25 <polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/> 26 </svg> 27 `)}}} 28if(ratingType.showLabel&&labels[displayLevel]){append(` 29 <span class="yayrev-rating-label">${labels[displayLevel]}</span> 30 `)}}else if(rating){for(let i=1;i<=5;i++){const starClass=i<=rating?'filled':'empty';append(` 31 <svg class="yayrev-star ${starClass}" width="18" height="18" viewBox="0 0 24 24" fill="${i <= rating ? 'currentColor' : 'none'}" stroke="currentColor" stroke-width="2"> 32 <polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/> 33 </svg> 34 `)}} 35return parts.join('')} 36root.YayRevRatingRender={render:render}})(typeof window!=='undefined'?window:globalThis)
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.