From: Marcel Werk Date: Thu, 22 Dec 2022 11:18:59 +0000 (+0100) Subject: Apply suggestions from code review X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3a6f2cb063f4ab4424390d89cd400232e5e0c667;p=GitHub%2FWoltLab%2Fwoltlab.github.io.git Apply suggestions from code review Co-authored-by: Alexander Ebert --- diff --git a/docs/javascript/components_pagination.md b/docs/javascript/components_pagination.md index c43657e5..d0179dc1 100644 --- a/docs/javascript/components_pagination.md +++ b/docs/javascript/components_pagination.md @@ -15,7 +15,7 @@ This component supports both static URLs and dynamic navigation using DOM events Defaults to `1`. -Number of the currently active page. +The number of the currently displayed page. ### `count` @@ -25,18 +25,18 @@ Number of available pages. Must be greater than `1` for the pagination to be dis ### `url` -Default to an empty string. +Defaults to an empty string. -If defined, static pagination links are created based on the URL. +If defined, static pagination links are created based on the URL with the `pageNo` parameter appended to it. Otherwise only the `switchPage` event will be fired if a user clicks on a pagination link. ## Events ### `switchPage` -The `switchPage` event will be fired if a user clicks on a pagination link. The event detail will contain the number of the selected page. +The `switchPage` event will be fired when the user clicks on a pagination link. The event detail will contain the number of the selected page. The event can be canceled to prevent navigation. ### `jumpToPage` -The `switchPage` event will be fired if a user clicks on a ellipsis button within the pagination. +The `switchPage` event will be fired when the user clicks on one of the ellipsis buttons within the pagination.