akiran / akiran/react-slick

determine slides "in view" when scrolling partial pages

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

説明

https://codesandbox.io/s/react-slick-playground-ok514
^^ nothing special, just a basic carousel with 10 slides..

we are having an issue where we need to know exactly what ones are still "in-view" ...
when we show full pages, it is easy to determine this with the beforeChange and or afterChange ... but when you end up scrolling a partial page, (in my example 2 existing, 2 new) the slick-current is data-id 8 and the slick-active is data-id 8-9, but data 6,7,8,9 are "in-view" ... the carousel only transformed so many pixels due to the slidesToOffset.

Is there any way we can add a class (slick-in-view?) or get more data in beforeChange to easily know what items are "in-view" after all transform/animation is complete?

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

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

評価

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

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

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