Explorar o código

fix retrieval of computed styles in ff

Hakim El Hattab %!s(int64=10) %!d(string=hai) anos
pai
achega
3c5f3ee048
Modificáronse 2 ficheiros con 5 adicións e 5 borrados
  1. 4 4
      js/reveal.js
  2. 1 1
      js/reveal.min.js

+ 4 - 4
js/reveal.js

@@ -743,8 +743,8 @@ var Reveal = (function(){
 				if( typeof sibling.offsetHeight === 'number' && sibling !== element ) {
 
 					var styles = window.getComputedStyle( sibling ),
-						marginTop = parseInt( styles[ 'margin-top' ], 10 ),
-						marginBottom = parseInt( styles[ 'margin-bottom' ], 10 );
+						marginTop = parseInt( styles.marginTop, 10 ),
+						marginBottom = parseInt( styles.marginBottom, 10 );
 
 					height -= sibling.offsetHeight + marginTop + marginBottom;
 
@@ -755,8 +755,8 @@ var Reveal = (function(){
 			var elementStyles = window.getComputedStyle( element );
 
 			// Subtract the margins of the target element
-			height -= parseInt( elementStyles[ 'margin-top' ], 10 ) +
-						parseInt( elementStyles[ 'margin-bottom' ], 10 );
+			height -= parseInt( elementStyles.marginTop, 10 ) +
+						parseInt( elementStyles.marginBottom, 10 );
 
 		}
 

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 1 - 1
js/reveal.min.js


Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio