[Feature] UI - Leftnav: Add external link icon to Learning Resources#24069
Conversation
Add ExportOutlined icon next to nav items that link to external pages, making it clear to users when a link opens in a new tab. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Greptile SummaryThis PR adds a small
Confidence Score: 5/5
|
| Filename | Overview |
|---|---|
| ui/litellm-dashboard/src/components/leftnav.tsx | Adds ExportOutlined antd icon next to the label of any nav item with an external_url (currently only "Learning Resources"). The change is minimal and well-scoped; only a missing aria-hidden on the decorative icon is worth addressing. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["renderNavLink(label, page, externalUrl?)"] --> B{externalUrl set?}
B -- Yes --> C["Render <a href=externalUrl target=_blank>"]
C --> D["label text + ExportOutlined icon ✨"]
B -- No --> E["Render <a href=?page=...>"]
E --> F["label text only"]
Last reviewed commit: "[Feature] UI - Leftn..."
| style={{ color: "inherit", textDecoration: "none" }} | ||
| > | ||
| {label} | ||
| {label} <ExportOutlined style={{ fontSize: 10, marginLeft: 4 }} /> |
There was a problem hiding this comment.
Icon missing
aria-hidden for screen readers
The ExportOutlined icon is purely decorative — its meaning is already conveyed by the target="_blank" on the surrounding <a> and (for screen readers) can be announced via rel="noopener noreferrer". Without aria-hidden="true", assistive technologies may attempt to announce the icon as an unnamed interactive element, producing confusing output like "icon" or nothing at all.
| {label} <ExportOutlined style={{ fontSize: 10, marginLeft: 4 }} /> | |
| {label} <ExportOutlined aria-hidden="true" style={{ fontSize: 10, marginLeft: 4 }} /> |
e8e4d9f
into
litellm_yj_march_18_2026
Summary
Problem
The "Learning Resources" nav item opens an external page but has no visual indicator distinguishing it from internal navigation links.
Fix
Added an
ExportOutlinedantd icon next to nav labels that have anexternal_url, so users can tell at a glance that the link opens in a new tab.Testing
external_urlType
🆕 New Feature