mirror of
https://github.com/astefanutti/decktape.git
synced 2025-01-05 21:23:15 +03:00
Improve reveal.js plugin detection message for reveal.js version < 2.3.0
This commit is contained in:
parent
199401a4cc
commit
d48327b916
@ -61,6 +61,11 @@ page.onLoadFinished = function(status) {
|
||||
console.log("Loading page finished with status: " + status);
|
||||
};
|
||||
|
||||
// Must be set before the page is opened
|
||||
page.onConsoleMessage = function(msg) {
|
||||
console.log(msg);
|
||||
};
|
||||
|
||||
page.open(opts.url, function(status) {
|
||||
if (status !== "success") {
|
||||
console.log("Unable to load the address: " + opts.url);
|
||||
@ -69,7 +74,7 @@ page.open(opts.url, function(status) {
|
||||
var plugin = detectActivePlugin();
|
||||
if (!plugin) {
|
||||
// TODO: backend fallback manual support
|
||||
console.log("No DeckTape plugin supported for the address:" + opts.url);
|
||||
console.log("No DeckTape plugin supported for the address: " + opts.url);
|
||||
phantom.exit(1);
|
||||
}
|
||||
console.log(plugin.getName() + " DeckTape plugin activated");
|
||||
|
@ -8,7 +8,15 @@ Reveal.prototype = {
|
||||
},
|
||||
|
||||
isActive : function() {
|
||||
return typeof Reveal !== "undefined";
|
||||
if (typeof Reveal === "undefined")
|
||||
return false;
|
||||
|
||||
if (!(typeof Reveal.isLastSlide === "function")) {
|
||||
console.log("Reveal JS plugin isn't compatible with reveal.js version < 2.3.0");
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
},
|
||||
|
||||
configure : function() {
|
||||
|
Loading…
Reference in New Issue
Block a user