remove extra padding in stacks, add api method to retrieve curren scale (#310)
parent
723bd1cc0b
commit
c50ae08fe0
|
@ -592,6 +592,11 @@ body {
|
||||||
top: -50%;
|
top: -50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.reveal .slides>section.stack {
|
||||||
|
padding-top: 0;
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.reveal .slides>section.present,
|
.reveal .slides>section.present,
|
||||||
.reveal .slides>section>section.present {
|
.reveal .slides>section>section.present {
|
||||||
display: block;
|
display: block;
|
||||||
|
|
File diff suppressed because one or more lines are too long
10
js/reveal.js
10
js/reveal.js
|
@ -94,6 +94,9 @@ var Reveal = (function(){
|
||||||
// all current slides.
|
// all current slides.
|
||||||
state = [],
|
state = [],
|
||||||
|
|
||||||
|
// The current scale of the presentation (see width/height config)
|
||||||
|
scale = 1,
|
||||||
|
|
||||||
// Cached references to DOM elements
|
// Cached references to DOM elements
|
||||||
dom = {},
|
dom = {},
|
||||||
|
|
||||||
|
@ -591,7 +594,7 @@ var Reveal = (function(){
|
||||||
dom.slides.style.height = slideHeight + 'px';
|
dom.slides.style.height = slideHeight + 'px';
|
||||||
|
|
||||||
// Determine scale of content to fit within available space
|
// Determine scale of content to fit within available space
|
||||||
var scale = Math.min( availableWidth / slideWidth, availableHeight / slideHeight );
|
scale = Math.min( availableWidth / slideWidth, availableHeight / slideHeight );
|
||||||
|
|
||||||
// Respect max/min scale settings
|
// Respect max/min scale settings
|
||||||
scale = Math.max( scale, config.minScale );
|
scale = Math.max( scale, config.minScale );
|
||||||
|
@ -1835,6 +1838,11 @@ var Reveal = (function(){
|
||||||
return currentSlide;
|
return currentSlide;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// Returns the current scale of the presentation content
|
||||||
|
getScale: function() {
|
||||||
|
return scale;
|
||||||
|
},
|
||||||
|
|
||||||
// Helper method, retrieves query string as a key/value hash
|
// Helper method, retrieves query string as a key/value hash
|
||||||
getQueryHash: function() {
|
getQueryHash: function() {
|
||||||
var query = {};
|
var query = {};
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue