Skip to content
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

feat: Add local pagination feature #56

Merged

Conversation

wolfmanfx
Copy link
Contributor

This commit adds the implementation for local pagination in the withPagination function. It allows for displaying a subset of items from a larger collection, based on the current page and page size.

The withPagination function accepts an optional collection parameter to support multiple paginated collections. It calculates the selected page entities, total count, total pages, and page navigation array based on the provided options.

Additionally, utility functions like gotoPage, setPageSize, nextPage, previousPage, firstPage, and setMaxPageNavigationArrayItems are provided to easily update the pagination state.

Export with-pagination

Downgrade signals package

Update signal package

This commit adds the implementation for local pagination in the `withPagination` function. It allows for displaying a subset of items from a larger collection, based on the current page and page size.

The `withPagination` function accepts an optional `collection` parameter to support multiple paginated collections. It calculates the selected page entities, total count, total pages, and page navigation array based on the provided options.

Additionally, utility functions like `gotoPage`, `setPageSize`, `nextPage`, `previousPage`, `firstPage`, and `setMaxPageNavigationArrayItems` are provided to easily update the pagination state.

Export with-pagination

Downgrade signals package

Update signal package
@rainerhahnekamp rainerhahnekamp merged commit fc03cee into angular-architects:main Jun 7, 2024
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.

3 participants