Skip to content

Optionally show booked times as greyed out on the booking page #19

Description

@shockalotti

Requested in #14, agreed there after discussion.

Optionally show times that are already booked as greyed-out, non-clickable entries in the slot list, instead of omitting them. For public-hours use cases (intro calls, clinics, tutoring) a visibly busy calendar communicates demand and limited availability; today an empty-looking list reads as "nothing here".

Per event type, default off. Reasoning is in the discussion: the endpoint is public and unauthenticated, and while the host's schedule is already inferable by comparing days or by polling and diffing, greying makes that effortless and exact for a casual visitor. Fine when hours are public, not fine for an instance fronting internal team calendars.

Scope it narrowly

Grey only slots blocked by a booking or a calendar conflict, inside the host's offered hours.

Do not render:

  • times outside the host's availability rules (that's the whole rest of the day, and it's the part that leaks the frame)
  • times unavailable only because of min_notice_minutes - greying those claims "someone booked this" when nobody did, corrupting exactly the signal this feature exists to send. Those get the hint in Booking page: explain empty slot lists and minimum-notice gaps #20 instead.

Buffer-blocked slots are a judgement call; leaning toward greying them, since they genuinely are unbookable.

Implementation notes

  • slots.Generate (internal/slots/generate.go) never materialises unavailable starts. It subtracts busy from the working windows and then walks what remains, so the skipped starts don't exist as objects. It has to emit them, tagged with a reason, for this to be possible at all.
  • Do not surface unavailable slots through MCP get_available_slots or the booking assistant. The assistant's invariant is that it only ever sees computed availability; hand it a list containing unbookable entries and it will eventually offer one.
  • Latent bug to avoid: book.html derives which calendar dates are clickable from Object.keys(slotsByDay). Mix unavailable slots into that structure and a fully booked day starts looking bookable. The available-dates set must count bookable slots only.
  • Watch payload size on the month prefetch.
  • Three surfaces: book.html, manage.html, embed.js. Markup and JS are not shared; styling is (booking.css). Verify desktop and mobile on each.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions