Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions ai/contextual-menu.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,24 @@
}
```

## Display location

By default, the contextual menu appears in the page header. You can configure it to display in the table of contents sidebar instead using the `display` option.

```json
{
"contextual": {
"options": ["copy", "view", "chatgpt", "claude"],
"display": "toc"
}
}
```

| Value | Description |
|:------|:------------|
| `header` | Displays options in the top-of-page context menu (default) |
| `toc` | Displays options in the table of contents sidebar |

## Adding custom options

Create custom options in the contextual menu by adding an object to the `options` array. Each custom option requires these properties:
Expand All @@ -67,7 +85,7 @@
</ResponseField>

<ResponseField name="description" type="string" required>
The description of the option. Displayed beneath the title when the contextual menu is expanded.

Check warning on line 88 in ai/contextual-menu.mdx

View check run for this annotation

Mintlify / Mintlify Validation (mintlify) - vale-spellcheck

ai/contextual-menu.mdx#L88

In general, use active voice instead of passive voice ('is expanded').
</ResponseField>

<IconsRequired />
Expand Down
Loading