# Custom controls This plugin allows to add responsive custom controls to reveal.js which allow arbitrary positioning, layout, and behaviour of the controls. [Check out the live demo](https://rajgoel.github.io/reveal.js-demos/customcontrols-demo.html) ## Installation Copy the files `plugin.js` and `style.css` into the plugin folder of your reveal.js presentation, i.e. ```plugin/customcontrols``` and load the plugin as shown below. ```html ``` Note, without configuration you need to add ```javascript ``` between ```
``` and `````` of your HTML file because the defaults use [Font Awesome](http://fontawesome.io/). ## Configuration The plugin can be configured by adding custom controls and changing the layout of the slide number, e.g., by: ```javascript Reveal.initialize({ // ... customcontrols: { controls: [ { id: 'toggle-overview', title: 'Toggle overview (O)', icon: '', action: 'Reveal.toggleOverview();' }, { icon: '', title: 'Toggle chalkboard (B)', action: 'RevealChalkboard.toggleChalkboard();' }, { icon: '', title: 'Toggle notes canvas (C)', action: 'RevealChalkboard.toggleNotesCanvas();' } ] }, // ... }); ``` The `id` and `title` are optional. The configuration should be self explaining and any number of controls can be added. The style file can be altered to control the layout and responsiveness of the custom controls. ## License MIT licensed Copyright (C) 2020 Asvin Goel