A shadcn-style floating panel component built with Ark UI primitives.

Installation

npx shadcn@latest add @ark-cn/floating-panel

Usage

import * as FloatingPanel from "@/components/ui/floating-panel"

Read exported parts in src/components/ui/floating-panel.tsx and compose the primitive according to the Ark UI pattern for this component.

Examples

Basic

Context

Panel is closed.

Controlled Open

Controlled Position

Controlled Size

API reference

This component mirrors the upstream Ark UI primitive. All props and DOM behavior are defined by Ark unless you see an ark-cn-only row below.

FloatingPanelPopup

PropTypeDescription
disablePortal?booleanRenders content in-place instead of portaled.
positionerClassName?stringExtra class on the positioner wrapper.

See the ARK UI documentation for the full API.