Files
d9-eql/web/themes/custom/eql/scss/global/_print.scss
T
2025-12-16 12:13:43 +01:00

111 lines
2.3 KiB
SCSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/* -------------------------
Paged.js : format + compteur
-------------------------- */
@page {
size: A4 portrait;
margin: 1.5cm;
@bottom-center {
content: "Page " counter(page) " / " counter(pages);
font-size: 9pt;
}
}
/* Pas de numéro sur cover / back-cover */
.cover { page: cover; }
.back-cover { page: backcover; }
@page cover { @bottom-center { content: none; } }
@page backcover { @bottom-center { content: none; } }
/* -------------------------
PRINT (Ctrl+P)
-------------------------- */
@media print {
/* Cache lUI du site */
header[role="banner"],
footer[role="contentinfo"],
nav,
.slick-arrow,
.slick-dots,
.layout__region--first{
display: none !important;
}
.layout__region--top{
flex: 0 1 100% !important;
.block-entity-fieldnodefield-photo,
.top_right{
width: 100% !important;
}
}
.top_top{
flex-direction: column !important;
}
.layout__region--second{
flex: 0 1 100% !important;
margin: auto;
margin-left: 3rem;
}
/* Cover */
.cover.print-only {
display: flex !important;
min-height: 100vh;
align-items: center;
justify-content: center;
text-align: center;
break-after: page;
}
/* Back cover */
.back-cover.print-only {
break-before: page;
.views-row-wrapper{
display: flex;
flex-direction: row;
flex-wrap: wrap;
}
}
/* Optionnel : éviter lURL après liens sur la cover */
.cover.print-only a[href^="http"]::after,
.cover.print-only a[href^="https"]::after {
content: "" !important;
}
}
/* -------------------------
SCREEN preview (Paged.js)
-------------------------- */
@media screen {
/* En écran normal : cacher print-only */
body:not(.use-paged) .print-only { display: none !important; }
/* Fond et affichage pages */
body.use-paged { background: #ddd; }
body.use-paged .pagedjs_pages {
width: 100%;
padding: 2rem 0;
}
body.use-paged .pagedjs_page {
margin: 1rem auto;
background: #fff;
box-shadow: 0 0 0 1px rgba(0,0,0,.35);
}
body.use-paged .pagedjs_pagebox {
width: 210mm;
min-height: 297mm;
margin: 0 auto;
background: #fff;
}
/* Paged.js met le contenu dans .pagedjs_page_content : on évite les surprises */
body.use-paged .pagedjs_page_content {
display: block;
}
}