Skip to content

Commit d497382

Browse files
authored
Merge pull request #3170 from Chaitanya1672/fix/addition-print-pdf-default-size
Implemented print media queries for better PDF layout
2 parents 8abd78c + 37e8258 commit d497382

File tree

3 files changed

+32
-0
lines changed

3 files changed

+32
-0
lines changed

client/components/RootPage.jsx

+5
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ const RootPage = styled.div`
1414
height: 100%;
1515
overflow: hidden;
1616
}
17+
@media print {
18+
@page {
19+
page-orientation: landscape;
20+
}
21+
}
1722
`;
1823

1924
export default RootPage;

client/modules/User/components/CookieConsent.jsx

+3
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ const CookieConsentContainer = styled.div`
2525
left: 0;
2626
right: 0;
2727
z-index: 9999;
28+
@media print {
29+
display: none;
30+
}
2831
`;
2932

3033
const CookieConsentDialog = styled.div`

client/styles/layout/_ide.scss

+24
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,27 @@
2020
width: 100%;
2121
height: 100%;
2222
}
23+
24+
@media print {
25+
.sidebar {
26+
display: none;
27+
width: 0;
28+
}
29+
.preview-console {
30+
display: none;
31+
}
32+
.CodeMirror {
33+
height: auto;
34+
overflow: visible;
35+
position: relative;
36+
}
37+
.CodeMirror-scroll {
38+
height: auto;
39+
overflow-y: hidden;
40+
}
41+
.CodeMirror-vscrollbar,
42+
.CodeMirror-hscrollbar,
43+
.CodeMirror-gutters {
44+
display: none;
45+
}
46+
}

0 commit comments

Comments
 (0)