复制一段给 AI 编程工具的提示词,包含源码、依赖和用法
属性
InspectorPanelProps
同时支持以下类型的全部属性: Omit<React.ComponentProps<"aside">, "title">
| 属性 | 类型 | 默认值 | 说明 |
|---|---|---|---|
| open* 必填 | boolean | — | — |
| onOpenChange* 必填 | (open: boolean) => void | — | — |
| title* 必填 | React.ReactNode | — | — |
| subtitle | React.ReactNode | — | — |
| icon | React.ReactNode | — | — |
| properties* 必填 | InspectorProperty[] | — | — |
| activity | InspectorActivity[] | [] | — |
| pinnable | boolean | true | Show the pin button. Pinned panels ignore outside clicks. |
| pinned | boolean | — | — |
| defaultPinned | boolean | false | — |
| onPinnedChange | (pinned: boolean) => void | — | — |
| width | number | 360 | Panel width in px on screens wider than 640px; below that it is a full-width sheet |
| fixed | boolean | false | Use viewport positioning instead of the nearest positioned ancestor |
安装
$ npx shadcn@latest add https://chromotion.dev/r/inspector-panel.json