Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -107,47 +107,45 @@ export default function ReplayDetailsPageBreadcrumbs({readerResult}: Props) {
onMouseLeave={() => setIsHovered(false)}
>
{organization.features.includes('replay-playlist-view') && (
<Flex>
<ButtonBar merged gap="0">
<LinkButton
size="xs"
icon={<IconPrevious />}
disabled={!previousReplay}
to={{
pathname: previousReplay
? makeReplaysPathname({
path: `/${previousReplay.id}/`,
organization,
})
: undefined,
query: initialLocation.current.query,
}}
onClick={() =>
trackAnalytics('replay.details-playlist-clicked', {
direction: 'previous',
organization,
})
}
/>
<LinkButton
size="xs"
icon={<IconNext />}
disabled={!nextReplay}
to={{
pathname: nextReplay
? makeReplaysPathname({path: `/${nextReplay.id}/`, organization})
: undefined,
query: initialLocation.current.query,
}}
onClick={() =>
trackAnalytics('replay.details-playlist-clicked', {
direction: 'next',
organization,
})
}
/>
</ButtonBar>
</Flex>
<StyledButtonBar merged gap="0">
<LinkButton
size="xs"
icon={<IconPrevious />}
disabled={!previousReplay}
to={{
pathname: previousReplay
? makeReplaysPathname({
path: `/${previousReplay.id}/`,
organization,
})
: undefined,
query: initialLocation.current.query,
}}
onClick={() =>
trackAnalytics('replay.details-playlist-clicked', {
direction: 'previous',
organization,
})
}
/>
<LinkButton
size="xs"
icon={<IconNext />}
disabled={!nextReplay}
to={{
pathname: nextReplay
? makeReplaysPathname({path: `/${nextReplay.id}/`, organization})
: undefined,
query: initialLocation.current.query,
}}
onClick={() =>
trackAnalytics('replay.details-playlist-clicked', {
direction: 'next',
organization,
})
}
/>
</StyledButtonBar>
)}
<ShortId
onClick={() =>
Expand Down Expand Up @@ -195,3 +193,9 @@ const StyledBreadcrumbs = styled(Breadcrumbs)`
const ShortId = styled('div')`
margin-left: 10px;
`;

// Breadcrumbs have overflow: hidden, so we need to set the margin-top to 2px
// to avoid the buttons from being cut off.
const StyledButtonBar = styled(ButtonBar)`
margin-top: 2px;
`;
Loading