[Backlog] In-world calendar for timeline events #126
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context / Motivation
Research/product brief — explicitly gated on real user pull; do not build speculatively. Wiki entries already carry structured timeline items:
LoreEntry.timeline_eventsis a JSONB array (webapp/backend/app/models/lore_entry.py:225, mirrored inlore_entry_version.py:39), with input shapeLoreTimelineEventInput(routers/campaigns.py:205) validated by_normalise_timeline_events(campaigns.py:560) — each event can link to a lore entry, session, or milestone in the campaign. What they lack is when in the world something happened (Harptos "15 Mirtul, 1492 DR" style). Prior art: World Anvil calendars, Fantasy-Calendar.com.Spec (starting sketch)
Calendar definition — per campaign, one optional
WorldCalendar:campaign_id,name(e.g. "Calendar of Harptos"),months(JSONB list of{name, days}),weekday_names(JSONB list),year_epoch_label(e.g. "DR"),current_world_date(optional "today" marker). No leap rules initially — state this limitation in the settings UI.In-world dates on timeline events — extend the
timeline_eventsitem shape (JSONB, so no migration for the items themselves) with an optionalworld_dateobject{year, month_index, day}validated against the campaign's calendar in_normalise_timeline_events. Rendered per the calendar definition ("15 Mirtul, 1492 DR").Campaign timeline view — a campaign page collecting all timeline events (across lore entries + milestones) that have
world_date, sorted by in-world date (year → month index → day); events without world dates fall back to the existing ordering.Out of scope
Open questions
Acceptance criteria (for when this is pulled)
References
webapp/backend/app/models/lore_entry.py:225(timeline_eventsJSONB),models/lore_entry_version.py:39webapp/backend/app/routers/campaigns.py:205(LoreTimelineEventInput),:560(_normalise_timeline_events, cross-linking rules at:597-629)Filed from the July 2026 full-project review.
The wiki design record #593 covers most of this issue (owner decision, 2026-09-10). The owner tracks in-world time "very loosely", so the agreed design has in-world dates without a calendar definition:
world_date {label, sort}: the date as the setting writes it ("3 Rainmonth, 812"), plus a hidden number that keeps the order correct. Year-only and approximate dates sort correctly.What remains here is the optional full calendar: months, weekdays, and dates drawn from a calendar definition. The owner doesn't need it, but another group on a hosted instance might. Keep this issue for that, still waiting on real demand as it already says. If it's ever built, the
labelabove can be generated from the calendar andsortcomputed from it, so nothing recorded earlier has to change.