## Changes - Add `theme` (refined | modern | bold | editorial, default "refined") and `themeMode` (auto | light | dark, default "auto") fields to the StatusPage Mongoose model and the shared `StatusPage` type. - Extend the create/update Zod validator to accept both fields optionally. - Map both fields in the repository's `toEntity` so GET responses include them. - Document both fields in the create and update endpoints in `openapi.json`. - Add `STATUS_PAGE_THEMES_ENABLED` env var (default `true`) wired through `SettingsService` for ops-level rollback. When disabled, the controller strips theme fields on write and forces defaults on read. ## Notes - No migration needed; Mongoose applies defaults for legacy documents. - Controller short-circuits to zero-cost when the feature flag is on. - `DEFAULT_STATUS_PAGE_THEME` / `DEFAULT_STATUS_PAGE_THEME_MODE` constants exported so the frontend PR can consume the same values.
33 lines
785 B
Bash
33 lines
785 B
Bash
# ==============================================
|
|
# Checkmate Server Configuration
|
|
# ==============================================
|
|
# Copy this file to .env and fill in your values
|
|
|
|
# Server Configuration
|
|
# --------------------
|
|
NODE_ENV=development
|
|
LOG_LEVEL=debug
|
|
|
|
# Database
|
|
# --------
|
|
DB_CONNECTION_STRING=mongodb://localhost:27017/uptime_db
|
|
|
|
# JWT Authentication
|
|
# ------------------
|
|
JWT_SECRET=my_secret
|
|
TOKEN_TTL=99d
|
|
|
|
# Client Configuration
|
|
# --------------------
|
|
CLIENT_HOST=http://localhost:5173
|
|
|
|
# Optional Configuration
|
|
# ----------------------
|
|
ORIGIN=localhost
|
|
|
|
# Feature Flags
|
|
# -------------
|
|
# Set to "false" to disable the selectable theme feature on status pages.
|
|
# When disabled, all status pages render with the default "refined" theme.
|
|
STATUS_PAGE_THEMES_ENABLED=true
|