<?php
/**
 * Copyright © Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */

// phpcs:disable Magento2.Templates.ThisInTemplate

/** @var $block \Magento\Checkout\Block\Total\DefaultTotal */
?>
<tr class="totals">
    <th
            colspan="<?= $block->escapeHtmlAttr($block->getColspan()) ?>"
            style="<?= $block->escapeHtmlAttr($block->getTotal()->getStyle()) ?>"
            class="mark" scope="row"
    >
        <?php if ($block->getRenderingArea() == $block->getTotal()->getArea()) :?>
            <strong>
        <?php endif; ?>
        <?= $block->escapeHtml($block->getTotal()->getTitle()) ?>
        <?php if ($block->getRenderingArea() == $block->getTotal()->getArea()) :?>
            </strong>
        <?php endif; ?>
    </th>
    <td
            style="<?= $block->escapeHtmlAttr($block->getTotal()->getStyle()) ?>"
            class="amount"
            data-th="<?= $block->escapeHtmlAttr($block->getTotal()->getTitle()) ?>"
    >
        <?php if ($block->getRenderingArea() == $block->getTotal()->getArea()) :?>
            <strong>
        <?php endif; ?>
            <span>
                <?= $block->escapeHtml(
                    $this->helper(Magento\Checkout\Helper\Data::class)->formatPrice($block->getTotal()->getValue()),
                    ['span']
                ) ?>
            </span>
        <?php if ($block->getRenderingArea() == $block->getTotal()->getArea()) :?>
            </strong>
        <?php endif; ?>
    </td>
</tr>
