print notes to pdf when is enabled #304

edit
Hakim El Hattab 2015-09-10 08:50:55 +02:00
parent 0338f280d3
commit b0b2ce1fe3
4 changed files with 25 additions and 1 deletions

View File

@ -61,6 +61,14 @@ h1,h2,h3,h4,h5,h6 {
font-family: Courier, 'Courier New', monospace !important;
}
.reveal .speaker-notes {
display: block;
width: 100%;
max-height: none;
left: auto;
top: auto;
}
/* SECTION 5: more reveal.js specific additions by @skypanther */
ul, ol, div, p {

View File

@ -1178,7 +1178,9 @@ body {
background-color: rgba(0, 0, 0, 0.5);
overflow: auto;
-moz-box-sizing: border-box;
box-sizing: border-box; }
box-sizing: border-box;
text-align: left;
font-family: Helvetica, sans-serif; }
.reveal .speaker-notes.visible:not(:empty) {
display: block; }

View File

@ -1314,6 +1314,8 @@ body {
background-color: rgba(0,0,0,0.5);
overflow: auto;
box-sizing: border-box;
text-align: left;
font-family: Helvetica, sans-serif;
}
.reveal .speaker-notes.visible:not(:empty) {

View File

@ -573,6 +573,18 @@
background.style.top = -top + 'px';
background.style.left = -left + 'px';
}
// If we're configured to `showNotes`, inject them into each slide
if( config.showNotes ) {
var notes = getSlideNotes( slide );
if( notes ) {
var notesElement = document.createElement( 'div' );
notesElement.classList.add( 'speaker-notes' );
notesElement.innerHTML = notes;
notesElement.style.bottom = 40 - ( ( pageHeight - contentHeight ) / 2 ) + 'px';
slide.appendChild( notesElement );
}
}
}
} );