<?php

/**
 * Duplicator Backup row in table Backups list
 */

use Duplicator\Views\KsesHelper;

defined("ABSPATH") or die("");

/**
 * Variables
 *
 * @var \Duplicator\Core\Controllers\ControllersManager $ctrlMng
 * @var \Duplicator\Core\Views\TplMng $tplMng
 */

$entries = [
    [
        'icon'  => '<i class="fa-solid fa-hard-drive"></i>',
        'label' => __('The Backup is in a Local Storage <b>[clickable]</b>', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-cloud"></i>',
        'label' => __('The Backup is in a Remote Storage <b>[clickable]</b>', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-square-check"></i>',
        'label' => __('Full Backup', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-database"></i>',
        'label' => __('Database Only Backup', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-images"></i>',
        'label' => __('Media Only Backup', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-puzzle-piece"></i>',
        'label' => __('Custom Components Backup', 'duplicator-pro'),
    ],
    [
        'icon'  => '<i class="fa-solid fa-clock-rotate-left maroon"></i>',
        'label' => __('This Backup is created after the Last Restored Backup', 'duplicator-pro'),
    ],
];

/**
 * @param array<int, array{icon: string, label: string}> $entries
 */
$entries = apply_filters('duplicator_package_flags_legend', $entries);
?>
<ul class="dup-status-icons-list no-bullet" >
    <?php foreach ($entries as $entry) { ?>
        <li>
            <span class="icon-wrapper">
                <?php echo wp_kses($entry['icon'], KsesHelper::ICON_TAGS); ?>
            </span>
            <?php echo wp_kses($entry['label'], KsesHelper::GEN_TAGS); ?>
        </li>
    <?php } ?>
</ul>
