<div class="changelog_container">
    <?php
    $massage_wellness_retreat_changelog_entries = massage_wellness_retreat_get_changelog_from_readme();
    if (!empty($massage_wellness_retreat_changelog_entries)) :
        foreach ($massage_wellness_retreat_changelog_entries as $massage_wellness_retreat_entry) :
            $massage_wellness_retreat_version = esc_html($massage_wellness_retreat_entry[1]);
            $massage_wellness_retreat_date = esc_html($massage_wellness_retreat_entry[2]);
            $massage_wellness_retreat_details = explode("\n", trim($massage_wellness_retreat_entry[3]));
            ?>
            <div class="changelog_element">
                <span class="theme_version">
                    <strong><?php echo 'v' . $massage_wellness_retreat_version; ?></strong>
                    <?php echo 'Release date: ' . $massage_wellness_retreat_date; ?>
                    <span class="dashicons dashicons-arrow-down-alt2"></span>
                </span>

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