fix(nav): use valid @posthog/icons names for docs menu items#16907
Merged
Conversation
Five icon names referenced in src/navs/index.js don't exist in @posthog/icons, so the resolver in TaskBarMenu silently rendered no icon for those entries. - IconInbox -> IconNotebook (PostHog Code > Inbox, Support > Inbox management) - IconLayoutDashboard -> IconDashboard (PostHog Code > Command Center) - IconGitFork -> IconGitRepository (PostHog Code > Worktrees) - IconMail -> IconLetter (Support > Email channel) - IconGitHub -> IconGithub (Support > GitHub integration; casing) Generated-By: PostHog Code Task-Id: 680d1cf1-2902-4dca-9b31-1f8546f84152
Contributor
Deploy preview
|
Follow-ups from review: - PostHog Code → Inbox: IconLetter (mail icon, per feedback) - PostHog Code → Command Center: IconGridMasonry (square split into a grid) - Diversify Support → Guides colors (all entries were orange) and swap Slack integration's icon to IconChat to avoid duplicating IconMessage with Widget setup Also fix other docs nav items whose icon names didn't resolve in @posthog/icons: - Product tours → Customize styles: IconColor → IconPalette - Customer analytics → B2B mode: IconCohort → IconGroups - Customer analytics → Create usage metrics: IconG (typo) → IconGraph - Endpoints → Rate limits: IconGauge → IconDashboard And add a fallback in TaskBarMenu/menuData.tsx so icon names that exist only in src/components/OSIcons/Icons.tsx (e.g. IconTag, IconAnthropic, IconOpenAI, IconClaudeCode, IconGemini, IconLangChain, IconOpenRouter, IconOpenClaw) resolve too. PostHog Icons still take precedence so JSX usage like <Icons.IconApps /> is unchanged. Generated-By: PostHog Code Task-Id: 680d1cf1-2902-4dca-9b31-1f8546f84152
Keep the import surface in menuData.tsx unchanged per review feedback. The local-OSIcons-only names (IconTag, IconAnthropic, IconClaudeCode, IconGemini, IconLangChain, IconOpenAI, IconOpenRouter, IconOpenClaw) were already silently failing before this PR and remain a separate problem to solve elsewhere. Generated-By: PostHog Code Task-Id: 680d1cf1-2902-4dca-9b31-1f8546f84152
gewenyu99
approved these changes
May 26, 2026
…aster Master removed the Product Tours product in #16756 (deleted docs, landing page, and nav entries). This branch was still adding back the Product Tours docs sidebar block, causing a merge conflict in src/navs/index.js. Remove both Product Tours entries from src/navs/index.js (the API reference link and the main docs sidebar section) so the three-way merge against master is clean again. Generated-By: PostHog Code Task-Id: c0d6ec58-56fd-41f2-a83d-d098d1ef26cb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
The top navigation was missing icons on a handful of docs menu entries — specifically under PostHog Code → Features and Support → Guides — because the icon names referenced in
src/navs/index.jsdon't exist in the@posthog/iconspackage.menuData.tsxresolves icons viaIcons[item.icon as keyof typeof Icons]and silently renders nothing when the lookup isundefined, which is why the items still showed up with no visible icon.Fixed the following icon names:
IconInboxIconNotebookIconLayoutDashboardIconDashboardIconGitForkIconGitRepositoryIconInboxIconNotebookIconMailIconLetterIconGitHubIconGithub(casing)If anyone has stronger preferences for the replacement icons (esp. for the two "Inbox" entries), happy to swap them — these are the closest matches available in
@posthog/icons@0.36.6.Checklist
vercel.jsonCreated with PostHog Code