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

// @codingStandardsIgnoreFile

?>
<?php
/** @var \Magento\Wishlist\Block\Customer\Wishlist\Items $block */
$columns = $block->getColumns();
?>
 
<div class="products-grid wishlist">
    <?php $iterator = 1; ?>
    <?php if (count($block->getItems())): ?>
    <ol class="product-items">
        <?php foreach ($block->getItems() as $item): ?>
        <?php /* @escapeNotVerified */ echo($iterator++ == 1) ? '<li data-row="product-item" class="product-item" id="item_' . $item->getId() . '">' : '</li><li class="product-item" id="item_' . $item->getId() . '">' ?>
            <div class="product-item-info">
                <?php foreach ($columns as $column): ?>
                    <?php $column->setItem($item); echo $column->toHtml($item);?>
                <?php endforeach; ?>
            </div>
        <?=($iterator == count($block->getItems())+1) ? '</li>' : '' ?>
        <?php endforeach; ?>
    </ol>
    <?php else: ?>
        <div class="message info empty">
            <span><?php /* @escapeNotVerified */ echo __('This Wish List has no Items');?></span>
        </div>
    <?php endif; ?>
</div>

<?php foreach ($columns as $column): ?>
    <?= $column->getAdditionalHtml();?>
<?php endforeach; ?>
