Skip to content

Calendar: preview the home page button before 1 December when logged in #62

Done

Description

@maxitect

The home page button that leads to the advent calendar (src/app/(frontend)/_components/CalendarButton.tsx) only shows from 1 December. Before launch, we want to check it on the live site without showing it to the public.

Deliverables

  • A checkbox in CalendarSettings, for example "Show the home page calendar button to logged-in users before 1 December" (migration). Off by default.
  • When the checkbox is on and the visitor is logged in to Payload, the home page shows the calendar button before 1 December, in both languages, linking to /calendrier or /calendar.
  • Visitors who aren't logged in see no change: no button before 1 December, whatever the checkbox says. From 1 December, the button shows for everyone, as it does today.

Acceptance criteria

  • With the checkbox on, a logged-in Payload user sees the calendar button on / in French and English before 1 December
  • With the checkbox off, a logged-in user sees no button before 1 December
  • A visitor who isn't logged in sees no button before 1 December, with the checkbox on or off
  • From 1 December, everyone sees the button whatever the checkbox says
  • The home page stays as cheap for public visitors as perf(home): cut the home page's first-visit document and font cost #54 left it: the logged-in check does not make the page dynamic for everyone, or the PR says why it had to
  • The migration runs cleanly on a Neon branch; no console errors or CSP violations on /

Depends on

#60 (both add a CalendarSettings migration)

Activity

  1. self-assigned this
    on Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions