import {TabList, Tabs} from 'sentry/components/tabs'; import {useLocation} from 'sentry/utils/useLocation'; import useOrganization from 'sentry/utils/useOrganization'; import {normalizeUrl} from 'sentry/utils/withDomainRequired'; interface Props { selected: 'replays' | 'selectors'; } const SELECTOR_IDX_ROUTE = 'selectors/'; const REPLAY_IDX_ROUTE = ''; const TABS = [ {key: 'replays', label: 'Replays', to: REPLAY_IDX_ROUTE}, {key: 'selectors', label: 'Selectors', to: SELECTOR_IDX_ROUTE}, ]; export default function ReplayTabs({selected}: Props) { const organization = useOrganization(); const hasDeadClickFeature = organization.features.includes( 'session-replay-rage-dead-selectors' ); const location = useLocation(); return hasDeadClickFeature ? ( {TABS.map(tab => ( {tab.label} ))} ) : null; }