Skip to content

Commit

Permalink
Improving print media styling
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilmielnik committed Jul 26, 2017
1 parent 3e08b81 commit c36b396
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 12 deletions.
1 change: 0 additions & 1 deletion src/components/button/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
text-align: center;
white-space: nowrap;
letter-spacing: 1px;
box-shadow: 0px 0px 5px 1px grey;
cursor: pointer;
user-select: none;

Expand Down
3 changes: 3 additions & 0 deletions src/components/page/styles.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
.page {
width: 210mm;
height: 297mm;
padding: 20mm;
box-sizing: border-box;
background: white;
box-shadow: 0px 0px 5px 2px grey;
Expand Down
10 changes: 1 addition & 9 deletions src/components/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,26 +6,18 @@

.page {
margin: 20px auto;
padding: 20mm;
height: 100%;

.buttons {
position: absolute;
left: calc(100% + 20mm);
top: 80px;
z-index: -1;

.button {
margin-bottom: 10px;

&.download-pdf {
top: 20px;
}
}
}

@media screen and (max-width: 1030px) {
.buttons {
@media screen and (max-width: 1030px) {
display: none;
}
}
Expand Down
9 changes: 7 additions & 2 deletions src/styles.scss
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
html, body {
margin: 0 auto;
padding: 0;
width: 210mm;
height: 285mm;
background: #ccc;
box-sizing: border-box;
font-family: 'Open Sans', sans-serif;
font-size: 13px;
line-height: 1.45;

@media print {
overflow: hidden;
background: white;
}
}

@page {
size: A4;
margin: 0;
}

a {
text-decoration: none;
cursor: pointer;
Expand Down

0 comments on commit c36b396

Please sign in to comment.