diff --git a/lib/index.js b/lib/index.js index 7e36978..1748128 100644 --- a/lib/index.js +++ b/lib/index.js @@ -212,11 +212,14 @@ Cleaver.prototype.loadStaticAssets = function () { Cleaver.prototype.renderSlideshow = function () { var putControls = this.options.controls || (this.options.controls === undefined); var putProgress = this.options.progress || (this.options.progress === undefined); + var options = Object.assign({}, this.options, { controls: putControls, progress: putProgress }); + var style, script, output; // Render the slides in a template (maybe as specified by the user) var slideshow = mustache.render(this.templates.loaded.slides, { slides: this.slides, + options: options, controls: putControls, progress: putProgress }); @@ -255,7 +258,7 @@ Cleaver.prototype.renderSlideshow = function () { style: style, author: this.options.author, script: script, - options: this.options + options: options }; /* Return the rendered slideshow */ diff --git a/templates/default.mustache b/templates/default.mustache index 1d0208f..55dc19f 100644 --- a/templates/default.mustache +++ b/templates/default.mustache @@ -1,8 +1,8 @@ -{{#progress}} +{{#options.progress}}