<?php

if (!defined('ABSPATH')) {
    exit; // Exit if accessed directly
}

if ($settings['style'] == 'style1')

    $container_style = 'tfl-uber-grid-container ' . tfl_get_grid_classes($settings);
else
    $container_style = 'tfl-container';

?>

<div class="tfl-galleries tfl-galleries-<?php echo $settings['style']; ?> <?php echo $container_style; ?>">

    <?php foreach ($settings['galleries'] as $index => $gallery): ?>

        <?php $args['index'] = $index; ?>

        <?php $args['gallery'] = $gallery; ?>

        <?php tfl_get_template_part("addons/gallery/{$settings['style']}", $args); ?>

    <?php endforeach; ?>

</div>

<div class="tfl-clear"></div>