remove theme config option #1061
							parent
							
								
									c3f9aabe04
								
							
						
					
					
						commit
						7c03d60186
					
				
							
								
								
									
										21
									
								
								index.html
								
								
								
								
							
							
						
						
									
										21
									
								
								index.html
								
								
								
								
							|  | @ -163,16 +163,17 @@ | |||
| 					<h2>Themes</h2> | ||||
| 					<p> | ||||
| 						reveal.js comes with a few themes built in: <br> | ||||
| 						<a href="?#/themes">Black (default)</a> - | ||||
| 						<a href="?theme=white#/themes">White</a> - | ||||
| 						<a href="?theme=league#/themes">League</a> - | ||||
| 						<a href="?theme=sky#/themes">Sky</a> - | ||||
| 						<a href="?theme=beige#/themes">Beige</a> - | ||||
| 						<a href="?theme=simple#/themes">Simple</a> <br> | ||||
| 						<a href="?theme=serif#/themes">Serif</a> - | ||||
| 						<a href="?theme=night#/themes">Night</a> - | ||||
| 						<a href="?theme=moon#/themes">Moon</a> - | ||||
| 						<a href="?theme=solarized#/themes">Solarized</a> | ||||
| 						<!-- Hacks to swap themes after the page has loaded. Not flexible and only intended for the reveal.js demo deck. --> | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/test.css'); return false;">Black (default)</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/white.css'); return false;">White</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/league.css'); return false;">League</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/sky.css'); return false;">Sky</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/beige.css'); return false;">Beige</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/simple.css'); return false;">Simple</a> <br> | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/serif.css'); return false;">Serif</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/night.css'); return false;">Night</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/moon.css'); return false;">Moon</a> - | ||||
| 						<a href="#" onclick="document.getElementById('theme').setAttribute('href','css/theme/solarized.css'); return false;">Solarized</a> | ||||
| 					</p> | ||||
| 					<p> | ||||
| 						<small> | ||||
|  |  | |||
							
								
								
									
										15
									
								
								js/reveal.js
								
								
								
								
							
							
						
						
									
										15
									
								
								js/reveal.js
								
								
								
								
							|  | @ -121,9 +121,6 @@ | |||
| 			// Focuses body when page changes visiblity to ensure keyboard shortcuts work
 | ||||
| 			focusBodyOnPageVisibilityChange: true, | ||||
| 
 | ||||
| 			// Theme (see /css/theme)
 | ||||
| 			theme: null, | ||||
| 
 | ||||
| 			// Transition style
 | ||||
| 			transition: 'default', // none/fade/slide/convex/concave/zoom
 | ||||
| 
 | ||||
|  | @ -870,18 +867,6 @@ | |||
| 			} ); | ||||
| 		} | ||||
| 
 | ||||
| 		// Load the theme in the config, if it's not already loaded
 | ||||
| 		if( config.theme && dom.theme ) { | ||||
| 			var themeURL = dom.theme.getAttribute( 'href' ); | ||||
| 			var themeFinder = /[^\/]*?(?=\.css)/; | ||||
| 			var themeName = themeURL.match(themeFinder)[0]; | ||||
| 
 | ||||
| 			if(  config.theme !== themeName ) { | ||||
| 				themeURL = themeURL.replace(themeFinder, config.theme); | ||||
| 				dom.theme.setAttribute( 'href', themeURL ); | ||||
| 			} | ||||
| 		} | ||||
| 
 | ||||
| 		sync(); | ||||
| 
 | ||||
| 	} | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	 Hakim El Hattab
						Hakim El Hattab