|
@@ -2215,6 +2215,25 @@ var Reveal = (function(){
|
|
|
|
|
|
}
|
|
|
|
|
|
+ if( currentSlide ) {
|
|
|
+
|
|
|
+ var allFragments = currentSlide.querySelectorAll( '.fragment' );
|
|
|
+
|
|
|
+ // If there are fragments in the current slide those should be
|
|
|
+ // accounted for in the progress.
|
|
|
+ if( allFragments.length > 0 ) {
|
|
|
+ var visibleFragments = currentSlide.querySelectorAll( '.fragment.visible' );
|
|
|
+
|
|
|
+ // This value represents how big a portion of the slide progress
|
|
|
+ // that is made up by its fragments (0-1)
|
|
|
+ var fragmentWeight = 0.9;
|
|
|
+
|
|
|
+ // Add fragment progress to the past slide count
|
|
|
+ pastCount += ( visibleFragments.length / allFragments.length ) * fragmentWeight;
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
return pastCount / ( totalCount - 1 );
|
|
|
|
|
|
}
|
|
@@ -2519,6 +2538,7 @@ var Reveal = (function(){
|
|
|
}
|
|
|
|
|
|
updateControls();
|
|
|
+ updateProgress();
|
|
|
|
|
|
return !!( fragmentsShown.length || fragmentsHidden.length );
|
|
|
|