Fix Vespers/Compline header to use evening day, not daytime day
Deploy / deploy (push) Successful in 1m19s
Deploy / deploy (push) Successful in 1m19s
day-nav.ts's header always resolved via resolveDay(date) regardless of selected hour, so viewing Vespers/Compline on a day whose evening anticipates tomorrow's First Vespers (e.g. Aug 25, 2026: St. Louis's day, but St. Zephyrinus claims First Vespers per calendar/vespers.ts) still showed today's saint in the header while the hour's actual content had already switched to tomorrow's. Now uses resolveEveningDay for those two hours specifically. Also adds an explicit "First Vespers (of tomorrow)" / "Second Vespers (of today)" status line to the Vespers header, via new getVespersStatusLabel(), so the anticipation/commemoration result is visible rather than only inferable from which saint's name shows up. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014axryJBrRswYh2niA7WCUc
This commit is contained in:
@@ -476,6 +476,22 @@ const TEMPORAL_CATEGORY_RANK_LABELS: Record<TemporalCategory, Bi> = {
|
||||
'privileged-feria-major': bi('Feria', 'Feria'),
|
||||
};
|
||||
|
||||
/**
|
||||
* Explicit "which Vespers is this" status, for the Vespers hour header —
|
||||
* distinct from `getDayLabel`'s name/rank/commemoration text, which is
|
||||
* silent about *why* a given identity governs tonight (a reader has to
|
||||
* already know, e.g., that St. Zephyrinus falls on tomorrow's date to
|
||||
* realize this evening is anticipating him). Pass the result of
|
||||
* `calendar/vespers.ts`'s `resolveEveningDay`, not a plain `resolveDay` —
|
||||
* only that carries the `vespersFrom` tag this reads.
|
||||
*/
|
||||
export function getVespersStatusLabel(day: LiturgicalDay): Bi {
|
||||
if (day.winner.kind === 'sanctoral' && day.winner.vespersFrom === 'firstVespersOfTomorrow') {
|
||||
return bi('First Vespers (of tomorrow)', 'Vesperæ de sequenti');
|
||||
}
|
||||
return bi('Second Vespers (of today)', 'Vesperæ de hodierno');
|
||||
}
|
||||
|
||||
/**
|
||||
* The full "day being celebrated" label: the day's own primary identity
|
||||
* (a sanctoral winner, a named temporal feast, a season's own anchor day,
|
||||
|
||||
Reference in New Issue
Block a user