Skip to content

Commit 701d4bb

Browse files
authored
fix: Present mode slide content not vertically centered (outline#11901)
* fix: Present mode slide content not vertically centered
1 parent 032d5c6 commit 701d4bb

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

app/scenes/Document/components/PresentationMode.tsx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ function PresentationMode({ title, icon, iconColor, data, onClose }: Props) {
256256
}
257257

258258
const availableWidth = container.clientWidth - 160;
259-
const availableHeight = container.clientHeight - 48 - 160;
259+
const availableHeight = container.clientHeight - 160;
260260
const scaleX = availableWidth / width;
261261
const scaleY = availableHeight / height;
262262
const newScale = Math.min(scaleX, scaleY, 1.5);
@@ -454,8 +454,13 @@ const TopBar = styled.div<{ $idle: boolean }>`
454454
align-items: center;
455455
justify-content: center;
456456
padding: 16px;
457-
position: relative;
457+
position: absolute;
458+
top: 0;
459+
left: 0;
460+
right: 0;
461+
z-index: 1;
458462
opacity: ${(props) => (props.$idle ? 0 : 1)};
463+
pointer-events: ${(props) => (props.$idle ? "none" : "auto")};
459464
transition: opacity 300ms ease;
460465
`;
461466

0 commit comments

Comments
 (0)