updated history template
This commit is contained in:
@@ -6,11 +6,13 @@
|
|||||||
|
|
||||||
<p>For a machine-readable version history, see <a href="package-list.json">package-list.json</a>.</p>
|
<p>For a machine-readable version history, see <a href="package-list.json">package-list.json</a>.</p>
|
||||||
|
|
||||||
{% if site.data.package-list %}
|
<div id="version-history-loading">
|
||||||
|
<p><i>Loading version history...</i></p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="version-history-content" style="display:none;">
|
||||||
<p><b>Published Versions</b></p>
|
<p><b>Published Versions</b></p>
|
||||||
|
<table class="grid" id="versions-table">
|
||||||
<table class="grid">
|
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Version</th>
|
<th>Version</th>
|
||||||
@@ -19,30 +21,48 @@
|
|||||||
<th>Description</th>
|
<th>Description</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody id="versions-tbody">
|
||||||
{% for entry in site.data.package-list.list %}
|
|
||||||
{% if entry.version != 'current' %}
|
|
||||||
<tr>
|
|
||||||
<td><a href="{{ entry.path }}">{{ entry.version }}</a></td>
|
|
||||||
<td>{{ entry.date }}</td>
|
|
||||||
<td>{{ entry.status }}</td>
|
|
||||||
<td>{{ entry.desc }}</td>
|
|
||||||
</tr>
|
|
||||||
{% endif %}
|
|
||||||
{% endfor %}
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<p><b>Continuous Integration Build</b></p>
|
<p><b>Continuous Integration Build</b></p>
|
||||||
|
<div id="ci-build-info"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
{% for entry in site.data.package-list.list %}
|
<div id="version-history-error" style="display:none;">
|
||||||
{% if entry.version == 'current' %}
|
|
||||||
<p>The latest development build is available at: <a href="{{ entry.path }}">{{ entry.path }}</a></p>
|
|
||||||
<p><i>Note: This is a continuous integration build and may be unstable.</i></p>
|
|
||||||
{% endif %}
|
|
||||||
{% endfor %}
|
|
||||||
|
|
||||||
{% else %}
|
|
||||||
<p><i>Version history not available.</i></p>
|
<p><i>Version history not available.</i></p>
|
||||||
{% endif %}
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
fetch('package-list.json')
|
||||||
|
.then(response => response.json())
|
||||||
|
.then(data => {
|
||||||
|
const tbody = document.getElementById('versions-tbody');
|
||||||
|
const ciDiv = document.getElementById('ci-build-info');
|
||||||
|
|
||||||
|
// Add published versions
|
||||||
|
data.list.forEach(entry => {
|
||||||
|
if (entry.version !== 'current') {
|
||||||
|
const row = tbody.insertRow();
|
||||||
|
row.insertCell(0).innerHTML = '<a href="' + entry.path + '">' + entry.version + '</a>';
|
||||||
|
row.insertCell(1).textContent = entry.date || 'N/A';
|
||||||
|
row.insertCell(2).textContent = entry.status || 'unknown';
|
||||||
|
row.insertCell(3).textContent = entry.desc || '';
|
||||||
|
} else {
|
||||||
|
// CI build info
|
||||||
|
ciDiv.innerHTML = '<p>The latest development build is available at: <a href="' + entry.path + '">' + entry.path + '</a></p>' +
|
||||||
|
'<p><i>Note: This is a continuous integration build and may be unstable.</i></p>';
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// Show content, hide loading
|
||||||
|
document.getElementById('version-history-loading').style.display = 'none';
|
||||||
|
document.getElementById('version-history-content').style.display = 'block';
|
||||||
|
})
|
||||||
|
.catch(error => {
|
||||||
|
console.error('Error loading version history:', error);
|
||||||
|
document.getElementById('version-history-loading').style.display = 'none';
|
||||||
|
document.getElementById('version-history-error').style.display = 'block';
|
||||||
|
});
|
||||||
|
</script>
|
||||||
</div>
|
</div>
|
||||||
Reference in New Issue
Block a user