瀏覽代碼

adjust background image url detection #453

Hakim El Hattab 11 年之前
父節點
當前提交
922b0037cd
共有 2 個文件被更改,包括 2 次插入2 次删除
  1. 1 1
      js/reveal.js
  2. 1 1
      js/reveal.min.js

+ 1 - 1
js/reveal.js

@@ -283,7 +283,7 @@ var Reveal = (function(){
 
 			if( data.background ) {
 				// Auto-wrap image urls in url(...)
-				if( /\.(png|jpg|jpeg|gif|bmp)$/gi.test( data.background ) ) {
+				if( /^(http|file|\/\/)/gi.test( data.background ) ) {
 					element.style.backgroundImage = 'url('+ data.background +')';
 				}
 				else {

File diff suppressed because it is too large
+ 1 - 1
js/reveal.min.js


Some files were not shown because too many files changed in this diff