<div class="changelog_container">
    <?php
    $travel_tourist_changelog_entries = travel_tourist_get_changelog_from_readme();
    if (!empty($travel_tourist_changelog_entries)) :
        foreach ($travel_tourist_changelog_entries as $travel_tourist_entry) :
            $travel_tourist_version = esc_html($travel_tourist_entry[1]);
            $travel_tourist_date = esc_html($travel_tourist_entry[2]);
            $travel_tourist_details = explode("\n", trim($travel_tourist_entry[3]));
            ?>
            <div class="changelog_element">
                <span class="theme_version">
                    <strong><?php echo 'v' . $travel_tourist_version; ?></strong>
                    <?php echo 'Release date: ' . $travel_tourist_date; ?>
                    <span class="dashicons dashicons-arrow-down-alt2"></span>
                </span>

                <div class="changelog_details" style="display: none;">
                    <ul>
                        <?php foreach ($travel_tourist_details as $travel_tourist_detail) : ?>
                            <li><?php echo esc_html(trim($travel_tourist_detail, "- \t")); ?></li>
                        <?php endforeach; ?>
                    </ul>
                </div>
            </div>
        <?php
        endforeach;
    else :
        ?>
        <p><?php esc_html_e('No changelog available.', 'travel-tourist'); ?></p>
    <?php endif; ?>
</div>