<?php
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
global $tami_pages; ?>
<?php

use Tami\WooCommerce\TamiAdmin;

$menu_output = '';
foreach ( TamiAdmin::get_pages() as $key => $page ) {
	$menu_output .= sprintf(
		'<li class="tami-nav-item" role="presentation"><button class="tami-nav-link %stami-rounded-5" data-tamitarget="%s" id="tami-%s-tab-button" data-tamibs-toggle="tamitab" type="button" role="tab" aria-selected="true">%s&nbsp;%s</button></li>',
		( $key === 0 ? 'tami-active ' : '' ),
		$page->slug,
		( $page->slug ?? $key ), $page->icon, $page->label
	);
}
$menu_allowed_tags = [
	'li'     => [
		'class' => [],
		'role'  => []
	],
	'button' => [
		'class'              => [],
		'data-tamitarget'    => [],
		'id'                 => [],
		'data-tamibs-toggle' => [],
		'type'               => [],
		'role'               => [],
		'aria-selected'      => []
	],
	'i'      => [
		'class' => []
	]
];
?>
<?php do_action( 'tami_woocommerce/before_panel' ); ?>
<div class="tami-all tami-mb-0 tami-border tami-border-tami tami-rounded-5 tami-overflow-hidden tami-page-loading"
     style="border-width: 2px !important;">
    <div class="tami-page-loading-spinner tami-bg-tami-grey tami-align-items-center tami-rounded-4">
        <div class="tami-spinner-border tami-text-tami tami-m-auto"></div>
    </div>
    <div class="tami-bg-white tami-rounded-4 tami-m-auto" style="max-width:auto">
        <div class="
         tami-rounded-0 tami-border-0 tami-outer-div">
            <div class="tami-p-0 tami-green-wave-bg">
				<?php do_action( 'tami_woocommerce/before_header' ); ?>
                <div class="tami-card-header tami-bg-tami-green tami-p-3">
                    <table class="tami-table-borderless" width="100%">
                        <tbody>
                        <tr>
                            <td class="tami-text-center">
                                <div class="tami-px-3">
                                    <span
                                            style="display: block;float: left;margin-top: -6.5px;"
                                    >
                                        <?php echo TamiAdmin::get_assets('images/tami-full.png', 'html', [
                                                'class' => 'tami-logo test',

                                            'style' => 'width:125px; height:auto;'
                                        ]) ?>
                                    </span>
                                </div>
                            </td>
                            <td class="tami-text-center tami-py-0 tami-py-lg-2 tami-d-none tami-d-lg-table-cell">
                                <ul class="tami-nav tami-nav-pills tami-nav-fill tami-gap-2 tami-p-1 tami-h4 tami-ms-0 tami-ms-lg-5"
                                    id="pillNav2">
	                                <?php echo wp_kses( $menu_output, $menu_allowed_tags ); ?>
                                </ul>
                            </td>
                        </tr>
                        <tr class="tami-d-table-row tami-d-lg-none tami-text-center">
                            <td>
                                <ul class="tami-nav tami-nav-pills tami-nav-fill tami-gap-2 tami-p-1 tami-h4"
                                    id="pillNav2">
									<?php echo wp_kses( $menu_output, $menu_allowed_tags ); ?>
                                </ul>
                            </td>
                        </tr>
                        </tbody>
                    </table>
                </div>
				<?php do_action( 'tami_woocommerce/after_header' ); ?>
                <div class="tami-card-body tami-card-minheight">
