2020-02-15 10:34:06 -05:00
|
|
|
<style>
|
|
|
|
@if (!app()->environment('testing'))
|
|
|
|
{!! file_get_contents(public_path('/dist/export-styles.css')) !!}
|
|
|
|
@endif
|
|
|
|
</style>
|
|
|
|
|
|
|
|
@if ($format === 'pdf')
|
|
|
|
<style>
|
2021-05-04 18:15:05 -04:00
|
|
|
|
|
|
|
/* PDF size adjustments */
|
|
|
|
body {
|
|
|
|
font-size: 14px;
|
|
|
|
line-height: 1.2;
|
|
|
|
}
|
|
|
|
|
|
|
|
h1, h2, h3, h4, h5, h6 {
|
|
|
|
line-height: 1.2;
|
|
|
|
}
|
|
|
|
|
|
|
|
table {
|
|
|
|
max-width: 800px !important;
|
|
|
|
font-size: 0.8em;
|
|
|
|
width: 100% !important;
|
|
|
|
}
|
|
|
|
|
|
|
|
table td {
|
|
|
|
width: auto !important;
|
|
|
|
}
|
|
|
|
|
2020-02-15 10:34:06 -05:00
|
|
|
/* Patches for CSS variable colors */
|
|
|
|
a {
|
|
|
|
color: {{ setting('app-color') }};
|
|
|
|
}
|
|
|
|
|
|
|
|
blockquote {
|
|
|
|
border-left-color: {{ setting('app-color') }};
|
|
|
|
}
|
|
|
|
|
|
|
|
/* Patches for content layout */
|
|
|
|
.page-content .float {
|
|
|
|
float: none !important;
|
|
|
|
}
|
|
|
|
|
|
|
|
.page-content img.align-left, .page-content img.align-right {
|
|
|
|
float: none !important;
|
|
|
|
clear: both;
|
|
|
|
display: block;
|
|
|
|
}
|
2022-01-01 13:18:37 -05:00
|
|
|
|
2022-01-24 12:24:00 -05:00
|
|
|
@if($engine === \BookStack\Entities\Tools\PdfGenerator::ENGINE_DOMPDF)
|
|
|
|
{{-- Fix for full width linked image sizes on DOMPDF --}}
|
2022-01-01 13:18:37 -05:00
|
|
|
.page-content a > img {
|
2022-01-24 12:24:00 -05:00
|
|
|
max-width: 700px;
|
2022-01-01 13:18:37 -05:00
|
|
|
}
|
2022-01-24 12:24:00 -05:00
|
|
|
{{-- Undoes the above for table images to prevent visually worse scenario, Awaiting next DOMPDF release for patch --}}
|
|
|
|
.page-content td a > img {
|
|
|
|
max-width: 100%;
|
|
|
|
}
|
|
|
|
@endif
|
2020-02-15 10:34:06 -05:00
|
|
|
</style>
|
|
|
|
@endif
|