mirror of
https://github.com/Mezeporta/Erupe.git
synced 2026-03-22 07:32:32 +01:00
feat(api): add configurable landing page at /
Allow server operators to show new players how to install the game client when they visit the server address in a browser. The page content (title and HTML body) is fully configurable via config.json and can be toggled on/off. Uses Go embed for a self-contained dark- themed HTML template with zero new dependencies.
This commit is contained in:
@@ -254,6 +254,14 @@ type API struct {
|
||||
Banners []APISignBanner
|
||||
Messages []APISignMessage
|
||||
Links []APISignLink
|
||||
LandingPage LandingPage
|
||||
}
|
||||
|
||||
// LandingPage holds config for the browser-facing landing page at /.
|
||||
type LandingPage struct {
|
||||
Enabled bool // Toggle the landing page on/off
|
||||
Title string // Page title (e.g. "My Frontier Server")
|
||||
Content string // Body content — supports raw HTML
|
||||
}
|
||||
|
||||
type APISignBanner struct {
|
||||
|
||||
Reference in New Issue
Block a user