Navigation
A navigation menu to trigger queries, open other Retool apps, export data, or copy values to the clipboard. It supports a single level of submenu items, and supports both horizontal and vertical orientation.
Navigation can display a logo that performs the same actions as a menu item. It can also use a responsive layout that collapses into a menu icon in horizontal mode, for either smaller viewports or on overflow.
Navigation supports linking an item directly to an app. Doing so will automatically highlight the item (or its parent) when currently viewing its linked app, and hide it for any users who do not have access to its linked app.
Properties
Available properties for Navigation with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read information about components.
An accessible image description for screen readers.
A list of app IDs, by index, for each item.
A list of captions for each item, by index.
The source data for the component.
Self-hosted Retool deployments only. The ID of the uploaded image when srcType
is dbBlobId
.
Whether user input, interaction, or selection is disabled.
A list of boolean values for each item, by index, that reflect whether they are disabled.
Whether the height automatically resizes to fit content or is a fixed size.
Whether the component is visible.
A list of boolean values for each item, by index, that reflect whether they are hidden.
A list of boolean values for each item, by index, that reflect whether they are highlighted.
The horizontal alignment of the contents.
A list of icons for each item, by index.
A list of icon positions for each item, by index, relative to labels.
The configuration mode for option lists. Either dynamic
for mapped options or static
for manual options.
A list of strings, by index, that reflect the type of item.
A list of IDs, by index, for each item.
A list of labels for each item. Falls back to the corresponding value
if no label is provided.
Whether the component takes up space on the canvas if hidden
is true
.
The amount of margin to render outside of the component.
Whether to display the menu vertically or horizontally.
Control when to show a menu button instead of the full menu. Only available in horizontal mode.
A list of IDs, by index, for each item that reflects the parent menu item.
A file representation that is shared by components on Retool.
Whether the input for retoolStorageFileId
is dynamic.
The id of the uploaded image when srcType
is retoolStorageFileId
.
Toggles the dropdown between Retool Storage files and legacy uploaded files.
A list of screen IDs, by index, for each item.
A list of screen IDs, by index, for each item.
Whether the component remains visible in the editor if hidden
is true
.
The source URL of the image when srcType
is src
.
The height of the source image.
The type of the image source. Either src
, dbBlobId
, or storageBlobId
.
The width of the source image.
The ID of the uploaded image when srcType
is storageBlobId
.
A list of tooltips for each item, by index.
The text to display in a tooltip on hover or focus.
Events
Events are triggered by user interactions with Navigation. Use event handling to trigger queries or other actions in response to events.
A user clicks a menu item
A user clicks on the logo
Methods
Methods for interacting with Navigation. You can write JavaScript almost anywhere in Retool and use methods to manipulate data or components.
Scrolls the canvas or parent container so that the selected component appears in the visible area.
Set the hidden
value to toggle whether the component is visible. Defaults to true
without a parameter.
Set the disabled
value to toggle whether the input field is disabled. Defaults to true
without a parameter.