Top nav items

Buttons and elements for the top nav.

Feature flag rollouts

Chat panel updates

When the platform-dst-chat-panel-layout feature flag is enabled, the layout supports displaying panel and chat panel at the same time, with updated resizing and responsive behavior.

Neutral selected states

When the platform-dst-tokens-finesse feature flag is enabled, this component uses the new neutral treatment for selected states.

These components can be used within the top nav from layout.

For Atlassian apps, Global top navigation (Atlassians only), (opens new window) provides a shared top nav built on Atlassian Design System components. See its documentation for configuration and integration guidance.

Start items

These actions go in the top nav start area. They are left-aligned in the following order:

  • Side nav toggle button: Opens and closes the side nav.
  • App switcher: Opens and closes an app switcher.

Use one of the following logo components to orient users and provide a persistent link to the app landing page:

Confluence
import React from 'react'; import { ConfluenceIcon } from '@atlaskit/logo/confluence-icon'; import { SideNavToggleButton } from '@atlaskit/navigation-system/layout/side-nav'; import { TopNavStart } from '@atlaskit/navigation-system/layout/top-nav'; import { AppLogo, AppSwitcher } from '@atlaskit/navigation-system/top-nav-items'; import { MockTopBar } from '../common/mock-top-bar'; export function TopNavStartLayoutExample(): React.JSX.Element { return ( <MockTopBar> <TopNavStart sideNavToggleButton={ <SideNavToggleButton defaultCollapsed collapseLabel="Collapse sidebar" expandLabel="Expand sidebar" /> } > {' '} {null} <AppSwitcher label="App switcher" /> <AppLogo href="https://jira.atlassian.com" icon={ConfluenceIcon} name="Confluence" label="Home page" /> </TopNavStart> </MockTopBar> ); } export default TopNavStartLayoutExample;

App switcher

App switcher opens the app switcher menu. By default, it uses the Atlassian app switcher icon.

Use the optional icon prop to replace the default icon with a custom visual, such as a product logo. Continue to provide a meaningful label so the custom visual has an accessible name.

Jira
import React from 'react'; import Avatar from '@atlaskit/avatar/avatar'; import { JiraIcon } from '@atlaskit/logo/jira/icon'; import { TopNavStart } from '@atlaskit/navigation-system/layout/top-nav'; import { AppLogo, AppSwitcher } from '@atlaskit/navigation-system/top-nav-items'; import dstLogo from '../../images/dst.png'; import { MockTopBar } from '../common/mock-top-bar'; const CustomAppSwitcherIcon = () => <Avatar size="small" appearance="square" src={dstLogo} />; export const CustomAppSwitcherExample = (): React.JSX.Element => { return ( <MockTopBar> <TopNavStart sideNavToggleButton={null}> <AppSwitcher icon={CustomAppSwitcherIcon} label="App switcher" onClick={() => {}} /> <AppLogo href="https://jira.atlassian.com" icon={JiraIcon} name="Jira" label="Home page" /> </TopNavStart> </MockTopBar> ); }; export default CustomAppSwitcherExample;

Side nav toggle button

The side nav toggle button must be passed to TopNavStart through the sideNavToggleButton prop, not via children.

  • When the keyboard shortcut is enabled, the toggle button’s tooltip will automatically show Ctrl+[ as the shortcut.
  • The toggle button appears before the app switcher and logo, whether the side nav is collapsed or expanded.
import React from 'react'; import { SideNavToggleButton } from '@atlaskit/navigation-system/layout/side-nav'; import { TopNavStart } from '@atlaskit/navigation-system/layout/top-nav'; import { MockTopBar } from '../common/mock-top-bar'; export function TopNavStartToggleExample(): React.JSX.Element { return ( <MockTopBar> <TopNavStart sideNavToggleButton={ <SideNavToggleButton defaultCollapsed collapseLabel="Collapse sidebar" expandLabel="Expand sidebar" /> } > {' '} {null} </TopNavStart> </MockTopBar> ); } export default TopNavStartToggleExample;

App logo displays an app logo icon and name.

  • It has a maximum width of 320px, after which the app name truncates.
  • At container widths below 1,024px, the app name is not shown.

See the responsive section for more information.

Secondary name

Use the optional secondaryName prop to add supporting context below the app name, such as the current experience or workspace. The supporting context is hidden with the app name at container widths below 1,024px.

import React from 'react'; import { JiraIcon } from '@atlaskit/logo/jira/icon'; import { TopNavStart } from '@atlaskit/navigation-system/layout/top-nav'; import { AppLogo } from '@atlaskit/navigation-system/top-nav-items'; import { MockTopBar } from '../common/mock-top-bar'; export const AppLogoSecondaryNameExample = (): React.JSX.Element => { return ( <MockTopBar> <TopNavStart sideNavToggleButton={null}> <AppLogo href="https://jira.atlassian.com" icon={JiraIcon} name="Jira" secondaryName="Software development" label="Jira home page" /> </TopNavStart> </MockTopBar> ); }; export default AppLogoSecondaryNameExample;

Custom logo provides a container for custom logo images with the following constraints:

  • Maximum width: 320px. If the image is wider than this, the logo will scale down to fit.
  • Maximum height: 24px. If the image is shorter than this, the logo will scale up to fit.

Do not provide explicit width and height values on the image, otherwise it will not respect the container size.

At container widths below 1,024px, only the provided icon is shown. At container widths of 1,024px and above, the provided logo is shown.

See the responsive section for more information.

Custom title

Optional text used for app customization by customers.

  • When present, it appears to the right of the logo.
  • It has a maximum width of 200px, after which the text truncates.
  • At container widths below 1,024px, the custom title is not displayed.
Jira
Custom title
import React from 'react'; import { JiraIcon } from '@atlaskit/logo/jira-icon'; import { TopNavStart } from '@atlaskit/navigation-system/layout/top-nav'; import { AppLogo } from '@atlaskit/navigation-system/top-nav-items'; import { CustomTitle } from '@atlaskit/navigation-system/top-nav-items/custom-title'; import { MockTopBar } from '../common/mock-top-bar'; export const CustomTitleExample = (): React.JSX.Element => { return ( <MockTopBar> <TopNavStart sideNavToggleButton={null}> <AppLogo href="http://www.atlassian.design" icon={JiraIcon} name="Jira" label="Home page" /> <CustomTitle>Custom title</CustomTitle> </TopNavStart> </MockTopBar> ); }; export default CustomTitleExample;

Middle items

These actions go in the top nav middle area.

  • They should consist of a search component and a create component, in that order to maintain the correct layout behavior.
  • The actions are center-aligned.
  • We have provided placeholder components.
  • Our placeholder search field scales to fill the available space, up to a maximum width of 680px. At container widths below 480px, it displays as an icon button.
  • Our placeholder create button displays as an icon button at container widths below 768px.

See the responsive section for more information. If you use search or create components from other packages, you may experience different responsive behavior.

The search bar must be the first child of TopNavMiddle, in line with our design specifications. Otherwise, you may see unexpected layout behavior.

import React from 'react'; import { TopNavMiddle } from '@atlaskit/navigation-system/layout/top-nav'; import { Search } from '@atlaskit/navigation-system/top-nav-items'; import { CreateButton } from '@atlaskit/navigation-system/top-nav-items/create-button'; import { MockTopBar } from '../common/mock-top-bar'; export function TopNavMiddleLayoutExample(): React.JSX.Element { return ( <MockTopBar> <TopNavMiddle> <Search label="Search" /> <CreateButton>Create</CreateButton> </TopNavMiddle> </MockTopBar> ); } export default TopNavMiddleLayoutExample;

End items

These actions appear in the top nav end area. They are right-aligned and provided as a list for accessibility. They appear in the following order:

  • Growth button: A placeholder for an upselling button (optional).
  • Notifications: Use to open and close notifications.
  • Help: Use to open and close help.
  • Settings: Use to open and close a settings menu.
  • Profile/Login: A placeholder for an account component.
  • Ask Rovo: Use to open Rovo Chat in chat panel.

At container widths below 768px, the other end items move into the More menu. Ask Rovo remains outside the menu and displays as an icon button.

Apps must wire up Ask Rovo to open chat panel and manage the button’s visibility based on chat panel state. Hide the button while chat panel is open and show it again when chat panel closes.

See the responsive section for more details.

Ask Rovo

Use Ask Rovo to open Rovo Chat in the chat panel.

  • Place it after the other end items using ResponsiveTopNavButton in the persistentItems prop on TopNavEnd. This keeps it outside the More menu.
  • At top nav container widths below 768px, it displays as an icon button.
  • Hide it while chat panel is open, and show it again when chat panel closes. Your app manages this visibility and the panel’s open state.

Wrap the button in a list item within an accessible list. When hiding the button, remove the containing list too, so it doesn’t leave an empty group.

The example below moves focus to the close button when chat opens. When chat closes, it returns focus to Ask Rovo if focus is still inside chat panel.

To adapt the example, supply your app’s navigation, page content, and chat content through its props. Connect your chat’s close action to closeChat, and pass the same handler to ChatPanel.onClose.

The persistentItems behavior is enabled behind the platform-dst-chat-panel-layout feature flag.

import React, { type ReactNode, useEffect, useRef, useState } from 'react'; import Badge from '@atlaskit/badge/badge'; import Button from '@atlaskit/button/default/button'; import { useId } from '@atlaskit/ds-lib/use-id'; import RovoChatIcon from '@atlaskit/icon/core/rovo-chat'; import { ChatPanel } from '@atlaskit/navigation-system/layout/chat-panel'; import { Main } from '@atlaskit/navigation-system/layout/main'; import { PanelSplitter } from '@atlaskit/navigation-system/layout/panel-splitter'; import { Root } from '@atlaskit/navigation-system/layout/root'; import { TopNav, TopNavEnd, TopNavMiddle, TopNavStart, } from '@atlaskit/navigation-system/layout/top-nav'; import { TopNavIconButton } from '@atlaskit/navigation-system/theming/top-nav-button'; import { Help } from '@atlaskit/navigation-system/top-nav-items/help'; import { Notifications } from '@atlaskit/navigation-system/top-nav-items/notifications'; import { Profile } from '@atlaskit/navigation-system/top-nav-items/profile'; import { ResponsiveTopNavButton } from '@atlaskit/navigation-system/top-nav-items/responsive-button'; import { Settings } from '@atlaskit/navigation-system/top-nav-items/settings'; import { Inline } from '@atlaskit/primitives/compiled/inline'; import { MenuListItem } from '@atlaskit/side-nav-items/menu-list-item'; export function AskRovoExample({ startItems, middleItems, children, chatContent, }: { startItems: ReactNode; middleItems: ReactNode; children: ReactNode; chatContent: ReactNode; }): React.JSX.Element { const [isChatOpen, setIsChatOpen] = useState(false); const chatId = useId(); const triggerRef = useRef<HTMLButtonElement>(null); const closeRef = useRef<HTMLButtonElement>(null); const shouldRestoreFocus = useRef(false); useEffect(() => { if (isChatOpen) { // Focus a meaningful control in your chat UI when the trigger disappears. closeRef.current?.focus(); } else if (shouldRestoreFocus.current) { triggerRef.current?.focus(); shouldRestoreFocus.current = false; } }, [isChatOpen]); const closeChat = () => { // Side nav can also dismiss a chat overlay. Preserve focus if it has moved outside chat. shouldRestoreFocus.current = document.getElementById(chatId)?.contains(document.activeElement) ?? false; setIsChatOpen(false); }; return ( <Root> <TopNav> <TopNavStart sideNavToggleButton={null}>{startItems}</TopNavStart> <TopNavMiddle>{middleItems}</TopNavMiddle> <TopNavEnd persistentItems={ isChatOpen ? null : ( <Inline role="list" aria-label="Chat"> <MenuListItem> <ResponsiveTopNavButton ref={triggerRef} iconButton={TopNavIconButton} icon={RovoChatIcon} label="Ask Rovo" onClick={() => setIsChatOpen(true)} /> </MenuListItem> </Inline> ) } > <Notifications label="Notifications" badge={() => <Badge appearance="dangerBold">{3}</Badge>} /> <Help label="Help" /> <Settings label="Settings" /> <Profile label="Profile" /> </TopNavEnd> </TopNav> <Main>{children}</Main> {isChatOpen && ( <ChatPanel id={chatId} onClose={closeChat}> <PanelSplitter label="Resize chat" /> <Button ref={closeRef} onClick={closeChat}> Close chat </Button> {chatContent} </ChatPanel> )} </Root> ); } export default AskRovoExample;

End item

If none of the provided end items are suitable, you can create your own icon button using EndItem.

If you need a more customized button, use top nav button and wrap it in a list item.

import React from 'react'; import AtlassianIntelligenceIcon from '@atlaskit/icon/core/atlassian-intelligence'; import { TopNavEnd } from '@atlaskit/navigation-system/layout/top-nav'; import { EndItem } from '@atlaskit/navigation-system/top-nav-items'; import { MockTopBar } from '../common/mock-top-bar'; export function EndItemExample(): React.JSX.Element { return ( <MockTopBar> <TopNavEnd> <EndItem icon={AtlassianIntelligenceIcon} onClick={() => alert('Atlassian Intelligence')} label="Atlassian Intelligence" /> </TopNavEnd> </MockTopBar> ); } export default EndItemExample;

Top nav button

A button component that supports theming. The following variants are available:

  • Top nav icon button
  • Top nav link button
  • Top nav link icon button
  • Top nav button

Use this component when you need to add buttons to the top nav. Be aware that adding custom buttons may negatively impact the consistency across apps.

import React from 'react'; import AiChatIcon from '@atlaskit/icon/core/ai-chat'; import TeamsIcon from '@atlaskit/icon/core/teams'; import { TopNav, TopNavEnd } from '@atlaskit/navigation-system/layout/top-nav'; import { TopNavButton, TopNavIconButton, TopNavLinkButton, TopNavLinkIconButton, } from '@atlaskit/navigation-system/theming/top-nav-button'; import { MockRoot } from '../../utils/mock-root'; export const TopNavButtonExample = (): React.JSX.Element => ( <MockRoot> <TopNav> <TopNavEnd> <TopNavIconButton icon={TeamsIcon} label="Top nav icon button" /> <TopNavLinkIconButton icon={AiChatIcon} href="#example-href" label="Top nav link icon button" /> <TopNavLinkButton iconBefore={TeamsIcon} href="#example-href"> Top nav link button </TopNavLinkButton> <TopNavButton iconBefore={AiChatIcon}>Top nav button</TopNavButton> </TopNavEnd> </TopNav> </MockRoot> ); export default TopNavButtonExample;

Responsive

Top nav items respond to the width of the top nav container. An inline chat panel reduces the space available to top nav, so responsive changes can occur without a change in viewport size.

The table shows the behavior of the placeholder components. Search and create components from other packages may have different responsive behavior.

Container widthStart itemsMiddle itemsEnd items
320–479pxLogo iconSearch and create icon buttonsMore button and Ask Rovo icon button
480–767pxLogo iconSearch field and create icon buttonMore button and Ask Rovo icon button
768–1,023pxLogo iconSearch field and create buttonEnd items shown individually
1,024–1,439pxLogo lockupSearch field and create buttonEnd items shown individually
1,440–1,767pxLogo lockupSearch field and create buttonEnd items shown individually
1,768px and aboveLogo lockupSearch field and create buttonEnd items shown individually

Ask Rovo is hidden while chat panel is open at every container width.

Explore the interactive example, (opens new window) to see how an inline chat panel affects top nav.

Custom theming

Custom theming is configured on the top nav.

Logos

Logos and icons from the logo package will automatically consume the theme when used with the AppLogo or CustomLogo component.

Custom logos uploaded by organization admins are not affected by theming.

Use the useLegacySearchTheme() hook to obtain a theme value that is compatible with existing Search Platform components.

Use sparingly

Do not create new components that rely on the useLegacySearchTheme() hook. It is intended only for backwards compatibility, and may be deprecated if the Search Platform evolves.

Buttons

Do not use button inside of the top navigation.

Use the action components exported from this package (such as AppSwitcher), as they automatically consume the custom theme.

Custom actions can be created using end item for icon buttons and top nav button for buttons with visible text.

import React from 'react'; import AngleBracketsIcon from '@atlaskit/icon/core/angle-brackets'; import { RovoIcon } from '@atlaskit/logo/rovo/icon'; import { TopNav, TopNavEnd } from '@atlaskit/navigation-system/layout/top-nav'; import { parseHex } from '@atlaskit/navigation-system/theming/color-utils/parse-hex'; import { TopNavButton } from '@atlaskit/navigation-system/theming/top-nav-button'; import { EndItem } from '@atlaskit/navigation-system/top-nav-items'; import { MockRoot } from '../../utils/mock-root'; export const CustomThemingButtonsExample = (): React.JSX.Element => ( <MockRoot> <TopNav customTheme={{ backgroundColor: parseHex('#964AC0'), highlightColor: parseHex('#F8EEFE') }} > <TopNavEnd> <TopNavButton iconBefore={(props) => <RovoIcon {...props} size="xxsmall" label="" />}> Chat </TopNavButton> <EndItem icon={AngleBracketsIcon} label="Dev tools" /> </TopNavEnd> </TopNav> </MockRoot> ); export default CustomThemingButtonsExample;
Was this page helpful?
We use this feedback to improve our documentation.
© 2026 AtlassianTrademark, (opens new window)Privacy, (opens new window)License