(X)HTML / CSS / JS Slideshow [BETA]
Eric A. Meyer
Operatic Origins
- Opera introduces OperaShow, a projection-mode style sheet handling technology
- Allows a single (X)HTML document to be turned into a PowerPoint-like slide show
- Adding screen and print style sheets allows for multi-medium views of a single document
- Highly efficient, but highly browser centric...
Expanding The Field
- When Opera 7.5 for OS X came out, the banner ads persisted in projection mode
- Tantek Çelik created a JavaScript-driven slide show technique that worked on multiple browsers
- Unfortunately, it required each slide to be ID'ed ahead of time, making additions and rearrangement difficult
- Navigation was only linear; no way to jump to an arbitrary slide
- There was also no facility to "switch off" the slide show styles short of killing all CSS
- Motive and opportunity combined to point the way...
Where We Are Now
- This slide show technique builds on Tantek's original scripts and ideas
- Each slide is enclosed in a classed
div
; IDs are dynamically assigned by script
- Navigation menu is automatically built at run time
- A "slide style" toggle function now exists
How It Works
- Controls are...
- Next slide: Space bar, return, right arrow, down arrow, click anywhere in slide that isn't in the control area (lower right corner), click "arrow" in lower right corner, accesskey "X"
- Previous slide: Up arrow, left arrow, click "arrow" in lower right corner, accesskey "Z"
- Toggle the slide styles: Click on the toggle button (to the left of the arrows), press "t", accesskey "T"
- To invoke the navigation menu: mouse into the lower right corner of the slide (below the navigation arrows)
The Advantages
- With one file, you get a slide show, a printable outline, and a screen presentation
- Files are incredibly lightweight and compress easily
- Thanks to their semantic (X)HTML, slideshow files are also highly accessible
- New slide themes can be created simply by writing new style sheets
Known Problems
- IE/Mac:
- The navigation menu doesn't show up when you mouse into the lower right corner
- All others: none known!
- Opera falls back to use OperaShow; thus all behaviors are exactly as for normal Opera Show documents and no additions show up
Assistance Appreciated
- Do you have a fix for any of the problems listed? Please share it!
- Credit for assistance will be included in the JS and CSS files as appropriate
- The slide system will be released under a Creative Commons Attribution-ShareAlike 2.0 license, so you must be willing to accept those terms
- In other words: if you submit a contribution, you are agreeing to abide by and place your contributions under the CC license mentioned above
In Summary
- With minimal scripting, we can recreate and improve upon a (currently) browser-specific technology
- The scripting still needs some work, as does the style
- Once the problems are resolved, we'll have a very flexible and lightweight slide show system available for anyone to use
- Help out if you can!