# Analytics Toolbar block

> Two-row analytics dashboard navbar with date range picker, compare toggle, and command-K search

Sticky analytics toolbar with breadcrumb title, calendar date range picker, compare toggle, auto-refresh select, share, export/embed dropdown, and command-K search dialog. shadcn Breadcrumb, Popover, Calendar, Select, DropdownMenu, Dialog, Kbd.

- Type: Pro block
- Category: [Navbar](https://web.dev.reui.io/blocks/application/navbar.md)
- Page: https://web.dev.reui.io/blocks/application/navbar/navbar-6
- MCP: `get_block("navbar-6")`
- Built with: Avatar, Breadcrumb, Button, Calendar, Dialog, Dropdown Menu, Input, Kbd, Popover, Select, Separator
- Installs with a ReUI Pro or Ultimate license; setup: https://web.dev.reui.io/docs/license-setup

## Best for

A spinning refresh button with an Off to 5m auto refresh select, over a second row with a single date Calendar popover and a Compare toggle

## Agent notes

- `handleRefresh` only spins the icon for 1200 ms, and the auto refresh `Select` keeps its `defaultValue` with no timer behind it
- `DateRangePicker` stores one `date` from a `Calendar` in single `mode`, not a range, and `comparing` in `CompareToggle` drives nothing
- Share, Edit dashboard, Export CSV, Export PNG and Embed have no handler, and `DASHBOARD_NAME` is the fixed title

## When not to use

- A range of days or preset ranges picked in a popover with Apply and Cancel: use [Date Selector](https://web.dev.reui.io/components/date-selector.md) (`get_component("date-selector")`)
- A page body of metric cards and charts under the header: use the [Dashboard blocks](https://web.dev.reui.io/blocks/application/dashboard.md)

## Third-party libraries

- date-fns v4: [docs](https://date-fns.org/v4.1.0/docs/Getting-Started)
- next-themes: [API reference](https://github.com/pacocoursey/next-themes#api), [docs](https://github.com/pacocoursey/next-themes)
- React DayPicker v9: [API reference](https://daypicker.dev/v9/api), [docs](https://daypicker.dev/v9/start), through shadcn Calendar

## Install

```bash
npx shadcn@latest add @reui/navbar-6
```

## About Navbar blocks

### When to use

- The top bar of a signed in product, with a breadcrumb or switchers, search, alerts, avatars or a user menu
- An editor toolbar with a back or close button, the page name and its run, publish or submit action
- A marketing site header with mega menu panels of linked pages and a Get Started button

### When not to use

- A whole product layout with a side rail, a header and the content area together: use the [App Shell blocks](https://web.dev.reui.io/blocks/application/app-shell.md)
- A keyboard palette that lists, groups and filters results as you type: use [Command](https://web.dev.reui.io/components/command.md) (`get_component("command")`)
- The account settings page a user menu opens, with team, billing and API key forms: use the [Profile blocks](https://web.dev.reui.io/blocks/application/profile.md)

### Agent notes

- `Navbar` takes no props, so every label, person and option it shows is fixed in the block; lift them into props to reuse it
- No button, link or menu item routes or calls an API; add an `onClick` or a real `href` where each one should go
- Each page.tsx adds only demo padding or dashed placeholder boxes around `Navbar`, none of which belongs in your layout

Every ReUI item has a twin like this one; the index is https://web.dev.reui.io/llms.txt. Agents with the ReUI MCP (https://web.dev.reui.io/docs/mcp) get the same guidance from the getters named above.
