print.css 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202
  1. /*!**********************************************************************************************************!*\
  2. !*** css ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js!./scss/print.scss ***!
  3. \**********************************************************************************************************/
  4. @charset "UTF-8";
  5. /* -----------------------/*
  6. * Reset CSS Print "Bretzel"
  7. * Made par Alsacréations
  8. /* ---------------------- */
  9. /*
  10. * Ressources et documentations :
  11. * 1- https://www.docuseal.co/blog/css-print-page-style
  12. * 2- https://www.alsacreations.com/astuce/lire/1160-Une-feuille-de-styles-de-base-pour-le-media-print.html
  13. */
  14. @media print {
  15. /* Dimension et marges de page */
  16. @page {
  17. size: A4 portrait;
  18. margin: 1.5cm 1.5cm;
  19. @bottom-center {
  20. content: "Page " counter(page) " / " counter(pages);
  21. }
  22. }
  23. @page :first {
  24. @top-center {
  25. content: "Titre du document";
  26. font-size: 14pt;
  27. font-weight: bold;
  28. }
  29. }
  30. /* Reset général */
  31. * {
  32. all: unset;
  33. display: revert;
  34. box-sizing: border-box;
  35. }
  36. img {
  37. max-width: 100%;
  38. }
  39. input,
  40. textarea,
  41. select {
  42. all: revert;
  43. }
  44. /* On redéfinit les styles globaux (12pt = 16px) */
  45. body {
  46. width: auto;
  47. margin: 0;
  48. font-family: serif;
  49. font-size: 12pt;
  50. font-family: Georgia, serif;
  51. line-height: 1.5;
  52. color: #000000 !important;
  53. background-color: #ffffff !important;
  54. }
  55. .back-cover {
  56. break-before: page;
  57. margin-top: 55rem;
  58. display: flex;
  59. flex-direction: column;
  60. justify-content: center;
  61. }
  62. .back-cover h2 {
  63. margin-top: 1rem;
  64. color: rgb(9, 57, 139);
  65. font-size: 1.2rem;
  66. }
  67. .back-cover h2 ::before {
  68. content: "";
  69. border-top: 1px solid black;
  70. }
  71. .back-cover .view-id-partenaires .view-content img {
  72. width: 5rem;
  73. height: auto;
  74. }
  75. .back-cover .view-id-partenaires .view-content a[href^=http]:after {
  76. display: none;
  77. }
  78. .back-cover .view-id-partenaires .views-row-wrapper {
  79. display: flex;
  80. flex-direction: row;
  81. flex-wrap: wrap;
  82. }
  83. /* Espacements typographiques (15pt = 20px) */
  84. p,
  85. blockquote,
  86. label,
  87. ul,
  88. ol {
  89. margin-block: 0 15pt;
  90. }
  91. p:last-child {
  92. margin-bottom: 0;
  93. }
  94. /* Titrages (24pt = 32px) */
  95. h1 {
  96. margin-block: 0 24pt;
  97. font-weight: 700;
  98. font-size: 18pt;
  99. line-height: 1.1;
  100. }
  101. h2 {
  102. margin-block: 0 18pt;
  103. font-weight: 700;
  104. font-size: 16pt;
  105. line-height: 1.1;
  106. }
  107. h3 {
  108. margin-block: 0 15pt;
  109. font-weight: 700;
  110. font-size: 14pt;
  111. }
  112. h4 {
  113. margin-block: 0 12pt;
  114. font-weight: 700;
  115. font-size: 12pt;
  116. }
  117. /* Classes dédiées print / no-print */
  118. .print {
  119. display: revert;
  120. }
  121. .no-print {
  122. display: none;
  123. }
  124. /* Pas de veuves ou orphelines (3 lignes minimum) */
  125. p,
  126. blockquote {
  127. orphans: 3;
  128. widows: 3;
  129. }
  130. /* Pas de saut de page au sein de ces éléments */
  131. blockquote,
  132. ul,
  133. ol,
  134. figure,
  135. table,
  136. .paragraph,
  137. footer,
  138. .top_top,
  139. .top_bottom {
  140. page-break-inside: avoid;
  141. }
  142. /* Pas de saut de page après ces éléments */
  143. h1,
  144. h2,
  145. h3,
  146. h4,
  147. caption,
  148. .field--name-field-titre {
  149. page-break-after: avoid;
  150. }
  151. /* Styles des liens */
  152. a,
  153. a:link,
  154. a:visited {
  155. background: transparent !important;
  156. color: unset;
  157. font-weight: 700;
  158. text-decoration: underline !important;
  159. }
  160. /* On affiche l'URL des liens externes */
  161. a[href^=http]:after,
  162. a[href^=https]:after {
  163. content: " (" attr(href) ")";
  164. }
  165. /* On masque les vidéos, header et menu de navigation */
  166. video,
  167. object,
  168. iframe,
  169. header,
  170. nav {
  171. display: none !important;
  172. width: 0 !important;
  173. height: 0 !important;
  174. overflow: hidden !important;
  175. }
  176. /* Style page projet */
  177. .page-node-type-projet .layout__region--top {
  178. width: 100% !important;
  179. padding-top: 0rem !important;
  180. }
  181. .page-node-type-projet .layout__region--top .top_top {
  182. flex-direction: column !important;
  183. }
  184. .page-node-type-projet .layout__region--top .top_top .block-entity-fieldnodefield-photo {
  185. width: 100% !important;
  186. }
  187. .page-node-type-projet .layout__region--top .top_top .slick-dots, .page-node-type-projet .layout__region--top .top_top .slick-arrow {
  188. display: none;
  189. }
  190. .page-node-type-projet .layout__region--top .top_top .top_right {
  191. width: 100% !important;
  192. }
  193. .page-node-type-projet .layout__region--top .top_bottom {
  194. width: 100% !important;
  195. }
  196. .page-node-type-projet .layout__region--first {
  197. display: none;
  198. }
  199. .page-node-type-projet .layout__region--second {
  200. flex: 0 1 100% !important;
  201. }
  202. }