<?php
$title =
'Homepage Release Notes';
?>

<div class="container-fluid py-4">

<div class="card border-0 shadow-lg rounded-4 mb-4">

<div class="card-body">

<h2 class="fw-bold">

<i class="fa fa-file-lines text-primary"></i>

Homepage Release Notes Center

</h2>

<div class="text-muted">

Track homepage evolution and publishing history.

</div>

</div>

</div>

<?php if(empty($notes)): ?>

<div class="alert alert-info rounded-4">

No release notes found.

</div>

<?php else: ?>

<?php foreach($notes as $n): ?>

<div class="card border-0 shadow-sm rounded-4 mb-4">

<div class="card-body">

<div class="d-flex justify-content-between">

<div>

<h4 class="fw-bold">

<?= htmlspecialchars(
$n['title']
)
?>

</h4>

<div class="text-muted">

Version
<?= (int)$n['version_no'] ?>

</div>

</div>

<div>

<span class="badge bg-primary">

<?= htmlspecialchars(
$n['new_status']
)
?>

</span>

</div>

</div>

<hr>

<div style="white-space:pre-wrap">

<?= htmlspecialchars(
$n['release_notes']
)
?>

</div>

<hr>

<div class="small text-muted">

Old Status:
<?= htmlspecialchars(
$n['old_status']
?? '-'
)
?>

|

New Status:
<?= htmlspecialchars(
$n['new_status']
?? '-'
)
?>

|

Created:
<?= htmlspecialchars(
$n['created_at']
)
?>

</div>

</div>

</div>

<?php endforeach; ?>

<?php endif; ?>

</div>
