]> BookStack Code Mirror - bookstack/blob - resources/sass/export-styles.scss
Fixed permission row permission check
[bookstack] / resources / sass / export-styles.scss
1 @use "sass:math";
2 @import "variables";
3 @import "mixins";
4 @import "html";
5 @import "text";
6 @import "layout";
7 @import "blocks";
8 @import "tables";
9 @import "lists";
10 @import "pages";
11
12 html, body {
13   background-color: #FFF;
14 }
15
16 body {
17   font-family: 'DejaVu Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", "Oxygen", "Ubuntu", "Roboto", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
18   margin: 0;
19   padding: 0;
20   display: block;
21 }
22
23 table {
24   border-spacing: 0;
25   border-collapse: collapse;
26 }
27
28 .page-content {
29   overflow: hidden;
30 }
31
32 // Prevent code block overflow on export
33 pre {
34   padding-left: 12px;
35 }
36 pre:after {
37   display: none;
38 }
39 pre code {
40   white-space: pre-wrap;
41 }
42
43 .page-break {
44   page-break-after: always;
45 }
46 @media screen {
47   .page-break {
48     border-top: 1px solid #DDD;
49   }
50 }
51
52 ul.contents ul li {
53   list-style: circle;
54 }
55
56 .chapter-hint {
57   color: #888;
58   margin-top: 32px;
59 }
60 .chapter-hint + h1 {
61   margin-top: 0;
62 }
63
64 // PDF specific overrides
65 body.export-format-pdf {
66   font-size: 14px;
67   line-height: 1.2;
68
69   h1, h2, h3, h4, h5, h6 {
70     line-height: 1.2;
71   }
72
73   table {
74     max-width: 800px !important;
75     font-size: 0.8em;
76     width: 100% !important;
77   }
78
79   table td {
80     width: auto !important;
81   }
82
83   .page-content .float {
84     float: none !important;
85   }
86
87   .page-content img.align-left, .page-content img.align-right  {
88     float: none !important;
89     clear: both;
90     display: block;
91   }
92
93 }
94
95 // DOMPDF pdf export specific overrides
96 body.export-format-pdf.export-engine-dompdf {
97   // Fix for full width linked image sizes on DOMPDF
98   .page-content a > img {
99     max-width: 700px;
100   }
101   // Undoes the above for table images to prevent visually worse scenario, Awaiting next DOMPDF release for patch
102   .page-content td a > img {
103     max-width: 100%;
104   }
105 }