ChangeCard

A change Okami made in the owner's chat, and where it stands. A plain change has landed, with Undo. One that would leave bookings outside someone's hours waits for the owner, listing those bookings with a call button each; so does a booking's move or cancel, which then offers to call its client. Undone or declined, it stays as a record with nothing left to press.

Playground

Miro · different hours

Done

Fri, Nov 6

9:00–12:00

ChangeCard

Waiting for the owner

Miro · day off

Needs you

Fri, Nov 6

“Doctor”

This booking would fall outside the new hours. It stays booked, so the client needs a call.

  • Fri, Nov 6, 14:00Jana · Haircut

A booking moved

Matúš · new time

Done

Haircut · Pele

Thu, Oct 15 · 14:00–14:45

Before: Mon, Oct 12 · 10:00–10:45

API

PropTypeDefaultDescription
titlestring—Who and what: “Miro · day off”.
linesstring[]—The change itself, a line each: the dates, the hours, the note.
state"landed" | "waiting" | "undone" | "declined"—Where it stands. Landed shows Undo; waiting shows Confirm and Keep as is; the others show neither.
bookingsScheduleBooking[][]Bookings the change leaves, or would leave, outside the hours: each with its time, client and a call button.
call{ name: string; phone: string }—The client a landed move or cancel reaches: a Call button, since Okami can't message clients yet. Shown once it has landed, not while it waits.
localestring—How the bookings' dates read.
onUndo / onConfirm / onDecline() => void—The card's actions; each shows only in its state.
busybooleanfalseAn answer is on its way: the actions wait.
labelsPartial<ChangeCardLabels>EnglishEvery word, the statuses and booking lines included.

Guidelines

  • A change with no one else affected lands at once and shows Undo; don't ask “are you sure?” first (owner-chat spec C9).
  • A change that would strand bookings waits for the owner, with the bookings on the card: nothing moves until a tap (C8).
  • A booking's move or cancel always waits for the owner — a client holds that time — and has no Undo once confirmed; it offers the call instead.
  • The card is the record. Okami's message beside it says what's next, not what the card already shows.