Skip to content

Implemented print media queries for better PDF layout #3170

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
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
5 changes: 5 additions & 0 deletions client/components/RootPage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ const RootPage = styled.div`
height: 100%;
overflow: hidden;
}
@media print {
@page {
page-orientation: landscape;
}
}
`;

export default RootPage;
3 changes: 3 additions & 0 deletions client/modules/User/components/CookieConsent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ const CookieConsentContainer = styled.div`
left: 0;
right: 0;
z-index: 9999;
@media print {
display: none;
}
`;

const CookieConsentDialog = styled.div`
Expand Down
24 changes: 24 additions & 0 deletions client/styles/layout/_ide.scss
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,27 @@
width: 100%;
height: 100%;
}

@media print {
.sidebar {
display: none;
width: 0;
}
.preview-console {
display: none;
}
.CodeMirror {
height: auto;
overflow: visible;
position: relative;
}
.CodeMirror-scroll {
height: auto;
overflow-y: hidden;
}
.CodeMirror-vscrollbar,
.CodeMirror-hscrollbar,
.CodeMirror-gutters {
display: none;
}
}
Loading