Skip to content

Commit

Permalink
docs(headless-react): pagination typedoc reference (#4949)
Browse files Browse the repository at this point in the history
https://coveord.atlassian.net/browse/KIT-3950

I noticed that we weren't documenting PaginationOptions.

https://docs.coveo.com/en/headless-react/latest/reference/interfaces/SSR_Commerce.index.PaginationProps.html#options

This PR fixes it:
<img width="1541" alt="Screenshot 2025-02-06 at 4 14 03 PM"
src="https://github.com/user-attachments/assets/c71ca770-c275-41d1-adeb-5ad43be3b308"
/>
<img width="1492" alt="Screenshot 2025-02-06 at 4 14 15 PM"
src="https://github.com/user-attachments/assets/6c7c200b-252a-41b1-a7bf-76ba36bb9bf2"
/>
  • Loading branch information
jpmarceau authored Feb 7, 2025
1 parent b64e226 commit c9cae30
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,17 @@ import {
Pagination,
PaginationProps,
PaginationState,
PaginationOptions,
CorePaginationOptions,
} from './headless-core-commerce-pagination.js';

export type {Pagination, PaginationProps, PaginationState};
export type {
Pagination,
PaginationProps,
PaginationState,
PaginationOptions,
CorePaginationOptions,
};

/**
* Defines a `Pagination` controller instance.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ export interface PaginationState {
}

export interface CorePaginationOptions {
/**
* For internal use by Headless.
*/
slotId?: string;
/**
* The number of products to fetch per page.
Expand Down
2 changes: 2 additions & 0 deletions packages/headless/src/ssr-commerce.index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,8 @@ export type {
Pagination,
PaginationProps,
PaginationState,
PaginationOptions,
CorePaginationOptions,
} from './controllers/commerce/core/pagination/headless-core-commerce-pagination.ssr.js';
export {definePagination} from './controllers/commerce/core/pagination/headless-core-commerce-pagination.ssr.js';

Expand Down

0 comments on commit c9cae30

Please sign in to comment.