Render reader desktop nav bar content only when visible

This commit is contained in:
schroda
2024-12-21 15:36:47 +01:00
parent 948e2564fa
commit f141a5ae66

View File

@@ -106,6 +106,8 @@ const BaseReaderNavBarDesktop = ({
}}
>
<ReaderNavContainer sx={{ backgroundColor: 'background.paper', pointerEvents: 'all' }}>
{isVisible && (
<>
<Stack sx={{ p: 2, gap: 2, backgroundColor: 'action.hover' }}>
<Stack sx={{ flexDirection: 'row', justifyContent: 'space-between', alignItems: 'center' }}>
<Tooltip title={t('reader.button.exit')}>
@@ -152,6 +154,8 @@ const BaseReaderNavBarDesktop = ({
<Divider />
<ReaderNavBarDesktopQuickSettings openSettings={openSettings} />
</Stack>
</>
)}
</ReaderNavContainer>
</Drawer>
);