fix: page title support click to reload

This commit is contained in:
alt0
2022-09-28 15:30:57 +08:00
parent 287e6ff1c4
commit 7c5de7b20c
2 changed files with 13 additions and 2 deletions
@@ -121,7 +121,7 @@ const StyledHeaderRoot = styled('div')(({ theme }) => {
};
});
const FlexContainer = styled('div')({ display: 'flex' });
const FlexContainer = styled('div')({ display: 'flex', alignItems: 'center' });
const TitleContainer = styled('div')(({ theme }) => {
return {
+12 -1
View File
@@ -72,7 +72,11 @@ export const CurrentPageTitle = () => {
}, [pageTitle]);
return pageTitle ? (
<ContentText type="sm" title={pageTitle}>
<ContentText
type="sm"
onClick={() => window.location.reload()}
title={pageTitle}
>
{pageTitle}
</ContentText>
) : null;
@@ -85,5 +89,12 @@ const ContentText = styled(Typography)(({ theme }) => {
overflow: 'hidden',
textOverflow: 'ellipsis',
whiteSpace: 'nowrap',
padding: '6px 12px',
cursor: 'pointer',
borderRadius: '5px',
'&:hover': {
backgroundColor: '#F5F7F8',
},
};
});