# Panel

A page of content with a title and its sections. `Panel.Sections` sit one heading level below `Panel.Title`. `Panel.usePanelTitle` returns a getter for the title element, to move focus to it.

## Use for

- a page of settings with a title and sections
- a page inside a `Profile`
- focusing the page title after navigation, with `Panel.usePanelTitle`

## Practices

- Do: Put each `Section` inside `Panel.Sections`, so its heading is one level below the title.
- Don't: Render your own heading for a `Profile.ContentPanel` page. Use `Panel.Title`: it is the page title there, and on compact layouts it opens the navigation.

## API reference

### Panel.Root

A `div` that holds the title ref for `Panel.usePanelTitle`.

Slot: `cl-panel`

### Panel.Title

A focusable `div` (`tabIndex={-1}`) around a `2xl` `Heading` at the current level. In a `Profile.ContentPanel` it is the page title, and on compact layouts the navigation's trigger.

Slot: `cl-panel-title`

### Panel.Sections

A `div` that sets the heading level one deeper for its children.

Slot: `cl-panel-sections`

## Examples

### A page

```tsx
<Panel.Root>
  <Panel.Title>Account</Panel.Title>
  <Panel.Sections>
    <Section.Root>…</Section.Root>
  </Panel.Sections>
</Panel.Root>
```

## Related

- [Profile](https://mosaic.clerk.com/docs/components/profile.md)
- [Section](https://mosaic.clerk.com/docs/components/section.md)
- [Heading](https://mosaic.clerk.com/docs/components/heading.md)
