Sfoglia il codice sorgente

made data-background attribute work with .webp #3200

hakimel 3 anni fa
parent
commit
286d5ef561
5 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 0 0
      dist/reveal.esm.js
  2. 0 0
      dist/reveal.esm.js.map
  3. 0 0
      dist/reveal.js
  4. 0 0
      dist/reveal.js.map
  5. 1 1
      js/controllers/backgrounds.js

File diff suppressed because it is too large
+ 0 - 0
dist/reveal.esm.js


File diff suppressed because it is too large
+ 0 - 0
dist/reveal.esm.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/reveal.js


File diff suppressed because it is too large
+ 0 - 0
dist/reveal.js.map


+ 1 - 1
js/controllers/backgrounds.js

@@ -150,7 +150,7 @@ export default class Backgrounds {
 
 		if( data.background ) {
 			// Auto-wrap image urls in url(...)
-			if( /^(http|file|\/\/)/gi.test( data.background ) || /\.(svg|png|jpg|jpeg|gif|bmp)([?#\s]|$)/gi.test( data.background ) ) {
+			if( /^(http|file|\/\/)/gi.test( data.background ) || /\.(svg|png|jpg|jpeg|gif|bmp|webp)([?#\s]|$)/gi.test( data.background ) ) {
 				slide.setAttribute( 'data-background-image', data.background );
 			}
 			else {

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