Thread Pane

Opens a reply thread beside a channel, or as a sheet on a phone.

Yesterday

  1. BO
    Ben Okafor

    Heads up: checkout errors are up since the 5 PM deploy. Looking into it.

Today

  1. AL
    Ada Lovelace

    @Scout can you triage the bugs that came in overnight? Anything that touches checkout goes to Payments.

  2. ScoutAgentfor Ada Lovelace
    Triaged 14 issues · 9 duplicates closed
    Thought for 11s

    Search issues opened after 18:00. Match titles and stack traces against open issues. Checkout bugs: payments, cart and invoice components.

    Three new bugs touch checkout:

    • PAY-412 Card declined when retrying payment

    • PAY-415 VAT shown twice on EU invoices

    • PAY-418 Wallet button missing on tablets

    I'd like to move them to Payments.

Installation

pnpm dlx shadcn@latest add checkfu/uicontext/thread-pane

Usage

import { ThreadPane } from "./ui/uicontext/components/kit/ThreadPane.ts"
const Message = UiSchema.TaggedEnum({ ClosedThread: {} })// `replies` and `composer` are your Channel (with `thread: true`) and Composerexport const ReplyPane = (	h: Html.H<typeof Message.Type>,	open: boolean,	replies: View.Content<typeof Message.Type>,	composer: View.Content<typeof Message.Type>,) =>	ThreadPane(h, {		props: { open, title: "Thread", subtitle: "#triage" },		onEmit: { RequestedClose: () => Message.ClosedThread() },		slots: { content: replies, composer },	})

Examples

As a sheet

When the space it sits in is narrower than breakpoint, the thread opens as a bottom sheet instead of a side panel.

API reference

Props

ThreadPane props
NameTypeDefaultDescription
openrequiredboolean—Whether the pane shows
titlerequiredstring—The pane's heading: "Thread"
subtitlestring—Where the thread is: "#triage"
breakpointnumber720Below this width (in CSS pixels) of the space it sits in, the pane is a bottom Sheet; 720 by default
compactAs"sheet" | "screen"—What it becomes below the breakpoint: a bottom sheet (the default), or a screen of its own

Events

ThreadPane events
EventPayloadDescription
RequestedClose{}The person closed the pane: its close button, Escape, or the sheet's backdrop

Slots

content, composer

Accessibility

  • The pane is a landmark named by its title; opening it moves focus to the title, and closing it returns focus to what opened it.
  • Escape or the Close thread button closes it. On a narrow screen it opens as a sheet from the bottom instead.

Source