pdf.scss 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  1. /**
  2. * This stylesheet is used to print reveal.js
  3. * presentations to PDF.
  4. *
  5. * https://revealjs.com/pdf-export/
  6. */
  7. html.print-pdf {
  8. * {
  9. -webkit-print-color-adjust: exact;
  10. }
  11. & {
  12. width: 100%;
  13. height: 100%;
  14. overflow: visible;
  15. }
  16. body {
  17. margin: 0 auto !important;
  18. border: 0;
  19. padding: 0;
  20. float: none !important;
  21. overflow: visible;
  22. }
  23. /* Remove any elements not needed in print. */
  24. .nestedarrow,
  25. .reveal .controls,
  26. .reveal .progress,
  27. .reveal .playback,
  28. .reveal.overview,
  29. .state-background {
  30. display: none !important;
  31. }
  32. .reveal pre code {
  33. overflow: hidden !important;
  34. font-family: Courier, 'Courier New', monospace !important;
  35. }
  36. .reveal {
  37. width: auto !important;
  38. height: auto !important;
  39. overflow: hidden !important;
  40. }
  41. .reveal .slides {
  42. position: static;
  43. width: 100% !important;
  44. height: auto !important;
  45. zoom: 1 !important;
  46. pointer-events: initial;
  47. left: auto;
  48. top: auto;
  49. margin: 0 !important;
  50. padding: 0 !important;
  51. overflow: visible;
  52. display: block;
  53. perspective: none;
  54. perspective-origin: 50% 50%;
  55. }
  56. .reveal .slides .pdf-page {
  57. position: relative;
  58. overflow: hidden;
  59. z-index: 1;
  60. page-break-after: always;
  61. }
  62. .reveal .slides section {
  63. visibility: visible !important;
  64. display: block !important;
  65. position: absolute !important;
  66. margin: 0 !important;
  67. padding: 0 !important;
  68. box-sizing: border-box !important;
  69. min-height: 1px;
  70. opacity: 1 !important;
  71. transform-style: flat !important;
  72. transform: none !important;
  73. }
  74. .reveal section.stack {
  75. position: relative !important;
  76. margin: 0 !important;
  77. padding: 0 !important;
  78. page-break-after: avoid !important;
  79. height: auto !important;
  80. min-height: auto !important;
  81. }
  82. .reveal img {
  83. box-shadow: none;
  84. }
  85. /* Slide backgrounds are placed inside of their slide when exporting to PDF */
  86. .reveal .backgrounds {
  87. display: none;
  88. }
  89. .reveal .slide-background {
  90. display: block !important;
  91. position: absolute;
  92. top: 0;
  93. left: 0;
  94. width: 100%;
  95. height: 100%;
  96. z-index: auto !important;
  97. }
  98. /* Display slide speaker notes when 'showNotes' is enabled */
  99. .reveal.show-notes {
  100. max-width: none;
  101. max-height: none;
  102. }
  103. .reveal .speaker-notes-pdf {
  104. display: block;
  105. width: 100%;
  106. height: auto;
  107. max-height: none;
  108. top: auto;
  109. right: auto;
  110. bottom: auto;
  111. left: auto;
  112. z-index: 100;
  113. }
  114. /* Layout option which makes notes appear on a separate page */
  115. .reveal .speaker-notes-pdf[data-layout="separate-page"] {
  116. position: relative;
  117. color: inherit;
  118. background-color: transparent;
  119. padding: 20px;
  120. page-break-after: always;
  121. border: 0;
  122. }
  123. /* Display slide numbers when 'slideNumber' is enabled */
  124. .reveal .slide-number-pdf {
  125. display: block;
  126. position: absolute;
  127. font-size: 14px;
  128. }
  129. /* This accessibility tool is not useful in PDF and breaks it visually */
  130. .aria-status {
  131. display: none;
  132. }
  133. }