1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-25 00:07:47 +01:00

feat: view diff in change requests (#8852)

This commit is contained in:
Mateusz Kwasniewski 2024-11-26 09:28:17 +01:00 committed by GitHub
parent 1990ede59f
commit 90440c0439
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -69,6 +69,11 @@ const StyledContainer: FC<{ children?: React.ReactNode }> = styled('div')(
}),
);
const ViewDiff = styled('span')(({ theme }) => ({
color: theme.palette.primary.main,
marginLeft: theme.spacing(1),
}));
const Truncated = styled('div')(() => ({
...textTruncated,
maxWidth: 500,
@ -82,6 +87,9 @@ export const StrategyTooltipLink: FC<IStrategyTooltipLinkProps> = ({
<StyledContainer>
<GetFeatureStrategyIcon strategyName={change.payload.name} />
<Truncated>
<Typography component='span'>
{formatStrategyName(change.payload.name)}
</Typography>
<TooltipLink
tooltip={children}
tooltipProps={{
@ -89,9 +97,7 @@ export const StrategyTooltipLink: FC<IStrategyTooltipLinkProps> = ({
maxHeight: 600,
}}
>
<Typography component='span'>
{formatStrategyName(change.payload.name)}
</Typography>
<ViewDiff>View Diff</ViewDiff>
</TooltipLink>
<NameWithChangeInfo
newName={change.payload.title}