From 962bf0cec61f31648f90add575e13b443fff9c5f Mon Sep 17 00:00:00 2001 From: Phyks Date: Tue, 10 Jun 2014 23:03:00 +0200 Subject: [PATCH] Base setup --- Gruntfile.js | 1 + css/theme/beige.css | 3 +- css/theme/blood.css | 2 +- css/theme/default.css | 3 +- css/theme/moon.css | 3 +- css/theme/night.css | 4 +- css/theme/phyks.css | 147 ++++++++++++++++++++++++++++++++++++ css/theme/simple.css | 4 +- css/theme/sky.css | 4 +- css/theme/solarized.css | 3 +- css/theme/source/phyks.scss | 42 +++++++++++ index.html | 102 +++++++++++++++++++++---- 12 files changed, 290 insertions(+), 28 deletions(-) create mode 100644 css/theme/phyks.css create mode 100644 css/theme/source/phyks.scss diff --git a/Gruntfile.js b/Gruntfile.js index 71ae1519..2f5bd9b1 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -41,6 +41,7 @@ module.exports = function(grunt) { main: { files: { 'css/theme/default.css': 'css/theme/source/default.scss', + 'css/theme/phyks.css': 'css/theme/source/phyks.scss', 'css/theme/beige.css': 'css/theme/source/beige.scss', 'css/theme/night.css': 'css/theme/source/night.scss', 'css/theme/serif.css': 'css/theme/source/serif.scss', diff --git a/css/theme/beige.css b/css/theme/beige.css index 089cb7b9..c46474a5 100644 --- a/css/theme/beige.css +++ b/css/theme/beige.css @@ -1,16 +1,15 @@ -@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /** * Beige theme for reveal.js. * * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se */ +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); @font-face { font-family: 'League Gothic'; src: url("../../lib/font/league_gothic-webfont.eot"); src: url("../../lib/font/league_gothic-webfont.eot?#iefix") format("embedded-opentype"), url("../../lib/font/league_gothic-webfont.woff") format("woff"), url("../../lib/font/league_gothic-webfont.ttf") format("truetype"), url("../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular") format("svg"); font-weight: normal; font-style: normal; } - /********************************************* * GLOBAL STYLES *********************************************/ diff --git a/css/theme/blood.css b/css/theme/blood.css index 0aefdd9b..55fed0d4 100644 --- a/css/theme/blood.css +++ b/css/theme/blood.css @@ -1,4 +1,3 @@ -@import url(https://fonts.googleapis.com/css?family=Ubuntu:300,700,300italic,700italic); /** * Blood theme for reveal.js * Author: Walther http://github.com/Walther @@ -10,6 +9,7 @@ * For other themes, change $codeBackground accordingly. * */ +@import url(https://fonts.googleapis.com/css?family=Ubuntu:300,700,300italic,700italic); /********************************************* * GLOBAL STYLES *********************************************/ diff --git a/css/theme/default.css b/css/theme/default.css index a234861f..b040c549 100644 --- a/css/theme/default.css +++ b/css/theme/default.css @@ -1,16 +1,15 @@ -@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /** * Default theme for reveal.js. * * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se */ +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); @font-face { font-family: 'League Gothic'; src: url("../../lib/font/league_gothic-webfont.eot"); src: url("../../lib/font/league_gothic-webfont.eot?#iefix") format("embedded-opentype"), url("../../lib/font/league_gothic-webfont.woff") format("woff"), url("../../lib/font/league_gothic-webfont.ttf") format("truetype"), url("../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular") format("svg"); font-weight: normal; font-style: normal; } - /********************************************* * GLOBAL STYLES *********************************************/ diff --git a/css/theme/moon.css b/css/theme/moon.css index 3c15b008..2b7f534f 100644 --- a/css/theme/moon.css +++ b/css/theme/moon.css @@ -1,15 +1,14 @@ -@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /** * Solarized Dark theme for reveal.js. * Author: Achim Staebler */ +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); @font-face { font-family: 'League Gothic'; src: url("../../lib/font/league_gothic-webfont.eot"); src: url("../../lib/font/league_gothic-webfont.eot?#iefix") format("embedded-opentype"), url("../../lib/font/league_gothic-webfont.woff") format("woff"), url("../../lib/font/league_gothic-webfont.ttf") format("truetype"), url("../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular") format("svg"); font-weight: normal; font-style: normal; } - /** * Solarized colors by Ethan Schoonover */ diff --git a/css/theme/night.css b/css/theme/night.css index e8703a5d..4286fbe1 100644 --- a/css/theme/night.css +++ b/css/theme/night.css @@ -1,10 +1,10 @@ -@import url(https://fonts.googleapis.com/css?family=Montserrat:700); -@import url(https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic,700italic); /** * Black theme for reveal.js. * * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se */ +@import url(https://fonts.googleapis.com/css?family=Montserrat:700); +@import url(https://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic,700italic); /********************************************* * GLOBAL STYLES *********************************************/ diff --git a/css/theme/phyks.css b/css/theme/phyks.css new file mode 100644 index 00000000..b040c549 --- /dev/null +++ b/css/theme/phyks.css @@ -0,0 +1,147 @@ +/** + * Default theme for reveal.js. + * + * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se + */ +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); +@font-face { + font-family: 'League Gothic'; + src: url("../../lib/font/league_gothic-webfont.eot"); + src: url("../../lib/font/league_gothic-webfont.eot?#iefix") format("embedded-opentype"), url("../../lib/font/league_gothic-webfont.woff") format("woff"), url("../../lib/font/league_gothic-webfont.ttf") format("truetype"), url("../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular") format("svg"); + font-weight: normal; + font-style: normal; } +/********************************************* + * GLOBAL STYLES + *********************************************/ +body { + background: #1c1e20; + background: -moz-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%); + background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, #555a5f), color-stop(100%, #1c1e20)); + background: -webkit-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%); + background: -o-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%); + background: -ms-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%); + background: radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%); + background-color: #2b2b2b; } + +.reveal { + font-family: "Lato", sans-serif; + font-size: 36px; + font-weight: normal; + letter-spacing: -0.02em; + color: #eeeeee; } + +::selection { + color: white; + background: #ff5e99; + text-shadow: none; } + +/********************************************* + * HEADERS + *********************************************/ +.reveal h1, +.reveal h2, +.reveal h3, +.reveal h4, +.reveal h5, +.reveal h6 { + margin: 0 0 20px 0; + color: #eeeeee; + font-family: "League Gothic", Impact, sans-serif; + line-height: 0.9em; + letter-spacing: 0.02em; + text-transform: uppercase; + text-shadow: 0px 0px 6px rgba(0, 0, 0, 0.2); } + +.reveal h1 { + text-shadow: 0 1px 0 #cccccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbbbbb, 0 4px 0 #b9b9b9, 0 5px 0 #aaaaaa, 0 6px 1px rgba(0, 0, 0, 0.1), 0 0 5px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.3), 0 3px 5px rgba(0, 0, 0, 0.2), 0 5px 10px rgba(0, 0, 0, 0.25), 0 20px 20px rgba(0, 0, 0, 0.15); } + +/********************************************* + * LINKS + *********************************************/ +.reveal a:not(.image) { + color: #13daec; + text-decoration: none; + -webkit-transition: color .15s ease; + -moz-transition: color .15s ease; + -ms-transition: color .15s ease; + -o-transition: color .15s ease; + transition: color .15s ease; } + +.reveal a:not(.image):hover { + color: #71e9f4; + text-shadow: none; + border: none; } + +.reveal .roll span:after { + color: #fff; + background: #0d99a5; } + +/********************************************* + * IMAGES + *********************************************/ +.reveal section img { + margin: 15px 0px; + background: rgba(255, 255, 255, 0.12); + border: 4px solid #eeeeee; + box-shadow: 0 0 10px rgba(0, 0, 0, 0.15); + -webkit-transition: all .2s linear; + -moz-transition: all .2s linear; + -ms-transition: all .2s linear; + -o-transition: all .2s linear; + transition: all .2s linear; } + +.reveal a:hover img { + background: rgba(255, 255, 255, 0.2); + border-color: #13daec; + box-shadow: 0 0 20px rgba(0, 0, 0, 0.55); } + +/********************************************* + * NAVIGATION CONTROLS + *********************************************/ +.reveal .controls div.navigate-left, +.reveal .controls div.navigate-left.enabled { + border-right-color: #13daec; } + +.reveal .controls div.navigate-right, +.reveal .controls div.navigate-right.enabled { + border-left-color: #13daec; } + +.reveal .controls div.navigate-up, +.reveal .controls div.navigate-up.enabled { + border-bottom-color: #13daec; } + +.reveal .controls div.navigate-down, +.reveal .controls div.navigate-down.enabled { + border-top-color: #13daec; } + +.reveal .controls div.navigate-left.enabled:hover { + border-right-color: #71e9f4; } + +.reveal .controls div.navigate-right.enabled:hover { + border-left-color: #71e9f4; } + +.reveal .controls div.navigate-up.enabled:hover { + border-bottom-color: #71e9f4; } + +.reveal .controls div.navigate-down.enabled:hover { + border-top-color: #71e9f4; } + +/********************************************* + * PROGRESS BAR + *********************************************/ +.reveal .progress { + background: rgba(0, 0, 0, 0.2); } + +.reveal .progress span { + background: #13daec; + -webkit-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); + -moz-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); + -ms-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); + -o-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); + transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } + +/********************************************* + * SLIDE NUMBER + *********************************************/ +.reveal .slide-number { + color: #13daec; } diff --git a/css/theme/simple.css b/css/theme/simple.css index 504606c0..4b60d05f 100644 --- a/css/theme/simple.css +++ b/css/theme/simple.css @@ -1,5 +1,3 @@ -@import url(https://fonts.googleapis.com/css?family=News+Cycle:400,700); -@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /** * A simple theme for reveal.js presentations, similar * to the default theme. The accent color is darkblue. @@ -7,6 +5,8 @@ * This theme is Copyright (C) 2012 Owen Versteeg, https://github.com/StereotypicalApps. It is MIT licensed. * reveal.js is Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se */ +@import url(https://fonts.googleapis.com/css?family=News+Cycle:400,700); +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /********************************************* * GLOBAL STYLES *********************************************/ diff --git a/css/theme/sky.css b/css/theme/sky.css index 1a447602..d33bfb3a 100644 --- a/css/theme/sky.css +++ b/css/theme/sky.css @@ -1,10 +1,10 @@ -@import url(https://fonts.googleapis.com/css?family=Quicksand:400,700,400italic,700italic); -@import url(https://fonts.googleapis.com/css?family=Open+Sans:400italic,700italic,400,700); /** * Sky theme for reveal.js. * * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se */ +@import url(https://fonts.googleapis.com/css?family=Quicksand:400,700,400italic,700italic); +@import url(https://fonts.googleapis.com/css?family=Open+Sans:400italic,700italic,400,700); .reveal a:not(.image) { line-height: 1.3em; } diff --git a/css/theme/solarized.css b/css/theme/solarized.css index c8bff7c1..1f1aa462 100644 --- a/css/theme/solarized.css +++ b/css/theme/solarized.css @@ -1,15 +1,14 @@ -@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); /** * Solarized Light theme for reveal.js. * Author: Achim Staebler */ +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); @font-face { font-family: 'League Gothic'; src: url("../../lib/font/league_gothic-webfont.eot"); src: url("../../lib/font/league_gothic-webfont.eot?#iefix") format("embedded-opentype"), url("../../lib/font/league_gothic-webfont.woff") format("woff"), url("../../lib/font/league_gothic-webfont.ttf") format("truetype"), url("../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular") format("svg"); font-weight: normal; font-style: normal; } - /** * Solarized colors by Ethan Schoonover */ diff --git a/css/theme/source/phyks.scss b/css/theme/source/phyks.scss new file mode 100644 index 00000000..1117b65c --- /dev/null +++ b/css/theme/source/phyks.scss @@ -0,0 +1,42 @@ +/** + * Default theme for reveal.js. + * + * Copyright (C) 2011-2012 Hakim El Hattab, http://hakim.se + */ + + +// Default mixins and settings ----------------- +@import "../template/mixins"; +@import "../template/settings"; +// --------------------------------------------- + + + +// Include theme-specific fonts +@font-face { + font-family: 'League Gothic'; + src: url('../../lib/font/league_gothic-webfont.eot'); + src: url('../../lib/font/league_gothic-webfont.eot?#iefix') format('embedded-opentype'), + url('../../lib/font/league_gothic-webfont.woff') format('woff'), + url('../../lib/font/league_gothic-webfont.ttf') format('truetype'), + url('../../lib/font/league_gothic-webfont.svg#LeagueGothicRegular') format('svg'); + + font-weight: normal; + font-style: normal; +} + +@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic); + +// Override theme settings (see ../template/settings.scss) +$heading1TextShadow: 0 1px 0 #ccc, 0 2px 0 #c9c9c9, 0 3px 0 #bbb, 0 4px 0 #b9b9b9, 0 5px 0 #aaa, 0 6px 1px rgba(0,0,0,.1), 0 0 5px rgba(0,0,0,.1), 0 1px 3px rgba(0,0,0,.3), 0 3px 5px rgba(0,0,0,.2), 0 5px 10px rgba(0,0,0,.25), 0 20px 20px rgba(0,0,0,.15); + +// Background generator +@mixin bodyBackground() { + @include radial-gradient( rgba(28,30,32,1), rgba(85,90,95,1) ); +} + + + +// Theme template ------------------------------ +@import "../template/theme"; +// --------------------------------------------- \ No newline at end of file diff --git a/index.html b/index.html index 72bf08d6..1f6a1f2c 100644 --- a/index.html +++ b/index.html @@ -347,6 +347,35 @@ function linkify( selector ) {

BY Hakim El Hattab / hakim.se

+
+

Addons

+
+ +
+
+

Mathjax

+

Just put some LaTeX in the slides :

+ \begin{aligned} + \dot{x} & = \sigma(y-x) \\ + \dot{y} & = \rho x - y - xz \\ + \dot{z} & = -\beta z + xy + \end{aligned} +
+
+

Code

+

+
+

Mathjax

+
+
+
+
+ @@ -359,30 +388,77 @@ function linkify( selector ) { // Full list of configuration options available here: // https://github.com/hakimel/reveal.js#configuration Reveal.initialize({ - controls: true, + // No controls in bottom right corner + controls: false, + // Display status bar progress: true, + // Display slide number + slideNumber: true, + // Push each slide to browser history history: true, - center: true, - - theme: Reveal.getQueryHash().theme, // available themes are in /css/theme - transition: Reveal.getQueryHash().transition || 'default', // default/cube/page/concave/zoom/linear/fade/none - - // Parallax scrolling - // parallaxBackgroundImage: 'https://s3.amazonaws.com/hakim-static/reveal-js/reveal-parallax-1.jpg', - // parallaxBackgroundSize: '2100px 900px', - + // Enable keyboard shortcuts for navigation + keyboard: true, + //Enable the slide overview mode + overview: true, + // Vertical centering of slides + center: true, + // Enables touch navigation on devices with touch input + touch: true, + // Don't loop the presentation + loop: false, + // Turn on fragments + fragments: true, + // Enable slide navigation by mouse wheel + mouseWheel: true, + // Hides the address bar on mobile devices + hideAddressBar: true, + // Don't open links in an iframe preview overlay + previewLinks: false, + // Transition style : default / cube / page / concave / zoom / linear / fade / none + transition: 'default', + // Transition speed : default / fast / slow + transitionSpeed: 'default', + // Transition style for full page slide backgrounds : default / none / slide / concave / convex / zoom + backgroundTransition: 'default', + // Number of slides away from the current that are visible + viewDistance: 3, + // Parallax background image + parallaxBackgroundImage: '', + // Parallax background size + parallaxBackgroundSize: '', // CSS syntax, e.g. "2100px 900px" + // Theme to use + theme: 'phyks', // Optional libraries used to extend on reveal.js dependencies: [ + // Cross-browser shim that fully implements classList { src: 'lib/js/classList.js', condition: function() { return !document.body.classList; } }, + // Markdown support { src: 'plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } }, { src: 'plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } }, + // Syntax highlight for element { src: 'plugin/highlight/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } }, + // Zoom in and out with Alt+click { src: 'plugin/zoom-js/zoom.js', async: true, condition: function() { return !!document.body.classList; } }, - { src: 'plugin/notes/notes.js', async: true, condition: function() { return !!document.body.classList; } } - ] + // Speaker notes + { src: 'plugin/notes/notes.js', async: true, condition: function() { return !!document.body.classList; } }, + // Remote control your reveal.js presentation using a touch device + // { src: 'plugin/remotes/remotes.js', async: true, condition: function() { return !!document.body.classList; } }, + // MathJax + { src: 'plugin/math/math.js', async: true } + ], + // "Normal" default size of the presentation + // 800x600 since it is the lowest resolution available on videoprojectors + width: 800, + height: 600, + // Factor of the display size that should remain empty around the content + margin: 0.1, }); + Reveal.configure({ + keyboard: { + 13: 'next', // go to the next slide when the ENTER key is pressed + } + }); -