mirror of
https://github.com/astefanutti/decktape.git
synced 2024-09-19 02:17:22 +03:00
Update the RISE plugin to be compatible with version 5.1+
This commit is contained in:
parent
54101bab14
commit
1880d00e7b
@ -1,5 +1,3 @@
|
|||||||
const { pause } = require('../libs/util');
|
|
||||||
|
|
||||||
exports.create = page => new RISE(page);
|
exports.create = page => new RISE(page);
|
||||||
|
|
||||||
class RISE {
|
class RISE {
|
||||||
@ -13,15 +11,15 @@ class RISE {
|
|||||||
}
|
}
|
||||||
|
|
||||||
isActive() {
|
isActive() {
|
||||||
return this.page.evaluate(_ => typeof $ !== 'undefined' && $('#start_livereveal').length)
|
return this.page.evaluate(_ => typeof $ !== 'undefined' && $('#RISE').length);
|
||||||
}
|
}
|
||||||
|
|
||||||
async configure() {
|
async configure() {
|
||||||
// Wait until the RISE extension has loaded
|
// Wait until the RISE extension has loaded
|
||||||
await this.page.waitForSelector('#start_livereveal', { timeout: 30000 });
|
await this.page.waitForSelector('#RISE', { timeout: 30000 });
|
||||||
// Click on the 'Enter/Exit Live Reveal Slideshow' button in the notebook toolbar
|
// Click on the 'Enter/Exit Live Reveal Slideshow' button in the notebook toolbar
|
||||||
await this.page.evaluate(_ => {
|
await this.page.evaluate(_ => {
|
||||||
$('#start_livereveal').click();
|
$('#RISE').click();
|
||||||
$('#help_b, #exit_b').fadeToggle();
|
$('#help_b, #exit_b').fadeToggle();
|
||||||
});
|
});
|
||||||
// Then wait until Reveal.js gets configured by the RISE extension
|
// Then wait until Reveal.js gets configured by the RISE extension
|
||||||
|
Loading…
Reference in New Issue
Block a user