Skip to content

Add correct calculation for pageCount when using scrollPerPage false #329

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

ashleysimpson
Copy link
Contributor

Description

Updated the page count calculation for the carousel and pagination to properly display the correct number of pagination dots for scrollPerPage false

Motivation and Context

The current functionality is broken and very apparent when using scrollPerPage in vue play

How Has This Been Tested?

I have only tested the implementation in vue play

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
    • I have updated the documentation accordingly.
  • I have included a vue-play example (if this is a new feature)

@@ -86,6 +86,10 @@ exports[`Carousel should decrease current slide number by 1 when advance slide b
button.VueCarousel-dot-button(type='button', role='button', aria-label='\`Item \${index}\`', title='Item 0', tabindex='0', style='width: 10px; height: 10px; background: rgb(239, 239, 239);')
li.VueCarousel-dot.VueCarousel-dot--active(aria-hidden='false', role='presentation', aria-selected='true', style='margin-top: 20px; padding: 10px;')
button.VueCarousel-dot-button(type='button', role='button', aria-label='\`Item \${index}\`', title='Item 1', tabindex='0', style='width: 10px; height: 10px; background: rgb(0, 0, 0);')
li.VueCarousel-dot(aria-hidden='false', role='presentation', aria-selected='false', style='margin-top: 20px; padding: 10px;')
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test should have four navigation dots and was wrong originally. After the fix the snapshot was updated to now be correct.

@quinnlangille quinnlangille changed the base branch from master to v0.16.0 November 27, 2018 17:36
@quinnlangille quinnlangille merged commit 7cc1504 into SSENSE:v0.16.0 Nov 27, 2018
quinnlangille added a commit that referenced this pull request Nov 29, 2018
* feat(standard): adding touchDrag prop to block touch dragging (#296)

* feat(standard): adding touchDrag prop to block dragging on mobile devices

* feat(standard): adding touchDrag prop to block dragging on mobile devices - removing package-lock.json

* adding line-break space to end of file

* chore(build): release for rc1

* v0.16.0-rc1

* Fix carousel failing to lock to remainder slides (#303)

* Update Carousel.vue

fix carousel bug

* Added a looping autoplay to the Story page. (#305)

* docs(readme): updated README configuration section (#304)

* v0.16.0-rc2

* fix: rename event slideClick to slideclick in Slide.vue (#311)

* fix: rename event slideClick to slideclick

* fix(slide): disable tap highlight in Mobile Safari (#326)

* fix(slide): disable tap highlight in Mobile Safari

* feat: add correct calculation for pageCount (#329)

* chore: build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants