Parcourir la source

add data-start-indexv #427

Hakim El Hattab il y a 11 ans
Parent
commit
6b6c87db97
2 fichiers modifiés avec 5 ajouts et 2 suppressions
  1. 4 1
      js/reveal.js
  2. 1 1
      js/reveal.min.js

+ 4 - 1
js/reveal.js

@@ -748,7 +748,10 @@ var Reveal = (function(){
 	function getPreviousVerticalIndex( stack ) {
 
 		if( typeof stack === 'object' && typeof stack.setAttribute === 'function' && stack.classList.contains( 'stack' ) ) {
-			return parseInt( stack.getAttribute( 'data-previous-indexv' ) || 0, 10 );
+			// Prefer manually defined start-indexv
+			var attributeName = stack.hasAttribute( 'data-start-indexv' ) ? 'data-start-indexv' : 'data-previous-indexv';
+
+			return parseInt( stack.getAttribute( attributeName ) || 0, 10 );
 		}
 
 		return 0;

Fichier diff supprimé car celui-ci est trop grand
+ 1 - 1
js/reveal.min.js


Certains fichiers n'ont pas été affichés car il y a eu trop de fichiers modifiés dans ce diff