trails/apps/journal
Ullrich Schäfer 3d3c56aaf4
profile-stats: lifetime roll-up header on the profile
Implements the profile-stats change (specs/profile-stats):

- getActivityStats(ownerId, { publicOnly }) in activities.server.ts: one indexed
  aggregate over stored columns (count, sum distance/ascent/elapsed duration) +
  a rolling last-4-weeks count. No cache table, no schema change, no GPX parsing
  (design §D1).
- Profile loader computes it scoped to the viewer (public-only for visitors,
  full totals for the owner); ProfileStats header renders count · distance ·
  ascent · time + "N in the last 4 weeks" via the shared StatRow + stats.ts
  formatters; hidden when there are no visible activities.
- i18n journal.profileStats.* in en + de.

Tests: ProfileStats component (jsdom: totals, empty, last-4-weeks toggle);
e2e asserts the owner roll-up counts their activities. typecheck + lint + unit
(journal 318) green; verified in the browser.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-13 07:25:06 +02:00
..
app profile-stats: lifetime roll-up header on the profile 2026-06-13 07:25:06 +02:00
public Add favicons, apple-touch-icons, and Chrome DevTools JSON 2026-03-29 10:35:03 +02:00
.env.example feat(journal): Garmin activity import — provider, webhook pipeline, backfill (§1–5) 2026-06-07 17:47:22 +02:00
Dockerfile remove the map and ui shim packages 2026-06-10 07:47:59 +02:00
package.json build(deps): Bump the production group across 1 directory with 21 updates 2026-06-11 19:22:35 +00:00
react-router.config.ts feat(journal): Fedify spike — WebFinger + actor objects behind FEDERATION_ENABLED 2026-06-06 14:15:27 +02:00
server.ts journal: typed job seam + Komoot credentials through the manager 2026-06-10 02:05:24 +02:00
tsconfig.json Fix planner production server + use .ts extensions everywhere 2026-03-25 01:41:33 +01:00
vite.config.ts Pre-warm Vite dep discovery for the journal dev server 2026-04-26 19:51:39 +02:00
vitest.config.ts Add mocked unit tests for REST API route handlers 2026-04-13 00:59:45 +02:00