<?xml version="1.0"?>
<t name="Rating: static star widget" t-name="portal_rating.rating_widget_stars_static">
        <t t-set="rating_avg" t-value="round(rating_avg * 100) / 100"/>
        <t t-set="val_decimal" t-value="round(rating_avg % 1, 1)"/>
        <t t-set="val_integer" t-value="int(rating_avg)"/>
        <t t-set="empty_star" t-value="5 - (val_integer+1) if val_decimal else 5 - val_integer"/>
        <div class="o_website_rating_static" t-att-style="inline_mode and 'display:inline'" t-att-title="rating_avg">
            <t t-if="rating_style_compressed">
                <t t-if="rating_avg &lt;= 2">
                    <i class="fa fa-star-o" role="img"/>
                </t>
                <t t-elif="rating_avg &gt;= 2.1 and rating_avg &lt;= 3.5">
                    <i class="fa fa-star-half-o" role="img"/>
                </t>
                <t t-else="">
                    <i class="fa fa-star" role="img"/>
                </t>
                <small class="text-muted ms-1">
                    <t t-esc="rating_avg"/>
                </small>
            </t>
            <t t-else="">
                <t t-foreach="range(0, val_integer)" t-as="num">
                    <i class="fa fa-star" role="img"/>
                </t>
                <t t-if="val_decimal">
                    <i class="fa fa-star-half-o" role="img"/>
                </t>
                <t t-foreach="range(0, empty_star)" t-as="num">
                    <i class="fa fa-star-o" role="img"/>
                </t>
                <small class="text-muted ms-1">
                    (<t t-esc="rating_count"/>)
                </small>
            </t>
        </div>
    </t>

    