Skip to content
GitHub

Widget Area

Widget sizing container

Widget
import { WidgetArea } from "@/components/ui/pxl/widget-area";
export default function WidgetAreaDemo() {
return (
<WidgetArea className="bg-primary text-primary-foreground pixel-rounded flex items-center justify-center">
Widget
</WidgetArea>
)
}
pnpm dlx shadcn@latest add pxl-ui/registry/widget-area
import { WidgetArea } from "@/components/ui/pxl/widget-area"
<WidgetArea size="sm" />

Use Widget Area to display your widgets in desktop or floating setups. For full screen scenarios, use Anchor Grid instead.

Use the size prop to change the size of the widget.

Small
Medium
Large
ExtraLarge
import { WidgetArea } from "@/components/ui/pxl/widget-area";
export default function Sizes() {
return (
<div className="flex flex-col gap-2 w-full">
<WidgetArea size="sm" className="bg-primary text-primary-foreground pixel-rounded flex items-center justify-center">
Small
</WidgetArea>
<WidgetArea size="md" className="bg-primary text-primary-foreground pixel-rounded flex items-center justify-center">
Medium
</WidgetArea>
<WidgetArea size="lg" className="bg-primary text-primary-foreground pixel-rounded flex items-center justify-center">
Large
</WidgetArea>
<WidgetArea size="xl" className="bg-primary text-primary-foreground pixel-rounded flex items-center justify-center">
ExtraLarge
</WidgetArea>
</div>
)
}