<?php
/**
 * Order of event card elements block.
 *
 * @package EventimUSEventListings
 */

defined( 'ABSPATH' ) || exit;
?>
<div class="dashboard-module">
	<div class="module-header">
		<h1><?php esc_html_e( 'Order Of Event Card Elements', 'eventim-us-event-listings' ); ?></h1>
		<h4><?php esc_html_e( 'Order will only be applied to list and grid view and will not be reflected on the calendar', 'eventim-us-event-listings' ); ?>
		</h4>
	</div>
	<div class="module-content">
		<ul class="event-card-elements-order">
			<?php
			foreach ( $cardLabelsOrder as $evusel_value ) :
				if ( ! isset( $cardLabelLabels[ $evusel_value ] ) ) {
					continue;
				}
				?>
				<li>
					<span class="dashicons dashicons-menu" style="opacity: 0.5;"></span>
					<?php echo esc_html( $cardLabelLabels[ $evusel_value ] ); ?>
					<input type="hidden" name="evusel_settings[event_card_elements_order][]"
						value="<?php echo esc_attr( $evusel_value ); ?>">
				</li>
			<?php endforeach; ?>
			<?php foreach ( $extraCardLabels as $evusel_value ) : ?>
				<li>
					<span class="dashicons dashicons-menu" style="opacity: 0.5;"></span>
					<?php echo esc_html( $cardLabelLabels[ $evusel_value ] ); ?>
					<input type="hidden" name="evusel_settings[event_card_elements_order][]"
						value="<?php echo esc_attr( $evusel_value ); ?>">
				</li>
			<?php endforeach; ?>
		</ul>
	</div>
</div>