Press 'P' to show a speaker console in a separate window.
Supports:
- Navigation controls
- This slide and next slide preview screens
- Speaker notes
- Clock and timer
Also applies this patch, which makes impressConsole.js follow the new
impress.js plugin standard: regebro/impress-console#22
Note: As impressConsole is now a plugin, it is included by default. You
no longer need to include it with a separate <script> tag. Nor do you
need to call its init() method.
Shows a help popup when user presses H. Add
<div id="impress-help">
...to the presentation to enable it.
Other plugins send their help text to this plugin as events.
The idea and style for this help popup comes from hovercraft, which would
generate such html code into each presentation it creates.
Adds new form plugin, which blurs() focus on impress:stepleave. This is to
prevent an input field from being focused when it is no longer visible.
Related to supporting forms, in an earlier commit we already changed the
navigation plugin to only listen to keypress events from body and html
elements. This was to allow presentations to have, for example, form
elements, where users can type text, including spaces, use arrows, etc.
To make loading of extras/ addons simpler, and remove cruft from
presentation html files, I created a new plugin src/plugins/extras/.
If any of the extra addons (highlight.js, markdown.js, mathjax.js
or mermaid.js) are added to the html file with a regular <script> tag,
then this module will discover and know how to init the module for you,
so it is not necessary to do that in html. If you're not using
the extras, this plugin does nothing.
Note that in the branch history where you are reading this commit,
the extras/ directory doesn't actually exist yet, nor do the
examples/ that use them. But they will hopefully join this branch soon.
The Mobile plugin adds CSS classes body.impress-mobile and
div.prev, div.next. These can be used in CSS to hide non-active
steps completely, in order to reduce memory consumption on
small mobile devices.
Also:
- Removes the code that allowed navigation by tapping left/right edge of screen.
- Actually, this was already removed in this branch...
- Removes the code that disabled impress.js on mobile devices
- Adds new API call impress().swipe()
Refactored for the plugin api from this pull request by @and3rson:
https://github.com/impress/impress.js/pull/496
Manually "cherry picked" from
c44fd0f4c1
This allows plugins to register to be executed at the beginning of
impress().init() and impress().goto() respectively. By returning false,
a plugin can also cancel the event.
Also adds 3 plugins that use this: rel, goto and stop.
- Libraries are under src/lib/
- Added to build.js as usual, before plugins.
- See src/lib/README.md for details
gc library implements a "garbage collector" library, which allows
both the core and plugins to store elements and listeners to a list,
and when impress().lib.gc.teardown() is called, to have all of them
removed from the DOM. It also allows plugins to register their own
callback functions, which are called at teardown.
Commentary:
This work is based on copying the src/lib/gc.js from impressionist. While it was
useful, it turns out on the impress.js side there was much more a need to reset
attributes rather than delete elements. For now, this means lots of plugins do this
via their own lib.gc.addCallback() functions. Probably it would be nicer to add
some generic lib.gc.resetAttributes() functionality for this particular case.
I'll return to this in a future patch.
extras/ are not supported for impress().tear(). What can I say, they're extras.
Maybe in the future I'll support them, for now I can live without.
* Source files are under src/
* js/impress.js is now generated, but remains part of the repo (so it just works)
* npm run build
* build.js uses buildify node module
* Break out navigation and resize plugins from core src/impress.js file