---
title: "Settings layout"
description: "A settings screen: grouped sections down the side and the chosen section's breadcrumb, heading and content beside them."
---

The frame of a settings area, assembled from a [Side Nav](/docs/components/side-nav) and a [Breadcrumb](/docs/components/breadcrumb). You describe the sections as data and render the current one as the block's content, so each section stays an ordinary component of yours.

Below 40rem the navigation moves above the content.

_Live example of Settings layout — see the page for the rendered demo._

## Installation

```bash
npx newtui@latest add settings-layout
``` Registry dependencies, installed with it: side-nav, breadcrumb.

Files written — React: components/settings-layout.tsx. Vue: components/settings-layout/SettingsLayout.vue, components/settings-layout/types.ts, components/settings-layout/index.ts.

## Usage

React:

```tsx
import { SettingsLayout } from "@/components/settings-layout"
```

Vue:

```ts
import { SettingsLayout } from "@/components/settings-layout"
```

## API reference

**`SettingsLayout`**

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `title` | `string` | — | What is being configured. It is the first crumb and the name of the navigation. |
| `groups` | `{ label?: string; sections: SettingsSection[] }[]` | — | The sections, in groups. A section is `{ id, label, badge?, danger? }`. |
| `section / v-model:section` | `string` | — | The id of the section being shown. |
| `onSectionChange` | `(section: string) => void` | — | React only. Called when an entry is chosen; Vue emits `update:section`. |
| `children / default slot` | `React.ReactNode / Vue slot` | — | The content of the current section. |

The entries are buttons, because the block swaps content in place. In a routed app, copy the block and give each `SideNavItem` an `href`.

## Accessibility

The navigation is a landmark named by `title`. The content column is a plain box, so put the block inside your page's own `<main>`. The current section carries `aria-current="page"` in the navigation and is repeated as the breadcrumb's last crumb and as the heading above the content.

## Tokens

Settings layout reads its colours, radii and motion from the `--newt-*` tokens. Override a token rather than editing the component.
