File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -245,16 +245,17 @@ export default class SCROLL_EFFECT_MODULE {
245245 setActiveState ( el , false ) ;
246246 }
247247 } else {
248- // displayRatioとdisplayRatioReverseが異なる場合の処理
249- if ( this . state . NumScrolltop + ( this . NumWindowHeight * this . config . displayRatio ) > el . pos ) {
250- // displayRatioで設定された閾値を満たした場合
251- setActiveState ( el , true ) ;
252- } else if ( this . state . NumScrolltop + ( this . NumWindowHeight * this . config . displayRatioReverse ) > el . pos ) {
253- // displayRatioReverseで設定された閾値を満たした場合
254- setActiveState ( el , true ) ;
248+ // ratioとratioReverseが異なる場合の処理
249+ if ( ! el . active ) {
250+ if ( this . state . NumScrolltop + ( this . state . NumWindowHeight * this . config . ratio ) > el . pos ) {
251+ // ratioで設定された閾値を満たした場合
252+ setActiveState ( el , true ) ;
253+ }
255254 } else {
256- // どの閾値も満たさない場合
257- setActiveState ( el , false ) ;
255+ if ( this . state . NumScrolltop + ( this . state . NumWindowHeight * this . config . ratioReverse ) < el . pos ) {
256+ // ratioReverseで設定された閾値を下回った場合
257+ setActiveState ( el , false ) ;
258+ }
258259 }
259260 }
260261 }
You can’t perform that action at this time.
0 commit comments