{% sw_extends "@Storefront/storefront/page/product-detail/buy-widget-price.html.twig" %}
{% block page_product_detail_price_content %}
{% set listPrice = price.listPrice %}
{% set isRegulationPrice = price.regulationPrice != null %}
<div class="d-flex flex-wrap" style="align-items: flex-end;">
<p class="product-detail-price{% if listPrice.percentage > 0 %} with-list-price{% endif %}" data-price="{{ price.unitPrice }}">
<span>{{ price.unitPrice|currency }}</span>{{ "general.star"|trans|sw_sanitize }}
</p>
{% if listPrice.percentage > 0 %}
{% block page_product_detail_was_price %}
{% block page_product_detail_was_price_badge %}
<span class="list-price-badge">%</span>
{% endblock %}
{% set afterListPriceSnippetExists = "listing.afterListPrice"|trans|length > 0 %}
{% set beforeListPriceSnippetExists = "listing.beforeListPrice"|trans|length > 0 %}
{% block page_product_detail_was_price_wrapper %}
<span class="product-detail-list-price-wrapper">
{% if beforeListPriceSnippetExists %}{{"listing.beforeListPrice"|trans|trim}}{% endif %}
<span{% if not (afterListPriceSnippetExists or beforeListPriceSnippetExists) %} class="list-price-price"{% endif %}>{{ listPrice.price|currency }}{{ "general.star"|trans|sw_sanitize }}</span>
{% if afterListPriceSnippetExists %}
{{"listing.afterListPrice"|trans|trim}}
{% endif %}
<span class="list-price-percentage">{{ "detail.listPricePercentage"|trans({'%price%': listPrice.percentage })|sw_sanitize }}</span>
</span>
{% endblock %}
{% endblock %}
{% endif %}
{% if isRegulationPrice %}
<div class="product-detail-list-price-wrapper">
<span class="regulation-price"> {{ "general.listPricePreviously"|trans({'%price%': price.regulationPrice.price|currency }) }}{{ "general.star"|trans|sw_sanitize }}</span>
</div>
{% endif %}
</div>
<div class="hueb-price">
</div>
{% endblock %}