File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " js-scroll-effect-module" ,
3- "version" : " 0.10.0 " ,
3+ "version" : " 0.10.1 " ,
44 "description" : " Add effect at scroll." ,
55 "keywords" : [
66 " scroll" ,
Original file line number Diff line number Diff line change @@ -130,6 +130,8 @@ export default class SCROLL_EFFECT_MODULE {
130130 el : el ,
131131 index : i ,
132132 pos : el . getBoundingClientRect ( ) . top + this . state . NumScrolltop ,
133+ height : el . clientHeight ,
134+ height2 : el . offsetHeight ,
133135 count : 0 ,
134136 active : false ,
135137 intersect : false ,
@@ -178,6 +180,7 @@ export default class SCROLL_EFFECT_MODULE {
178180 // Store element state at PosList.
179181 this . state . PosList . map ( ( el ) => {
180182
183+ // When displayRatio and displayRatioReverse are the SAME.
181184 if ( this . config . displayRatio === this . config . displayRatioReverse ) {
182185 if ( this . state . NumScrolltop + ( this . NumWindowHeight * this . config . displayRatio ) > el . pos ) {
183186 // First count up.
@@ -196,6 +199,7 @@ export default class SCROLL_EFFECT_MODULE {
196199 }
197200 }
198201
202+ // When displayRatio and displayRatioReverse are the DIFFERENT.
199203 if ( this . config . displayRatio !== this . config . displayRatioReverse ) {
200204 if ( this . state . NumScrolltop + ( this . NumWindowHeight * this . config . displayRatio ) > el . pos ) {
201205 // First count up.
You can’t perform that action at this time.
0 commit comments