alvarotrigo / alvarotrigo/react-fullpage

Changing autoScrolling on non full-screen section behaves unexpectedly

オープン
#241 コメント 9 件 リアクション 0 件 担当者 0 名 GitHub で見る
bug
主要言語
JavaScript
スター
1.3k
フォーク
172
PR マージ指標
30日以内にマージされた PR はありません

説明

### Description

Hi, I am using React Fullpage for render some sections, and one of them should be non-autoscrollable, so I have some bug when the state will be true, the page will faster scrolling to upper section without animation. Is it possible to deactive autoscrolling and FitToSection on one section, and when it will be other page activate autoscroll but without any jerking?

My code:

{
console.log(destination, 'destination')
if (destination.item.classList.contains('fp-responsive-auto-height') || destination.isLast) {
setIsActive(false)
return
} else {
setIsActive(true)
}
}}
render={({ state, fullpageApi }) => {
if (!isActive) {
fullpageApi.setAutoScrolling(false)
} else {
if (state.initialized) {
fullpageApi.setAutoScrolling(true)
}
}
return (


















//*---THIS section is 1200 px height&---*






//*---THIS section is 200 px height&---*


)
}}
/>

//*---after will be also footer section in App components*

### Steps to reproduce it
1. Create full page section
2. Try to make one or two page without autoscrolling and disableFitTosection to avoid any jerking

### Versions
use Chrome, win 10

Thank you in advance!!

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。