# SidebarNavigation

> Represents the navigator row of the sidebar snapshot card: the four capture links and whether they act as a grid cursor.

[API reference](/docs/api/index.md) › [Debug Core](/docs/extensions/debug-core/reference/index.md) › [View](/docs/extensions/debug-core/reference/view/index.md) › [Sidebar](/docs/extensions/debug-core/reference/view/sidebar/index.md) › SidebarNavigation

| final readonly class | `PHPForge\Debug\View\Sidebar\SidebarNavigation` |
| --- | --- |
| Source | [`src/View/Sidebar/SidebarNavigation.php`](https://github.com/php-forge/debug-core/blob/main/src/View/Sidebar/SidebarNavigation.php#L14) |

Represents the navigator row of the sidebar snapshot card: the four capture links and whether they act as a grid
cursor.

The host computes every value from its own manifest and URL scheme, so this object carries no routing logic. The
defaults describe a single capture with nowhere to move.

## Properties

| Property | Type | Description | Defined by |
| --- | --- | --- | --- |
| <span id="property-cursorInitTag"></span>`$cursorInitTag` readonly constructor | `string` | Optional tag the cursor JS should land on when the sidebar arrives from a panel view's History link (`?cursor=<tag>`). Empty string falls back to the newest captured request. Default: `''`. | `SidebarNavigation` |
| <span id="property-hasNewer"></span>`$hasNewer` readonly constructor | `bool` | `true` when there is a newer request available; controls the Newer button. Default: `false`. | `SidebarNavigation` |
| <span id="property-hasOlder"></span>`$hasOlder` readonly constructor | `bool` | `true` when there is an older request available; controls the Older button. Default: `false`. | `SidebarNavigation` |
| <span id="property-isCursor"></span>`$isCursor` readonly constructor | `bool` | `true` when the sidebar is rendered for the index page and the navigator buttons act as a grid cursor. Default: `false`. | `SidebarNavigation` |
| <span id="property-isNewest"></span>`$isNewest` readonly constructor | `bool` | `true` when the snapshot is the newest captured request; disables the Newest button. Default: `true`. | `SidebarNavigation` |
| <span id="property-isOldest"></span>`$isOldest` readonly constructor | `bool` | `true` when the snapshot is the oldest captured request; disables the Oldest button. Default: `true`. | `SidebarNavigation` |
| <span id="property-newerUrl"></span>`$newerUrl` readonly constructor | `string` | Newer request link target; empty string when the snapshot is already on the newest row. Default: `''`. | `SidebarNavigation` |
| <span id="property-newestUrl"></span>`$newestUrl` readonly constructor | `string` | Newest request link target (top of list); empty string renders an empty `href`. Default: `''`. | `SidebarNavigation` |
| <span id="property-olderUrl"></span>`$olderUrl` readonly constructor | `string` | Older request link target; empty string when the snapshot is already on the oldest row. Default: `''`. | `SidebarNavigation` |
| <span id="property-oldestUrl"></span>`$oldestUrl` readonly constructor | `string` | Oldest request link target (bottom of list); empty string renders an empty `href`. Default: `''`. | `SidebarNavigation` |

## Methods

| Method | Description | Defined by |
| --- | --- | --- |
| [`__construct()`](#method-__construct) | Creates the sidebar snapshot navigation state. | `SidebarNavigation` |

## Method details

### __construct() <span id="method-__construct"></span>

```php
public function __construct(bool $isCursor = false, string $cursorInitTag = '', string $newestUrl = '', string $oldestUrl = '', string $newerUrl = '', string $olderUrl = '', bool $isNewest = true, bool $isOldest = true, bool $hasNewer = false, bool $hasOlder = false)
```

Creates the sidebar snapshot navigation state.

**Parameters**

| Parameter | Type | Description |
| --- | --- | --- |
| `$isCursor` | `bool` |  |
| `$cursorInitTag` | `string` |  |
| `$newestUrl` | `string` |  |
| `$oldestUrl` | `string` |  |
| `$newerUrl` | `string` |  |
| `$olderUrl` | `string` |  |
| `$isNewest` | `bool` |  |
| `$isOldest` | `bool` |  |
| `$hasNewer` | `bool` |  |
| `$hasOlder` | `bool` |  |