seitime-frappe/frappe/templates/styles/standard.css
Anand Doshi 0a9a654ccd [fix] avoid overlapping text and breaking row text in wkhtmltopdf output
- Disable header row repeat for webkit browsers
- Avoid page break within td > div
2015-09-08 12:59:42 +05:30

99 lines
1.6 KiB
CSS

@media screen {
.print-format-gutter {
background-color: #ddd;
padding: 15px 0px;
}
.print-format {
background-color: white;
box-shadow: 0px 0px 9px rgba(0,0,0,0.5);
max-width: 8.3in;
min-height: 11.69in;
padding: 0.75in;
margin: auto;
}
.page-break {
padding: 30px 0px;
border-bottom: 1px dashed #888;
}
.page-break:first-child {
padding-top: 0px;
}
.page-break:last-child {
border-bottom: 0px;
}
/* mozilla hack for images in table */
body:last-child .print-format td img {
width: 100% !important;
}
}
@media print {
.print-format p {
margin-left: 1px;
margin-right: 1px;
}
}
.print-format {
font-size: {{ print_settings.font_size|flt or 9 }}pt;
font-family: {{ font }};
-webkit-print-color-adjust:exact;
}
.page-break {
page-break-after: always;
}
.print-heading {
border-bottom: 2px solid #aaa;
margin-bottom: 10px;
}
.print-heading h2 {
margin: 0px;
}
.print-heading h4 {
margin-top: 5px;
}
table.no-border, table.no-border td {
border: 0px;
}
.print-format label {
/* wkhtmltopdf breaks label into multiple lines when it is inline-block */
display: block;
}
.print-format img {
max-width: 100%;
}
.print-format table td > .primary:first-child {
font-weight: bold;
}
.print-format td, .print-format th {
vertical-align: top !important;
padding: 6px !important;
}
.print-format p {
margin: 3px 0px 3px;
}
table td div {
/* needed to avoid partial cutting of text between page break in wkhtmltopdf */
page-break-inside: avoid !important;
}
/* hack for webkit specific browser */
@media (-webkit-min-device-pixel-ratio:0) {
thead, tfoot { display: table-row-group; }
}