slideshow-service 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (77) hide show
  1. checksums.yaml +4 -4
  2. data/Manifest.txt +71 -0
  3. data/lib/slideshow/service/public/slideshow-csss/classList.js +116 -0
  4. data/lib/slideshow/service/public/slideshow-csss/logo.svg +52 -0
  5. data/lib/slideshow/service/public/slideshow-csss/plugins/code-highlight.js +114 -0
  6. data/lib/slideshow/service/public/slideshow-csss/plugins/css-controls.js +40 -0
  7. data/lib/slideshow/service/public/slideshow-csss/plugins/css-edit.js +132 -0
  8. data/lib/slideshow/service/public/slideshow-csss/plugins/css-snippets.js +89 -0
  9. data/lib/slideshow/service/public/slideshow-csss/plugins/incrementable.js +94 -0
  10. data/lib/slideshow/service/public/slideshow-csss/prefixfree.min.js +10 -0
  11. data/lib/slideshow/service/public/slideshow-csss/reusable.css +118 -0
  12. data/lib/slideshow/service/public/slideshow-csss/slides.html +90 -0
  13. data/lib/slideshow/service/public/slideshow-csss/slideshow.css +282 -0
  14. data/lib/slideshow/service/public/slideshow-csss/slideshow.js +508 -0
  15. data/lib/slideshow/service/public/slideshow-csss/style.css +45 -0
  16. data/lib/slideshow/service/public/slideshow-csss/theme.css +247 -0
  17. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-fold-dim.gif +0 -0
  18. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-fold-dim.png +0 -0
  19. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-fold.gif +0 -0
  20. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-fold.png +0 -0
  21. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-nofold-dim.gif +0 -0
  22. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-nofold-dim.png +0 -0
  23. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-nofold.gif +0 -0
  24. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-nofold.png +0 -0
  25. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-unfold-dim.gif +0 -0
  26. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-unfold-dim.png +0 -0
  27. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-unfold.gif +0 -0
  28. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet-unfold.png +0 -0
  29. data/lib/slideshow/service/public/slideshow-slidy/graphics/bullet.png +0 -0
  30. data/lib/slideshow/service/public/slideshow-slidy/graphics/example.png +0 -0
  31. data/lib/slideshow/service/public/slideshow-slidy/graphics/example.svg +223 -0
  32. data/lib/slideshow/service/public/slideshow-slidy/graphics/face1.gif +0 -0
  33. data/lib/slideshow/service/public/slideshow-slidy/graphics/face2.gif +0 -0
  34. data/lib/slideshow/service/public/slideshow-slidy/graphics/face3.gif +0 -0
  35. data/lib/slideshow/service/public/slideshow-slidy/graphics/face4.gif +0 -0
  36. data/lib/slideshow/service/public/slideshow-slidy/graphics/fold-bright.gif +0 -0
  37. data/lib/slideshow/service/public/slideshow-slidy/graphics/fold-dim.bmp +0 -0
  38. data/lib/slideshow/service/public/slideshow-slidy/graphics/fold-dim.gif +0 -0
  39. data/lib/slideshow/service/public/slideshow-slidy/graphics/fold.bmp +0 -0
  40. data/lib/slideshow/service/public/slideshow-slidy/graphics/fold.gif +0 -0
  41. data/lib/slideshow/service/public/slideshow-slidy/graphics/icon-blue.png +0 -0
  42. data/lib/slideshow/service/public/slideshow-slidy/graphics/keys2.jpg +0 -0
  43. data/lib/slideshow/service/public/slideshow-slidy/graphics/nofold-dim.bmp +0 -0
  44. data/lib/slideshow/service/public/slideshow-slidy/graphics/nofold-dim.gif +0 -0
  45. data/lib/slideshow/service/public/slideshow-slidy/graphics/nofold.bmp +0 -0
  46. data/lib/slideshow/service/public/slideshow-slidy/graphics/unfold-bright.gif +0 -0
  47. data/lib/slideshow/service/public/slideshow-slidy/graphics/unfold-dim.bmp +0 -0
  48. data/lib/slideshow/service/public/slideshow-slidy/graphics/unfold-dim.gif +0 -0
  49. data/lib/slideshow/service/public/slideshow-slidy/graphics/unfold.bmp +0 -0
  50. data/lib/slideshow/service/public/slideshow-slidy/graphics/unfold.gif +0 -0
  51. data/lib/slideshow/service/public/slideshow-slidy/graphics/w3c-logo-blue.gif +0 -0
  52. data/lib/slideshow/service/public/slideshow-slidy/graphics/w3c-logo-blue.svg +14 -0
  53. data/lib/slideshow/service/public/slideshow-slidy/graphics/w3c-logo-slanted.jpg +0 -0
  54. data/lib/slideshow/service/public/slideshow-slidy/graphics/w3c-logo-white.gif +0 -0
  55. data/lib/slideshow/service/public/slideshow-slidy/graphics/w3c-logo-white.svg +14 -0
  56. data/lib/slideshow/service/public/slideshow-slidy/help/help.html +80 -0
  57. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.ca +52 -0
  58. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.de +96 -0
  59. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.en +81 -0
  60. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.es +52 -0
  61. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.fr +118 -0
  62. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.hu +98 -0
  63. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.nl +82 -0
  64. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.pl +76 -0
  65. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.pt-br +95 -0
  66. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.pt_br +95 -0
  67. data/lib/slideshow/service/public/slideshow-slidy/help/help.html.sv +75 -0
  68. data/lib/slideshow/service/public/slideshow-slidy/help/help.pt-br.html +95 -0
  69. data/lib/slideshow/service/public/slideshow-slidy/scripts/slidy.js +2952 -0
  70. data/lib/slideshow/service/public/slideshow-slidy/slides.blank.html +26 -0
  71. data/lib/slideshow/service/public/slideshow-slidy/slides.w3c.html +62 -0
  72. data/lib/slideshow/service/public/slideshow-slidy/styles/slidy.css +401 -0
  73. data/lib/slideshow/service/public/slideshow-slidy/styles/w3c-blue.css +493 -0
  74. data/lib/slideshow/service/version.rb +1 -2
  75. data/lib/slideshow/service/views/_editor.erb +7 -4
  76. data/lib/slideshow/service.rb +47 -19
  77. metadata +73 -2
@@ -0,0 +1,89 @@
1
+ /**
2
+ * Script to add prefixes to standard CSS3 in textareas or style attributes
3
+ * Requires css-edit.js
4
+ * @author Lea Verou
5
+ * MIT License
6
+ */
7
+
8
+ (function(head) {
9
+
10
+ var self = window.CSSSnippet = function(element) {
11
+ var me = this;
12
+
13
+ this.raw = element.hasAttribute('data-raw');
14
+
15
+ if(this.raw) {
16
+ this.style = document.createElement('style');
17
+
18
+ if(window.SlideShow) {
19
+ this.slide = SlideShow.getSlide(element);
20
+
21
+ if(location.hash == '#' + me.slide.id) {
22
+ this.style = head.appendChild(this.style);
23
+ }
24
+
25
+ // Remove it after we're done with it, to save on resources
26
+ addEventListener('hashchange', function() {
27
+ var appended = !!me.style.parentNode;
28
+
29
+ if(location.hash == '#' + me.slide.id != appended) {
30
+ me.style = head[(appended? 'remove' : 'append') + 'Child'](me.style);
31
+ }
32
+ }, false);
33
+ }
34
+ }
35
+ else {
36
+
37
+ // this holds the elements the CSS is gonna be applied to
38
+ this.subjects = CSSEdit.getSubjects(element);
39
+
40
+ CSSEdit.setupSubjects(this.subjects);
41
+ }
42
+
43
+ // Test if its text field first
44
+ if(/^(input|textarea)$/i.test(element.nodeName)) {
45
+ this.textField = element;
46
+
47
+ // Turn spellchecking off
48
+ this.textField.spellcheck = false;
49
+
50
+ CSSEdit.elastic(this.textField);
51
+
52
+ this.textField.addEventListener('input', function() {
53
+ me.update();
54
+ }, false);
55
+
56
+ this.textField.addEventListener('keyup', function() {
57
+ me.update();
58
+ }, false);
59
+
60
+ this.update();
61
+ }
62
+ else {
63
+ // Update style, only once
64
+ this.update();
65
+ }
66
+ }
67
+
68
+ self.prototype = {
69
+ update: function() {
70
+ var supportedStyle = PrefixFree.prefixCSS(this.getCSS(), this.raw);
71
+
72
+ if(this.raw) {
73
+ this.style.innerHTML = supportedStyle;
74
+ }
75
+ else {
76
+ var valid = CSSEdit.updateStyle(this.subjects, this.getCSS(), 'data-originalstyle');
77
+
78
+ if(this.textField && this.textField.classList) {
79
+ this.textField.classList[valid? 'remove' : 'add']('error');
80
+ }
81
+ }
82
+ },
83
+
84
+ getCSS: function() {
85
+ return this.textField ? this.textField.value : this.subjects[0].getAttribute('style');
86
+ }
87
+ };
88
+
89
+ })(document.head);
@@ -0,0 +1,94 @@
1
+ /**
2
+ * Script for making multiple numbers in a textfield incrementable/decrementable (like Firebug's CSS values)
3
+ * @author Lea Verou
4
+ * @version 1.0
5
+ */
6
+
7
+ /**
8
+ * Constructor
9
+ * @param textField {HTMLElement} An input or textarea element
10
+ * @param modifiers {Object} An object with params ctrlKey, altKey and/or shiftKey. The key combination must have a sum of >= 3.
11
+ * For example, {altKey: 1, ctrlKey: 3, shiftKey: 2} means that either Ctrl has to be pressed with the arrows, or alt+shift, or alt+ctrl, or all three.
12
+ * The default is 0, which means no modifiers needed.
13
+ */
14
+ function Incrementable(textField, modifiers, units) {
15
+ var me = this;
16
+
17
+ this.textField = textField;
18
+
19
+ this.step = +textField.getAttribute('step') ||
20
+ +textField.getAttribute('data-step') || 1;
21
+
22
+ modifiers = modifiers || {};
23
+ this.modifiers = {
24
+ ctrlKey: modifiers.ctrlKey || 0,
25
+ altKey: modifiers.altKey || 0,
26
+ shiftKey: modifiers.shiftKey || 0
27
+ };
28
+
29
+ if(units) {
30
+ this.units = units;
31
+ }
32
+
33
+ this.changed = false;
34
+
35
+ this.textField.addEventListener('keydown', function(evt) {
36
+ if(me.checkModifiers(evt) && (evt.keyCode == 38 || evt.keyCode == 40)) {
37
+ me.changed = false;
38
+
39
+ // Up or down arrow pressed, check if there's something
40
+ // increment/decrement-able where the caret is
41
+ var caret = this.selectionStart, text = this.value,
42
+ regex = new RegExp('^([\\s\\S]{0,' + caret + '}[^-0-9\\.])(-?[0-9]*(?:\\.?[0-9]+)(?:' + me.units + '))\\b', 'i');
43
+
44
+ this.value = this.value.replace(regex, function($0, $1, $2) {
45
+ if($1.length <= caret && $1.length + $2.length >= caret) {
46
+ me.changed = true;
47
+ return $1 + me.stepValue($2, evt.keyCode == 40, evt.shiftKey);
48
+ }
49
+ else {
50
+ return $1 + $2;
51
+ }
52
+ });
53
+
54
+ if(me.changed) {
55
+ this.selectionEnd = this.selectionStart = caret;
56
+ evt.preventDefault();
57
+ evt.stopPropagation();
58
+ }
59
+ }
60
+ }, false);
61
+
62
+ this.textField.addEventListener('keypress', function(evt) {
63
+ if(me.changed && me.checkModifiers(evt)
64
+ && (evt.keyCode == 38 || evt.keyCode == 40))
65
+ evt.preventDefault();
66
+ evt.stopPropagation();
67
+ me.changed = false;
68
+ }, false);
69
+ }
70
+
71
+ Incrementable.prototype = {
72
+ checkModifiers: function(evt) {
73
+ var m = this.modifiers;
74
+
75
+ return m.ctrlKey * evt.ctrlKey + m.altKey * evt.altKey + m.shiftKey * evt.shiftKey >= 3
76
+ || (m.ctrlKey + m.altKey + m.shiftKey == 0);
77
+ },
78
+
79
+ /**
80
+ * Gets a <length> and increments or decrements it
81
+ */
82
+ stepValue: function(length, decrement, byChunk) {
83
+ var val = parseFloat(length) + (decrement? -1 : 1) * (byChunk? 10 : 1) * this.step;
84
+
85
+ // Prevent rounding errors
86
+ if(this.step % 1) {
87
+ val = (parseFloat(val.toPrecision(12)));
88
+ }
89
+
90
+ return val + length.replace(/^-|[0-9]+|\./g, '');
91
+ },
92
+
93
+ units: '|%|deg|px|r?em|ex|ch|in|cm|mm|pt|pc|vm|vw|vh|gd|m?s'
94
+ };
@@ -0,0 +1,10 @@
1
+ // PrefixFree 1.0.4 / by Lea Verou / MIT license
2
+ (function(m,j){function l(a,b){return[].slice.call((b||document).querySelectorAll(a))}if(window.getComputedStyle&&window.addEventListener){var b=window.PrefixFree={prefixCSS:function(a,d){function e(f,d,h,e){var f=b[f],c=e!==j?e:"",n=h!==j?h:"",d=d||c+g+"$1"+n,c=e!==j?e:"\\b",n=h!==j?h:"\\b";f.length&&(f=RegExp(c+"("+f.join("|")+")"+n,"gi"),a=a.replace(f,d))}var g=b.prefix;e("functions",g+"$1(","\\s*\\(");e("keywords",null);e("properties",g+"$1:","\\s*:");if(b.properties.length){var c=RegExp("\\b("+
3
+ b.properties.join("|")+")(?!:)","gi");e("valueProperties",function(a){return a.replace(c,g+"$1")},":(.+?);")}d&&(e("selectors",b.prefixSelector,"\\b",""),e("atrules",null,j,"@"));return a=a.replace(RegExp("-"+g,"g"),"-")},process:{link:function(a){try{if(!/\bstylesheet\b/i.test(a.rel)||!a.sheet.cssRules)return}catch(d){return}var e=a.getAttribute("href")||a.getAttribute("data-href"),g=e.replace(/[^\/]+$/,""),c=a.parentNode,f=new XMLHttpRequest;f.open("GET",e);f.onreadystatechange=function(){if(f.readyState===
4
+ 4){var d=f.responseText;if(d&&a.parentNode){var d=b.prefixCSS(d,true),d=d.replace(/url\((?:'|")?(.+?)(?:'|")?\)/gi,function(a,b){return!/^([a-z]{3,10}:|\/)/i.test(b)?'url("'+g+b+'")':a}),e=document.createElement("style");e.textContent=d;e.media=a.media;e.disabled=a.disabled;c.insertBefore(e,a);c.removeChild(a)}}};f.send(null);a.setAttribute("data-inprogress","")},styleElement:function(a){var d=a.disabled;a.textContent=b.prefixCSS(a.textContent,true);a.disabled=d},styleAttribute:function(a){var d=
5
+ a.getAttribute("style"),d=b.prefixCSS(d);a.setAttribute("style",d)}},prefixSelector:function(a){return a.replace(/^:{1,2}/,function(a){return a+b.prefix})},prefixProperty:function(a,d){var e=b.prefix+a;return d?b.camelCase(e):e},camelCase:function(a){return a.replace(/-([a-z])/g,function(a,b){return b.toUpperCase()}).replace("-","")},deCamelCase:function(a){return a.replace(/[A-Z]/g,function(a){return"-"+a.toLowerCase()})}};(function(){var a={},d="",e=0,g=[],c=getComputedStyle(document.documentElement,
6
+ null),f=document.createElement("div").style,i=function(c){g.indexOf(c)===-1&&g.push(c);if(c.indexOf("-")>-1){var h=c.split("-");if(c.charAt(0)==="-"){var c=h[1],i=++a[c]||1;a[c]=i;for(e<i&&(d=c,e=i);h.length>3;)h.pop(),i=h.join("-"),b.camelCase(i)in f&&(c=g,c.indexOf(i)===-1&&c.push(i))}}};if(c.length>0)for(var h=0;h<c.length;h++)i(c[h]);else for(var k in c)i(b.deCamelCase(k));b.prefix="-"+d+"-";b.Prefix=b.camelCase(b.prefix);g.sort();b.properties=[];for(h=0;h<g.length;h++){k=g[h];if(k.charAt(0)!==
7
+ "-")break;k.indexOf(b.prefix)===0&&(c=k.slice(b.prefix.length),g.indexOf(c)===-1&&b.properties.push(c))}b.Prefix=="Ms"&&!("transform"in f)&&!("MsTransform"in f)&&"msTransform"in f&&b.properties.push("transform","transform-origin");b.properties.sort()})();(function(){function a(a,b){g[b]="";g[b]=a;return!!g[b]}var d={"linear-gradient":{property:"backgroundImage",params:"red, teal"},calc:{property:"width",params:"1px + 5%"},element:{property:"backgroundImage",params:"#foo"}},e={initial:"color","zoom-in":"cursor",
8
+ "zoom-out":"cursor"};d["repeating-linear-gradient"]=d["repeating-radial-gradient"]=d["radial-gradient"]=d["linear-gradient"];b.functions=[];b.keywords=[];var g=document.createElement("div").style,c;for(c in d){var f=d[c],i=f.property,f=c+"("+f.params+")";!a(f,i)&&a(b.prefix+f,i)&&b.functions.push(c)}for(var h in e)i=e[h],!a(h,i)&&a(b.prefix+h,i)&&b.keywords.push(h)})();(function(){function a(a){g.textContent=a+"{}";return!!g.sheet.cssRules.length}var d={":read-only":null,":read-write":null,":any-link":null,
9
+ "::selection":null},e={keyframes:"name",viewport:null,document:'regexp(".")'};b.selectors=[];b.atrules=[];var g=m.appendChild(document.createElement("style")),c;for(c in d){var f=c+(d[c]?"("+d[c]+")":"");!a(f)&&a(b.prefixSelector(f))&&b.selectors.push(c)}for(var i in e)f=i+" "+(e[i]||""),!a("@"+f)&&a("@"+b.prefix+f)&&b.atrules.push(i);m.removeChild(g)})();b.valueProperties=["transition","transition-property"];l('link[rel~="stylesheet"]').forEach(b.process.link);m.className+=" "+b.prefix;document.addEventListener("DOMContentLoaded",
10
+ function(){l('link[rel~="stylesheet"]:not([data-inprogress])').forEach(b.process.link);l("style").forEach(b.process.styleElement);l("[style]").forEach(b.process.styleAttribute)},false)}})(document.documentElement);
@@ -0,0 +1,118 @@
1
+ /**
2
+ * CSS I've found useful for more than one CSSS presentations
3
+ * and thought it might be useful for others too
4
+ * @author Lea Verou
5
+ */
6
+
7
+ /* Mark slides as incomplete to spot them easier */
8
+ .incomplete.slide::after {
9
+ content: 'INCOMPLETE';
10
+ font-weight: bold;
11
+ position: absolute;
12
+ top: 40%;
13
+ left: 30%;
14
+ padding: .1em .4em 0;
15
+ border: .1em solid;
16
+ color: rgba(255, 0, 0, .8);
17
+ font-size: 140%;
18
+ border-radius: .2em;
19
+ transform: rotate(30deg);
20
+ }
21
+
22
+ /* Ribbon */
23
+ [data-type].slide:not(.hide-ribbon):after {
24
+ content: attr(data-type);
25
+ position: fixed;
26
+ top: 0;
27
+ right: 0;
28
+ color: white;
29
+ font-size: 50%;
30
+ text-align: center;
31
+ text-transform: uppercase;
32
+ font-weight: bold;
33
+ background: hsl(40,100%,50%);
34
+ background-image: linear-gradient(rgba(255, 255, 255, .3), rgba(255, 255, 255, 0));
35
+ line-height: 1.6;
36
+ min-width: 20em;
37
+ box-shadow: 0 10px 5px -5px rgba(0,0,0,.3);
38
+ transform: rotate(45deg) translate(6em, -2em);
39
+ }
40
+
41
+ /* Full image slides */
42
+
43
+ @keyframes scroll {
44
+ from, to { background-position: 0 0; }
45
+ 80%, 95% { background-position: 0 100%; }
46
+ }
47
+
48
+ .image.slide {
49
+ padding: 0;
50
+ background-size: cover;
51
+ background-position: center;
52
+ background-repeat: no-repeat;
53
+ background-color: black;
54
+ }
55
+
56
+ /* When you don't want to clip the image at all */
57
+ .partial.image.slide {
58
+ background-size: contain;
59
+ }
60
+
61
+ /* An image that scrolls indefinitely */
62
+ .scrolling.image.slide:target {
63
+ background-position: 0 0;
64
+ background-repeat: repeat-y;
65
+ animation: scroll 10s 1s infinite linear forwards;
66
+ }
67
+
68
+ .bottom-heavy.image.slide {
69
+ background-position: center bottom;
70
+ }
71
+
72
+ .top-heavy.image.slide {
73
+ background-position: center top;
74
+ }
75
+
76
+ .image.slide > .caption,
77
+ .image.slide > h1:only-child {
78
+ position: absolute;
79
+ top: 50%;
80
+ right: 0;
81
+ left: 0;
82
+ margin-top: -.6em;
83
+ padding: .2em 0;
84
+ text-align: center;
85
+ font-size: 200%;
86
+ font-family: inherit;
87
+ font-weight: inherit;
88
+ line-height: 1.2;
89
+ color: white;
90
+ background: rgba(0,0,0,.4);
91
+ text-shadow: .03em .03em .05em black;
92
+ white-space: nowrap;
93
+ }
94
+
95
+ .top-heavy.image.slide > .caption,
96
+ .top-heavy.image.slide > h1:only-child {
97
+ top: auto;
98
+ bottom: .5in;
99
+ }
100
+
101
+ .bottom-heavy.image.slide > .caption,
102
+ .bottom-heavy.image.slide > h1:only-child {
103
+ position: static;
104
+ margin: .5in 0 0;
105
+ }
106
+
107
+ .image.slide > .caption h1 {
108
+ font: inherit;
109
+ margin-bottom: 0;
110
+ }
111
+
112
+ .image.slide > .caption h1 + a {
113
+ font-size: 30%;
114
+ display: block;
115
+ text-shadow: inherit;
116
+ }
117
+
118
+ /* END Full image slides */
@@ -0,0 +1,90 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
6
+ <meta name="generator" content="{{ headers['generator'] }}">
7
+ <meta name="author" content="{{ headers['author'] }}">
8
+
9
+ <title>{{ headers['title'] }}</title>
10
+
11
+ <!-- Don't alter this, CSSS needs it to work -->
12
+ <link href="slideshow.css" rel="stylesheet">
13
+
14
+ <!-- Theme-specific styles go here (themes can be reused in multiple talks) -->
15
+ <link href="theme.css" rel="stylesheet">
16
+
17
+ <!-- Talk-specific styles go here -->
18
+ <!-- GB: changed fixed name (style.css) to variable -->
19
+ <link href="style.css" rel="stylesheet">
20
+
21
+ </head>
22
+ <!-- GB: todo: add duration header/property -->
23
+ <body data-duration="45">
24
+
25
+ <header id="intro" class="slide">
26
+ <h1>{{ headers['title'] }}</h1>
27
+ <p class="attribution">By {{ headers['author'] }}</p>
28
+ </header>
29
+
30
+ <section class="slide" id="navigation">
31
+ <h2>CSSS Navigation</h2>
32
+ <p>Only through keyboard for now :(</p>
33
+ <ul>
34
+ <li>→ or ↓ to advance to the next slide or incrementally displayed item</li>
35
+ <li>← or ↑ to go to the previous slide or incrementally displayed item</li>
36
+ <li>Ctrl* + → or Ctrl* + ↓ to jump to the next slide</li>
37
+ <li>Ctrl* + ← or Ctrl* + ↑ to jump to the previous slide</li>
38
+ <li>Home to go to the first slide, End to go to the last</li>
39
+ <li>Ctrl* + G to jump to an arbitrary slide (by slide number or identifier)</li>
40
+ </ul>
41
+ <p>* Ctrl or Shift actually. Only Shift works in Opera.</p>
42
+ </section>
43
+
44
+ <section class="slide">
45
+ <h2>CSSS Navigation Cont.</h2>
46
+
47
+ <p>Thumbnail view</p>
48
+ <ul>
49
+ <li>Press Ctrl+H (or Shift+H if you're in Opera) now.</li>
50
+ <li>Press Ctrl+Shift+H to see all slides (warning: can be slow!)</li>
51
+ </ul>
52
+
53
+ <p>Presenter view</p>
54
+ <ul>
55
+ <li>This slide has presenter notes. They are only visible in presenter view (Ctrl+P or Shift+P).</li>
56
+ </ul>
57
+ <p class="presenter-notes">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
58
+
59
+ </section>
60
+
61
+ {% for slide in slides %}
62
+ <section class="slide">
63
+ {{ slide.content }}
64
+ </section>
65
+ {% endfor %}
66
+
67
+
68
+ <!--
69
+ <footer class="slide">
70
+ <h2>Thank you!</h2>
71
+ <p>Closing remarks</p>
72
+ </footer>
73
+ -->
74
+
75
+ <script src="slideshow.js"></script>
76
+
77
+ <!-- Make sure the reference to -prefix-free works -->
78
+ <script src="prefixfree.min.js"></script>
79
+
80
+ <!-- Uncomment the plugins you need
81
+ <script src="plugins/css-edit.js"></script>
82
+ <script src="plugins/css-snippets.js"></script>
83
+ <script src="plugins/css-controls.js"></script>
84
+ -->
85
+ <script>var slideshow = new SlideShow();
86
+ {{ more_content_for_js }}
87
+ </script>
88
+
89
+ </body>
90
+ </html>
@@ -0,0 +1,282 @@
1
+ /**
2
+ Basic CSS so that the slideshow script functions as a slideshow
3
+ @author Lea Verou
4
+ @version 1.0
5
+ */
6
+
7
+ /**
8
+ * "Variables"
9
+ */
10
+ .slide,
11
+ .delayed,
12
+ .delayed-children > * {
13
+ transition:1s;
14
+ transition-property: -webkit-transform, opacity, left, top, right, bottom;
15
+ }
16
+
17
+ /**
18
+ * Styles
19
+ */
20
+
21
+ html, body {
22
+ height: 100%;
23
+ }
24
+
25
+ body {
26
+ margin: 0;
27
+ }
28
+
29
+ .slide {
30
+ display: none;
31
+ position:absolute;
32
+ top:0;
33
+ right:0;
34
+ bottom:0;
35
+ left:0;
36
+ z-index:1;
37
+
38
+ font-size:250%;
39
+ line-height:1.6;
40
+ }
41
+
42
+ .slide.previous,
43
+ .slide:target,
44
+ .slide.next {
45
+ display: block;
46
+ opacity:0;
47
+ overflow:hidden;
48
+ }
49
+
50
+ .slide:target {
51
+ z-index:100;
52
+ opacity:1;
53
+ overflow: visible;
54
+ }
55
+
56
+ /**
57
+ Slide numbers
58
+ */
59
+ #indicator {
60
+ position: absolute;
61
+ top: .05in;
62
+ right: .5em;
63
+ z-index: 1010;
64
+
65
+ font-size: .15in;
66
+ color: white;
67
+ background: rgba(0,0,0,.25);
68
+ font-weight: 900;
69
+ text-shadow: .05em .05em .1em black;
70
+ text-align: center;
71
+ padding: .1em .3em 0;
72
+ min-width: 1.6em;
73
+ box-sizing: border-box;
74
+ border-radius: 999px;
75
+ }
76
+
77
+ /* If there's nothing selected, show the first */
78
+ .slide:first-child {
79
+ z-index:2;
80
+ }
81
+
82
+ /* Delayed items that are shown incrementally after the slide is */
83
+ .delayed,
84
+ .delayed-children > * {
85
+ opacity: 0;
86
+ }
87
+
88
+ .delayed.displayed,
89
+ .delayed-children > .displayed {
90
+ opacity: .3;
91
+ }
92
+
93
+ .delayed.current,
94
+ .delayed-children > .current,
95
+ .delayed.displayed.non-dismissable,
96
+ .delayed-children > .displayed.non-dismissable {
97
+ opacity: 1;
98
+ }
99
+
100
+ /**
101
+ iframe slides
102
+ */
103
+ .iframe.slide {
104
+ padding: 0;
105
+ text-align: center;
106
+ }
107
+
108
+ .iframe.slide > h1 {
109
+ position: absolute;
110
+ bottom: 0; right: 0; left: 0;
111
+ background: rgba(0,0,0,.5);
112
+ font-size: 100%;
113
+ }
114
+
115
+ .iframe.slide > h1 > a {
116
+ display: inline-block;
117
+ padding: .2em .5em;
118
+
119
+ color: white;
120
+ text-align: center;
121
+ text-decoration: none;
122
+ text-shadow: .05em .05em .1em black;
123
+ }
124
+
125
+ .slide > iframe:only-of-type {
126
+ display: none;
127
+ position: absolute;
128
+ border: 0;
129
+ width: 100%;
130
+ height: 100%;
131
+ margin: 0;
132
+ }
133
+
134
+ .slide:target > iframe:only-of-type {
135
+ display: block;
136
+ }
137
+
138
+ /**
139
+ Show thumbnails
140
+ */
141
+
142
+ .show-thumbnails {
143
+ overflow-x: hidden;
144
+ }
145
+
146
+ .show-thumbnails .slide,
147
+ .presenter .slide.next {
148
+ width: 1024px;
149
+ height: 768px;
150
+
151
+ -moz-box-sizing: border-box;
152
+ -webkit-box-sizing: border-box;
153
+ box-sizing: border-box;
154
+
155
+ float: left;
156
+ overflow: hidden;
157
+ position: static;
158
+ opacity: 1;
159
+ margin:-292px -395px;
160
+ cursor: pointer;
161
+
162
+ transform: scale(.2, .2);
163
+ transition:1s transform;
164
+ }
165
+
166
+ .show-thumbnails.headers-only .slide {
167
+ display: none;
168
+ }
169
+
170
+ .show-thumbnails.headers-only header.slide {
171
+ display: block;
172
+ }
173
+
174
+ .show-thumbnails .slide .delayed,
175
+ .presenter .slide:target + .slide .delayed {
176
+ opacity: 1;
177
+ }
178
+
179
+ .show-thumbnails .slide:hover,
180
+ .show-thumbnails .slide:target,
181
+ .presenter .slide:target + .slide {
182
+ outline: 20px solid rgba(255, 255, 255, .6);
183
+ outline-radius:5px;
184
+
185
+ box-shadow: 5px 5px 10px black;
186
+ }
187
+
188
+ .show-thumbnails .slide:target {
189
+ outline-color: rgba(255, 255, 255, .3);
190
+ }
191
+
192
+ .show-thumbnails .slide:target:hover {
193
+ outline-color: rgba(255, 255, 255, .9);
194
+ }
195
+
196
+ /* Display titles */
197
+ .show-thumbnails .slide[data-title]:after {
198
+ content: attr(data-title);
199
+ position: absolute;
200
+ left: 0;
201
+ right: 0;
202
+ bottom: 0;
203
+ padding: .1em 0;
204
+ background: rgba(0,0,0,.5);
205
+ color: white;
206
+ font-size: 250%;
207
+ text-align: center;
208
+ text-shadow: .05em .05em .1em black;
209
+ transform: none;
210
+ }
211
+
212
+ /* Hide all elements in slide by hitting Ctrl + J or Shift + J */
213
+ .hide-elements .slide:target > * {
214
+ opacity: 0;
215
+ transition:.5s;
216
+ }
217
+
218
+ /* Timer */
219
+
220
+ #timer {
221
+ position:absolute;
222
+ top:0;
223
+ left:0;
224
+ z-index:101;
225
+ width:0%;
226
+ height:16px;
227
+ line-height: 16px;
228
+ padding: 0 5px;
229
+ background:rgba(0,0,0,.5);
230
+ overflow: hidden;
231
+ text-align: right;
232
+ box-sizing: border-box;
233
+ }
234
+
235
+ #timer:before {
236
+ content: 'Progress ';
237
+ text-transform: uppercase;
238
+ color: white;
239
+ font-size: 9px;
240
+ }
241
+
242
+ #timer.end {
243
+ width: 100%;
244
+ }
245
+
246
+ /* Presenter & projector views */
247
+
248
+ .projector #timer {
249
+ display: none;
250
+ }
251
+
252
+ .presenter-notes {
253
+ display: none;
254
+ position: fixed;
255
+ right: 230px;
256
+ bottom: 0;
257
+ left: 0;
258
+ max-height: 6em;
259
+ overflow: auto;
260
+ padding: .6em 1em;
261
+ font-size: 60%;
262
+ line-height: 1.3;
263
+ font-weight: normal;
264
+ resize:vertical;
265
+ background: rgba(255, 255, 255, .5);
266
+ color: black;
267
+ text-shadow: 0 1px white;
268
+ box-shadow: .1em .1em .3em rgba(0,0,0,.5) inset;
269
+ }
270
+
271
+ .presenter .slide.next {
272
+ position: fixed;
273
+ top: auto;
274
+ right: 0;
275
+ bottom: 0;
276
+ left: auto;
277
+ z-index: 100;
278
+ }
279
+
280
+ .presenter .slide:target > .presenter-notes {
281
+ display: block;
282
+ }