yera.ui.fastapi_routes.sidebar
Serve contextual sidebar fragments for HTMX navigation.
Symbols
register_sidebar_routes
register_sidebar_routes(
app: FastAPI,
apps: Mapping[str, AppReference],
session_store: BaseSessionStore,
) → NoneRegister HTMX fragment routes for app, live, and session sidebars.
App and session detail routes return 404 when their selected resource does
not exist. The Live fragment groups running and waiting sessions, and emits
an HX-Trigger-After-Swap event containing the current live-session
count so the shell can update its navigation state.
Parameters
app
type: FastAPI
FastAPI application receiving the routes.
apps
type: Mapping[str, AppReference]
Available applications keyed by stable identifier.
session_store
type: BaseSessionStore
Store used to classify and retrieve persisted sessions.