Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

feat(inbox): add Beta tag to Inbox navbar item (#64879)

Michael Matlokada754d4ec352
diff --git a/frontend/src/layout/panel-layout/ai-first/NavLink.tsx b/frontend/src/layout/panel-layout/ai-first/NavLink.tsx
index 2d905e665f68..cd688a3d8aa1 100644
--- a/frontend/src/layout/panel-layout/ai-first/NavLink.tsx
+++ b/frontend/src/layout/panel-layout/ai-first/NavLink.tsx
@@ -1,6 +1,7 @@
import { useValues } from 'kea'
import { IconGear } from '@posthog/icons'
+import { LemonTag } from '@posthog/lemon-ui'
import { Link } from 'lib/lemon-ui/Link'
import { ButtonGroupPrimitive, ButtonPrimitive } from 'lib/ui/Button/ButtonPrimitives'
@@ -23,6 +24,7 @@ interface NavLinkProps {
'data-attr'?: string
onClick?: (e: React.MouseEvent) => void
sideAction?: NavLinkSideAction
+ tag?: 'alpha' | 'beta' | 'new'
}
export function NavLink({
@@ -33,6 +35,7 @@ export function NavLink({
'data-attr': dataAttr,
onClick,
sideAction,
+ tag,
}: NavLinkProps): JSX.Element {
const { pathname } = useValues(panelLayoutLogic)
@@ -78,6 +81,15 @@ export function NavLink({
{label}
</span>
)}
+ {!isCollapsed && tag && (
+ <LemonTag
+ type={tag === 'alpha' ? 'completion' : tag === 'beta' ? 'warning' : 'success'}
+ size="small"
+ className="relative top-[-1px]"
+ >
+ {tag.toUpperCase()}
+ </LemonTag>
+ )}
</Link>
{hasSideActionRight && sideAction && (
<ButtonPrimitive
diff --git a/frontend/src/layout/panel-layout/ai-first/tabs/NavTabBrowse.tsx b/frontend/src/layout/panel-layout/ai-first/tabs/NavTabBrowse.tsx
index 105441cb1bd9..fd5b4ba54c2e 100644
--- a/frontend/src/layout/panel-layout/ai-first/tabs/NavTabBrowse.tsx
+++ b/frontend/src/layout/panel-layout/ai-first/tabs/NavTabBrowse.tsx
@@ -229,6 +229,7 @@ export function NavTabBrowse(): JSX.Element {
icon={<IconNotification />}
isCollapsed={isLayoutNavCollapsed}
data-attr="nav-item-inbox"
+ tag="beta"
onClick={() => posthog.capture('nav item clicked', { item: 'inbox' })}
/>
)}