price_product_tile_regular_small¶
The price_product_tile_regular_small
macro is used to render a single price on a product tile. Internally it's just a price_base macro with additional styling.
Definition¶
Input parameters¶
price¶
string
represents a price to render.
label¶
string
if set, an additional price label will be displayed.
Example¶
In this example we render a price with a label.
{% from "@macros/price_product_tile_regular_small.twig" import price_product_tile_regular_small %}
{{ price_product_tile_regular_small('$12.34', 'Price:') }}
Macro source code¶
{% macro price_product_tile_regular_small(price, label = '') %}
{% from "@macros/price_base.twig" import price_base %}
{{
price_base(price, label, {
price: 'price_xs',
priceValue: 'price__value_bold'
})
}}
{% endmacro %}