mirror of
https://github.com/astefanutti/decktape.git
synced 2025-01-05 21:23:15 +03:00
Add CSSS plugin and example
This commit is contained in:
parent
d79fdd38f8
commit
47868fa434
@ -4,7 +4,7 @@ DeckTape is a high-quality PDF exporter for HTML5 presentation frameworks. It su
|
||||
|
||||
DeckTape is built on top of [PhantomJS](http://phantomjs.org) which relies on [WebKit Qt](https://wiki.qt.io/Qt_WebKit) for laying out and rendering Web pages and provides a headless WebKit scriptable with a JavaScript API.
|
||||
|
||||
DeckTape currently supports the [deck.js](http://imakewebthings.com/deck.js/), [DZSlides](http://paulrouget.com/dzslides/), [flowtime.js](http://flowtime-js.marcolago.com), [HTML Slidy](http://www.w3.org/Talks/Tools/), [impress.js](http://impress.github.io/impress.js), [remark.js](http://remarkjs.com) and [reveal.js](http://lab.hakim.se/reveal-js) presentation frameworks out-of-the-box. Besides, it exposes a plugin-based extension API so that it is possible to add support for other frameworks or tailored existing ones to your specific needs.
|
||||
DeckTape currently supports the [CSSS](http://leaverou.github.io/csss/), [deck.js](http://imakewebthings.com/deck.js/), [DZSlides](http://paulrouget.com/dzslides/), [flowtime.js](http://flowtime-js.marcolago.com), [HTML Slidy](http://www.w3.org/Talks/Tools/), [impress.js](http://impress.github.io/impress.js), [remark.js](http://remarkjs.com) and [reveal.js](http://lab.hakim.se/reveal-js) presentation frameworks out-of-the-box. Besides, it exposes a plugin-based extension API so that it is possible to add support for other frameworks or tailored existing ones to your specific needs.
|
||||
|
||||
You can browse some slide deck [examples](#examples) below that have been exported with DeckTape.
|
||||
|
||||
@ -87,6 +87,7 @@ The following slide deck examples have been exported using DeckTape:
|
||||
| [Flowtime.js Presentation Framework][flowtime-js-presentation] | flowtime.js | [flowtime-js-presentation.pdf][] (7.5MB) |
|
||||
| [The Official Remark Slideshow][remark-js-slideshow] | remark.js `0.11.0` | [remark-js-slideshow.pdf][] (0.7MB) |
|
||||
| [HTML Slidy: Slide Shows in HTML and XHTML][html-slidy-presentation] | HTML Slidy | [html-slidy-presentation.pdf][] (0.5MB) |
|
||||
| [CSSS: CSS-based SlideShow System][csss-sample-slideshow] | CSSS | [csss-sample-slideshow.pdf][] (13.5MB) |
|
||||
|
||||
[fowd-nyc-2014]: http://razvancaliman.com/fowd-nyc-2014
|
||||
[fowd-nyc-2014.pdf]: https://astefanutti.github.io/decktape/examples/fowd-nyc-2014.pdf
|
||||
@ -104,3 +105,5 @@ The following slide deck examples have been exported using DeckTape:
|
||||
[remark-js-slideshow.pdf]: https://astefanutti.github.io/decktape/examples/remark-js-slideshow.pdf
|
||||
[html-slidy-presentation]: http://www.w3.org/Talks/Tools/Slidy/
|
||||
[html-slidy-presentation.pdf]: https://astefanutti.github.io/decktape/examples/html-slidy-presentation.pdf
|
||||
[csss-sample-slideshow]: http://leaverou.github.io/csss/
|
||||
[csss-sample-slideshow.pdf]: https://astefanutti.github.io/decktape/examples/csss-sample-slideshow.pdf
|
||||
|
36
plugins/csss.js
Normal file
36
plugins/csss.js
Normal file
@ -0,0 +1,36 @@
|
||||
function CSSS() {
|
||||
}
|
||||
|
||||
CSSS.prototype = {
|
||||
|
||||
getName : function() {
|
||||
return "CSSS";
|
||||
},
|
||||
|
||||
isActive : function() {
|
||||
// Need to avoid global variable name collision with remark.js
|
||||
return typeof remark === "undefined" && typeof slideshow === "object";
|
||||
},
|
||||
|
||||
configure : function() {
|
||||
document.getElementById("timer").style.display = "none";
|
||||
},
|
||||
|
||||
slideCount : function() {
|
||||
return document.querySelectorAll(".slide, .delayed, .delayed-children > *").length;
|
||||
},
|
||||
|
||||
hasNextSlide : function() {
|
||||
return (slideshow.index + 1) in slideshow.slides;
|
||||
},
|
||||
|
||||
nextSlide : function() {
|
||||
slideshow.next(false);
|
||||
},
|
||||
|
||||
currentSlideIndex : function() {
|
||||
return slideshow.slides[slideshow.slide].id;
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = new CSSS();
|
@ -9,7 +9,7 @@ Remark.prototype = {
|
||||
},
|
||||
|
||||
isActive : function() {
|
||||
return typeof slideshow === "object";
|
||||
return typeof remark == "object" && slideshow === "object";
|
||||
},
|
||||
|
||||
slideCount : function() {
|
||||
|
Loading…
Reference in New Issue
Block a user