Skip to main content

Sheet

An edge-docked slide-over sheet supporting right, left, top, and bottom sides with smooth easing, backdrop blur, focus trap, and Escape dismissal.

Linh Tran·side="right"

Customize

Backdrop blur (px)4
Speed1

Installation

npx shadcn@latest add @kinetic/sheet

Usage

import {
  Sheet,
  SheetClose,
  SheetContent,
  SheetDescription,
  SheetFooter,
  SheetHeader,
  SheetTitle,
  SheetTrigger,
} from "@/components/kinetic/ui/sheet";

export function EditProfile() {
  return (
    <Sheet>
      <SheetTrigger>Edit profile</SheetTrigger>
      <SheetContent>
        <SheetHeader>
          <SheetTitle>Edit profile</SheetTitle>
          <SheetDescription>Update your details below.</SheetDescription>
        </SheetHeader>
        <SheetFooter>
          <SheetClose>Close</SheetClose>
        </SheetFooter>
      </SheetContent>
    </Sheet>
  );
}

Sides

Set side on SheetContent to right (default), left, top, or bottom.

<SheetContent side="left">...</SheetContent>
<SheetContent side="bottom">...</SheetContent>

Controlled state

Pass open and onOpenChange to control the sheet, or defaultOpen for an uncontrolled initial state.

<Sheet open={open} onOpenChange={setOpen}>
  ...
</Sheet>

Close button

SheetContent shows a close button by default. Set showCloseButton={false} to hide it and provide your own SheetClose.

<SheetContent showCloseButton={false}>...</SheetContent>

Speed and blur

speed scales the animation, blurPx sets the panel blur during motion, and backdropBlurPx sets the backdrop blur. They can be set on Sheet and overridden on SheetContent.

<Sheet speed={1.25} backdropBlurPx={6}>...</Sheet>

Motion preferences

With reduced motion enabled, the sheet uses a short fade instead of sliding from the edge. Animation timing follows the current Kinetic tempo. Focus is trapped while open, Escape closes the sheet, and focus returns to the trigger.

API Reference

Sheet

Zero-dependency root managing sheet open state, animation speed, and backdrop blur.

PropTypeDefaultDescription
open / defaultOpen / onOpenChangeboolean / (open: boolean) => void-Controlled or uncontrolled open state.
speednumber1Animation speed multiplier (0.25 to 4).
backdropBlurPxnumber4Backdrop blur radius in pixels (0 to 20).

SheetContent

Edge-docked portaled surface with smooth drawer easing, focus trapping, and close button.

PropTypeDefaultDescription
side"right" | "left" | "top" | "bottom""right"Viewport edge from which the sheet slides in.
showCloseButtonbooleantrueRenders the top-right dismiss button.
speed / backdropBlurPxnumber-Optional overrides for root speed and backdrop blur.

Notes

SheetTitle is required inside SheetContent for accessibility (use className='sr-only' if hidden). SheetOverlay and SheetPortal are internal; customize body spacing with px-4 to match SheetHeader and SheetFooter.