Skip to content

feat(calendar): add the night page - #162

Merged
Jrodrigo06 merged 5 commits into
calendar-windowfrom
night-detail
Nov 27, 2026
Merged

Jrodrigo06 merged 5 commits into
calendar-windowfrom
night-detail

Conversation

@Jrodrigo06

@Jrodrigo06 Jrodrigo06 commented Nov 26, 2026 •

Copy link
Copy Markdown
Collaborator

What

A page for one night at /nights/:date, built from the "Calendar – Day view" design, limited to what the backend sends:

  • Header with the date, days out, a link back to the calendar and the previous and next night.
  • Our rate before VAT, and the manager's rate if set.
  • "Why this price": every factor, grouped into Day and season, Booking timing, Events, Holidays and Combined effects. The starting point plus every line adds up to the rate.
  • The night's events, or "Events not loaded for this night" when the backfill missed it.
  • A "Your rate" field with Save, which sends feedback and fetches the night again.
  • The sidebar keeps Calendar highlighted on a night's page.

Why

The hover card now shows only the 3 biggest reasons, so the full breakdown needs a home, and managers need a way to set their own rate.

How to check

  • just dev --neon and just frontend, open a night from the calendar's "See all reasons".
  • The lines in "Why this price" should add up to the rate.
  • Change "Your rate" and Save: the manager's rate card should update.

Screenshots

5 December

5 December

25 December

25 December

5 December after saving a rate

5 December after saving a rate

Notes

  • Groups are read from the factor wording, since the API sends no group. A renamed label in the backend would land in "Other".
  • A busy night can have over 70 events, so the list shows 8 with "Show all".
  • Room types, multipliers, the lock and the charts in the design are left out until the backend supports them.

@Jrodrigo06
Jrodrigo06 added this pull request to stack #158 November 26, 2026 22:21
The night page needs to POST a rate, so apiPost now takes an optional JSON body.
Feedback must name the snapshot the manager saw, and the night page needs to tell unloaded events from none. The mock's days-ahead factor now uses the backend's wording.
The hover card now shows only the biggest reasons, so /nights/:date lists all of them, grouped, adding up to the rate, with the night's events.
Managers can now record their own rate, which the tune-up learns from; saving fetches the night again so the manager's rate shows.
A night's page sits under the calendar, so the sidebar should still show where you are.
@Jrodrigo06
Jrodrigo06 merged commit 6173a85 into main Nov 27, 2026
8 checks passed
@Jrodrigo06
Jrodrigo06 deleted the night-detail branch November 27, 2026 20:49
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.

2 participants