Skip to content

Conversation

@dhairyashiil
Copy link
Member

@dhairyashiil dhairyashiil commented Nov 29, 2025

Video:

Screen.Recording.2025-11-29.at.10.00.57.PM.mov
Screen.Recording.2025-11-29.at.10.00.57.PM.mov
  1. tooltip
Screen.Recording.2025-11-29.at.10.04.31.PM.mov
  1. team ooo
Screen.Recording.2025-11-29.at.10.56.30.PM.mov

What does this PR do?

Adds the ability to display Out of Office (OOO) notes publicly on booking pages with a privacy toggle. This feature improves transparency and communication when users are unavailable.

Changes

Database Schema

  • Added showNotePublicly boolean field to OutOfOfficeEntry model (default: false for backward compatibility)
  • Created and applied database migration

Backend (tRPC)

  • Updated outOfOfficeCreateOrUpdate handler to accept and save showNotePublicly field
  • Updated Zod schema validation to include showNotePublicly as optional boolean
  • Modified OOO repository methods to select and return notes and showNotePublicly fields
  • Updated getUserAvailability to propagate OOO notes and visibility through the data flow
  • Enhanced slot generation logic to include notes when publicly visible

Frontend - Settings UI

  • Added "Show note publicly" toggle to Create/Edit OOO Entry modal
  • Toggle positioned next to "Notes" label following Booking Questions UI pattern
  • Shows "Hidden" badge when toggle is OFF, no text when ON
  • Toggle always visible (not dependent on note content)
  • Fixed bug where toggle state wasn't properly loaded when editing existing entries

Frontend - Booking Page

  • Display OOO message on booking page when showNotePublicly is enabled
  • Message shows before redirect information with "OOO Message:" label
  • Only message text is italicized, not the label
  • OOO dates are now selectable even without redirect configured
  • Redirect button only shows when team member is assigned
  • Added scrollable container for long notes (max-height: 120px) to prevent UI overflow
  • Hide 12h/24h time format toggle when viewing OOO dates (optimization: O(1) check)

Use Cases

Scenario 1: OOO with Redirect

  • User selects OOO date on calendar
  • Sees OOO emoji, user name, message, and redirect text
  • Redirect button displayed to book with team member

Scenario 2: OOO without Redirect

  • User selects OOO date on calendar
  • Sees OOO emoji, user name, and message (if public)
  • No redirect button shown
  • Cannot book time slots (blocked)

@dhairyashiil dhairyashiil requested a review from a team as a code owner November 29, 2025 14:37
@graphite-app graphite-app bot added the community Created by Linear-GitHub Sync label Nov 29, 2025
@vercel
Copy link

vercel bot commented Nov 29, 2025

@dhairyashiil is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to