Skip to content

Migrate to Tailwind CSS and redesign with sport type fixes#45

Merged
gerfru merged 1 commit into
mainfrom
feat/gui-upgrade-tailwind
May 15, 2026
Merged

Migrate to Tailwind CSS and redesign with sport type fixes#45
gerfru merged 1 commit into
mainfrom
feat/gui-upgrade-tailwind

Conversation

@gerfru

@gerfru gerfru commented May 15, 2026

Copy link
Copy Markdown
Owner

Summary

  • Migrate all 10 Jinja2 templates from monolithic style.css (1062 lines) to Tailwind CSS utility
    classes; style.css reduced to ~420 lines (JS-generated classes only, cannot be inlined)
  • Add class-based light/dark theme with FOUC-free toggle in Settings page; theme persisted in
    localStorage via theme-init.js (runs before Tailwind CDN) and theme.js
  • Fix light mode text contrast across dashboard header, activity detail, and metrics detail
    (hardcoded text-slate-100/bg-white/[0.08] replaced with proper dark: variants)
  • Replace indigo accent with Slate + Emerald color scheme across all templates
  • Fix Garmin sport type resolution: read subActivityType.typeKey before activityType.typeKey
    so activities like Krafttraining, Yoga, Indoor Cycling no longer show as "Other"
  • Add German display labels for all sport types in dashboard.js and activity.js
  • Fix activity upsert to also update sport_type on existing records (previously only
    aerobic_effect/anaerobic_effect were updated on conflict)

Test plan

  • Dashboard renders in dark and light mode, all charts visible
  • Settings toggle switches between dark/light, persists after page reload
  • Activity detail page: title, back link, and meta text readable in both modes
  • Metrics detail page: title and value readable in both modes
  • After sync: activities show "🏋️ Krafttraining" / "🧘 Yoga" instead of "⚡ Other"
  • Login, Register, Garmin/Libre link pages use emerald accent buttons
  • make build-api + make build-sync succeed without errors

Migrate all 10 templates to Tailwind CSS utility classes, replacing
the monolithic style.css (1062 → ~420 lines, JS-generated classes only).
Add class-based light/dark theme with FOUC-free toggle in Settings.
Expand Garmin sport type resolution to use subActivityType.typeKey so
activities like Krafttraining, Yoga, Indoor Cycling no longer show as
Other; upsert now updates sport_type on existing records.
@gerfru gerfru merged commit d51ed05 into main May 15, 2026
5 checks passed
@gerfru gerfru deleted the feat/gui-upgrade-tailwind branch June 12, 2026 21:54
gerfru added a commit that referenced this pull request Jun 12, 2026
#45)

Migrate all 10 templates to Tailwind CSS utility classes, replacing
the monolithic style.css (1062 → ~420 lines, JS-generated classes only).
Add class-based light/dark theme with FOUC-free toggle in Settings.
Expand Garmin sport type resolution to use subActivityType.typeKey so
activities like Krafttraining, Yoga, Indoor Cycling no longer show as
Other; upsert now updates sport_type on existing records.

Co-authored-by: Gerald F. Fruhmann <gerfru@Geralds-Mac-mini.local>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant