Documentation menu
Getting Started
Components
Primitives
- Agent Thinking
- Alert
- Alert Dialog
- Avatar
- Badge
- Breadcrumb
- Button
- Button Group
- Calendar
- Card
- Checkbox
- Command
- Command Palette
- Context Menu
- Data Table
- Dialog
- Dropdown Menu
- Empty
- Field
- Glow Cloud
- Input
- Label
- Medication Schedule
- Period Tabs
- Popover
- Rainbow Button
- Scroll Area
- Select
- Selectable Card
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Sonner
- Spinner
- Switch
- Table
- Tabs
- Tag
- Textarea
- Timeline
- Tooltip
- Use Count Up
Charts and metrics
Patterns
- Confirm Button
- Date Picker
- Embedded
- Empty State
- Entity Drawer
- Error Boundary
- Field Row
- File Dropzone
- Form Dialog
- Kv
- List Editor
- List Page
- Live Time
- Mini Table
- Money
- Note Field
- Note Text
- Page Card
- Page Header
- Page Tabs
- Page Toolbar
- Person Cell
- Picture Field
- Print Card
- Range Switcher
- Row Actions
- Search Input
- Search Select
- Selected Box
- Signature Pad
- Status Badge
- Sub Nav Layout
- Suggest Input
- Tab Icons
- Table Footer
- Theme Accent Picker
- Time Picker
- View All Link
Dashboard cards
Advanced
Device frames
Website widgets
Website screens
Website panels
Website panels
Bed Board Panel
Inpatient: a ward bed board with occupied, cleaning, reserved and free beds.
import BedBoard from "@/registry/vcare/site/panels/BedBoard"
export default function SiteBedBoardPanelDemo() {
// The width of a half-width Departments card.
return (
<div className="vc-site grid place-items-center overflow-x-auto rounded-2xl bg-[#f5f6f8] p-6">
<div className="w-full max-w-[520px]">
<BedBoard />
</div>
</div>
)
}Installation
npx shadcn@latest add @vcare/site-bed-board-panelOr install directly from the URL: https://ui.vcarehms.com/r/site-bed-board-panel.json
- Install the dependencies:
npm i react-icons - Add the registry items it uses: site-kit, site-theme.
- Copy this file into your project and change the
@/registry/vcare/…imports to your own paths.
components/site/panels/BedBoard.tsx
import { LuBedDouble } from 'react-icons/lu';
import { Item, Kpi, Panel } from '../ui/kit';
type Bed = { id: string; state: 'occupied' | 'free' | 'reserved' | 'cleaning'; who?: string; note?: string };
const beds: Bed[] = [
{ id: 'GW-01', state: 'occupied', who: 'David Moreno', note: 'Day 46 · Dengue fever' },
{ id: 'GW-02', state: 'cleaning' },
{ id: 'GW-03', state: 'free' },
{ id: 'SP-01', state: 'occupied', who: 'Sofia Novak', note: 'Day 44 · Low back pain' },
{ id: 'SP-02', state: 'free' },
{ id: 'PR-01', state: 'reserved', who: 'Sarah Collins', note: 'Planned admission' },
];
const style = { occupied: 'bg-[#e6efff] ring-[#c7dafc]', free: 'bg-[#e3f6ea] ring-[#bfe6cd]', reserved: 'bg-[#fff3d6] ring-[#f3d99b]', cleaning: 'bg-[#fff0e3] ring-[#f6d3b3]' } as const;
export default function BedBoard() {
return (
<Panel>
<div className="grid grid-cols-2 gap-2 p-3">
<Kpi icon={<LuBedDouble size={16} />} label="Occupancy" value="18%" />
<Kpi icon={<LuBedDouble size={16} />} label="Free beds" value="10" tone="green" />
</div>
<div className="grid grid-cols-2 gap-2 px-3 pb-3 sm:grid-cols-3">
{beds.map((b, i) => (
<Item key={b.id} i={i} className={`rounded-xl p-2.5 ring-1 ${style[b.state]}`}>
<div className="flex items-center justify-between text-[11.5px] font-bold text-ink"><span className="flex items-center gap-1"><LuBedDouble size={12} />{b.id}</span></div>
{b.who ? <p className="mt-1.5 truncate text-[11.5px] font-semibold text-ink">{b.who}</p> : <p className="mt-1.5 text-[11px] font-medium text-[#4b5160]">{b.state === 'free' ? 'Admit here' : 'Mark ready'}</p>}
<p className="truncate text-[10.5px] text-[#6b7280]">{b.note ?? (b.state === 'free' ? 'Available' : 'Being cleaned')}</p>
</Item>
))}
</div>
</Panel>
);
}Usage
import BedBoard from "@/components/site/panels/BedBoard"
<BedBoard />Exports
BedBoard (default)
Dependencies
react-icons@^5.7.0(npm)@vcare/site-kit(registry)@vcare/site-theme(registry)
Raw item: /r/site-bed-board-panel.json