Limit the number of dots #417
Replies: 6 comments 4 replies
-
+1 See screenshot: |
Beta Was this translation helpful? Give feedback.
-
Hi. I think it would be a good feature to next versions. |
Beta Was this translation helpful? Give feedback.
-
Is there any news on this issue? I also want to limit the number of navigation dots for mobile view at least. I checked out pagination and there seems to be no option for that yet. I see this example to add numbers instead of dots: const splide = new Splide( '.splide' );
splide.on( 'pagination:mounted', function ( data ) {
// You can add your class to the UL element
data.list.classList.add( 'splide__pagination--custom' );
// `items` contains all dot items
data.items.forEach( function ( item ) {
item.button.textContent = String( item.page + 1 );
} );
} );
splide.mount(); I would think we could use something like |
Beta Was this translation helpful? Give feedback.
-
I think this is also a nice feature. Any updates on this? |
Beta Was this translation helpful? Give feedback.
-
I would also like to see this feature added, especially for mobile where the dots overrun the edges of the page. |
Beta Was this translation helpful? Give feedback.
-
Here's a custom code solution. This code generates a custom pagination. Therefore you need to disable the Splide pagination with the option The active dot is moved from left to right and starts at the left if the end of the MAX_DOTS is reached. So the user can see that there is something happen when using the Slider. See the gist at https://gist.github.com/Jehu/1f4038fdbcf9ee8c0b5a58cefd7cbbfd |
Beta Was this translation helpful? Give feedback.
-
Is there a way to limit the number of dots shown in the pagination?
Beta Was this translation helpful? Give feedback.
All reactions