feat: Add version number to homepage footer

- Create version.ts in lib folder with APP_VERSION constant
- Add version footer to HomePage
- Add CSS styling for version footer
- Starting version: 0.8.0
This commit is contained in:
2026-03-17 17:43:18 +01:00
parent fdac954cea
commit 3c0335ae7c
3 changed files with 33 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
/**
* Application Version
*
* Semantic Versioning: MAJOR.MINOR.PATCH
* - MAJOR: Incompatible API changes
* - MINOR: New functionality (backward compatible)
* - PATCH: Bug fixes (backward compatible)
*/
export const APP_VERSION = "0.8.0";
/**
* Build date - set at build time
*/
export const BUILD_DATE = new Date().toISOString().split('T')[0];

View File

@@ -1,6 +1,7 @@
import { FormEvent, useEffect, useState } from "react";
import { useNavigate } from "react-router-dom";
import { apiGet } from "../lib/api";
import { APP_VERSION } from "../lib/version";
import type { DashboardOverview, LookupResult } from "../lib/types";
function formatDate(value: string) {
@@ -174,6 +175,11 @@ export default function HomePage() {
<div className="empty-state">Noch keine Proben vorhanden.</div>
)}
</section>
{/* Version Footer */}
<footer className="version-footer">
<span>Version {APP_VERSION}</span>
</footer>
</div>
);
}

View File

@@ -1564,3 +1564,16 @@ a {
grid-template-columns: 1fr;
}
}
/* Version Footer */
.version-footer {
text-align: center;
padding: 24px 0;
color: var(--muted);
font-size: 0.85rem;
opacity: 0.7;
}
.version-footer span {
font-weight: 500;
}