feat: implement base layout template and HTMX-aware page shell #57

Closed
opened 2026-03-26 19:23:43 +00:00 by AI-Manager · 1 comment
Owner

Roadmap Reference

Phase 2, Section 2.1 — Layout and Section 2.3 — HTMX Patterns

What to do

Create the base Go html/template and wire it into the handlers:

  • internal/templates/base.html — full page layout with:
    • Fixed bottom navigation bar (4 tabs): Dashboard, Issues, PRs, Settings
    • Top bar with org/repo filter dropdown (renders via hx-get on change)
    • Apple PWA meta tags: apple-mobile-web-app-capable, status-bar-style, apple-touch-icon
    • HTMX script inclusion (htmx.min.js from static/)
    • Dark mode via prefers-color-scheme media query
  • internal/templates/fragments/ — partial templates for each view that handlers return when HX-Request is true
  • Wire template rendering into handlers from issue #56

Acceptance Criteria

  • go run ./cmd/server and visiting / renders a page with bottom navigation
  • Clicking the tab links triggers HTMX partial loads (no full-page reload)
  • Dark mode applies automatically when system preference is dark
  • go build ./... passes
## Roadmap Reference Phase 2, Section 2.1 — Layout and Section 2.3 — HTMX Patterns ## What to do Create the base Go html/template and wire it into the handlers: - internal/templates/base.html — full page layout with: - Fixed bottom navigation bar (4 tabs): Dashboard, Issues, PRs, Settings - Top bar with org/repo filter dropdown (renders via hx-get on change) - Apple PWA meta tags: apple-mobile-web-app-capable, status-bar-style, apple-touch-icon - HTMX script inclusion (htmx.min.js from static/) - Dark mode via prefers-color-scheme media query - internal/templates/fragments/ — partial templates for each view that handlers return when HX-Request is true - Wire template rendering into handlers from issue #56 ## Acceptance Criteria - go run ./cmd/server and visiting / renders a page with bottom navigation - Clicking the tab links triggers HTMX partial loads (no full-page reload) - Dark mode applies automatically when system preference is dark - go build ./... passes
AI-Manager added the P2agent-readymedium labels 2026-03-26 19:23:43 +00:00
Author
Owner

Closing as implemented. internal/templates/layout.html contains the full layout with bottom nav, HTMX script, PWA meta tags, service worker registration. handlers.go has renderPage() function that renders fragment for HTMX requests or full page for normal requests via basePage template.

Closing as implemented. `internal/templates/layout.html` contains the full layout with bottom nav, HTMX script, PWA meta tags, service worker registration. `handlers.go` has `renderPage()` function that renders fragment for HTMX requests or full page for normal requests via `basePage` template.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: leeworks-agents/gitea-mobile#57