-
Notifications
You must be signed in to change notification settings - Fork 593
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
…952) * refactor: simplify some boolean logic * refactor: remove default value for slideIndex In order to determine when the slideIndex was intentionally set by a user. * fix: better initial cell index when slides not left-aligned * fix: make autoplay continue to the last slide when cellAlign != left and slidesToShow > 1 * test: add some failing tests before modifying getDotIndexes to handle cellAlign * fix: handle non-left cellAlign values when generating dot controls * fix: only avoid whitespace with default index with scrollMode="remainder" * test: add failing tests for case of final slide being omitted * fix: show a dot corresponding to the last slide when cellAlign=center|right * test: add failing tests for prev/next button disabling * fix: correct button disabling when cellAlign=center|right * refactor: rename count->slideCount * test: add failing tests for prev/next button index calculation * fix: make the prev/next buttons jump to appropriate indices with cellAlign=center|right * refactor: simplify now that prevSlide and nextSlide cannot overstep their bounds * test: fix cypress test based on old behavior * test: use speed prop to make e2e tests run faster * build: avoid autoplay causing flakiness in Chromatic checks * chore: tweak behavior for dot generation when whitespace is allowed * chore: prevent additional scrolling when all remaining slides visible * chore: handle case of all slides fitting in from start * chore: handle case of all slides fitting in from start (right align) * test: add extra case of all slides fitting in from start (center align)
- Loading branch information
Showing
16 changed files
with
723 additions
and
183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'nuka-carousel': patch | ||
--- | ||
|
||
make the prev/next buttons jump to appropriate indices with cellAlign=center|right |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'nuka-carousel': patch | ||
--- | ||
|
||
make autoplay continue to the last slide when cellAlign != left and slidesToShow > 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'nuka-carousel': patch | ||
--- | ||
|
||
correct button disabling when cellAlign=center|right |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'nuka-carousel': patch | ||
--- | ||
|
||
show a dot corresponding to the last slide when cellAlign=center|right |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'nuka-carousel': patch | ||
--- | ||
|
||
fix initial index when autoplayReverse=true and cellAlign is not left |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
60036ad
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
nuka-carousel – ./
nuka-carousel-next.vercel.app
nuka-carousel-nuka-carousel.vercel.app
nuka-carousel-git-main-nuka-carousel.vercel.app