{% from "/macros/profile/profile-details.html" import profileDetails %} {% from "/macros/profile/profile-cost.html" import profileAddonProductCost %} {% from "/macros/profile/profile-fee.html" import profileFee %} {% from "/macros/profile/configure/profile-added-button.html" import productAddButton %} {% macro configuratorAddonProductsContent(addonProducts, selectedEdition, i18n) %}

{{ i18n.selectAddons }}

{% for addonProduct in addonProducts.items %} {% for edition in addonProduct.edition %}

{{ addonProduct.name }}

    {% for plan in edition.plans %} {% if plan.costs and plan.costs.flatPrice %} {{ profileAddonProductCost(plan.costs.flatPrice, true) }} {% endif %} {% if plan.costs and plan.costs.unitPrice %} {% for unitPrice in plan.costs.unitPrice %} {% set unitPriceIndex = loop.index %} {% for usageRange in unitPrice.usageRange %} {{ profileAddonProductCost(usageRange, unitPriceIndex === 1 and not plan.costs.flatPrice) }} {% endfor %} {% endfor %} {% endif %} {% if plan.contractLength %}
  • {{ plan.formattedContract }}
  • {% endif %} {% if plan.setupFees.length or plan.contractFees.length %} {{ profileFee(plan.setupFees, plan.contractFees) }} {% endif %} {% if loop.index < edition.plans.length %}
  • {{ addonProducts.i18n.tierSeparator }}
  • {% endif %} {% endfor %}
{% set editionOptions = { isFullWidth: true } %} {{ productAddButton(edition.callToAction, addonProducts.i18n, edition.id, editionOptions) }} {{ addonProducts.i18n.remove }}
{% if edition.bullets.length %}
{{ profileDetails(edition.bullets) }} {% if edition.bullets.length > 7 %} {% endif %}
{% endif %}
{% endfor %} {% endfor %}
{% endmacro %}