: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.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
import type { MessagingNavTabKey } from './messagingTabs'
import { QuillNewCategoryButton } from './QuillNewCategoryButton'
import { QuillNewChannelButton } from './QuillNewChannelButton'
import { QuillNewTemplateButton } from './QuillNewTemplateButton'
export function QuillMessagingTabActions({
tab,
channelsUrl,
}: {
tab: MessagingNavTabKey
channelsUrl: string
}): JSX.Element | null {
// One component per action, so a tab mounts (and loads) only the logic its own button needs.
if (tab === 'library') {
return <QuillNewTemplateButton />
}
if (tab === 'channels') {
return <QuillNewChannelButton channelsUrl={channelsUrl} />
}
if (tab === 'opt-outs') {
return <QuillNewCategoryButton />
}
return null
}