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

[BD-46] docs: fixed links leading to the 7th version of the React-table #2955

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/DataTable/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ designStatus: 'Done'
devStatus: 'In progress'
---

The DataTable component is a wrapper that uses the <a href="https://react-table.tanstack.com/docs/overview">react-table</a> library to
The DataTable component is a wrapper that uses the <a href="https://github.com/TanStack/table/tree/v7/docs/src/pages/docs" target="_blank" rel="noopener noreferrer">react-table</a> library to
create tables. It can be used as is, or its subcomponents can be used on their own, allowing the developer full control.

Paragon also exports all React hooks from ``react-table`` allowing the developers to use them and make customizations more freely without adding ``react-table`` as a separate dependency to their project.
For full list of available hooks view <a href="https://react-table.tanstack.com/docs/api/overview">react-table API reference</a>.
For full list of available hooks view <a href="https://github.com/TanStack/table/tree/v7/docs/src/pages/docs/api" target="_blank" rel="noopener noreferrer">react-table API reference</a>.

## How children get information

Expand All @@ -49,7 +49,7 @@ const instance = useContext(DataTableContext)
For small tables (less than ~10,000 rows), filtering, sorting and pagination can be done quickly and easily on the frontend.

In this example, a default TextFilter component is used for all columns. A default filter can be passed in,
or a filter component can be defined on the column. See <a href="https://react-table.tanstack.com/docs/api/useFilters">react-table filters documentation</a>
or a filter component can be defined on the column. See <a href="https://github.com/TanStack/table/blob/v7/docs/src/pages/docs/api/useFilters.md" target="_blank" rel="noopener noreferrer">react-table filters documentation</a>
for more information.

```jsx live
Expand Down
2 changes: 1 addition & 1 deletion src/DataTable/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ DataTable.propTypes = {
/** Function that will fetch table data. Called when page size, page index or filters change.
* Meant to be used with manual filters and pagination */
fetchData: PropTypes.func,
/** Initial state passed to react-table's documentation https://react-table.tanstack.com/docs/api/useTable */
/** Initial state passed to react-table's documentation https://github.com/TanStack/table/blob/v7/docs/src/pages/docs/api/useTable.md */
initialState: PropTypes.shape({
pageSize: requiredWhen(PropTypes.number, 'isPaginated'),
pageIndex: requiredWhen(PropTypes.number, 'isPaginated'),
Expand Down
6 changes: 3 additions & 3 deletions src/DataTable/tablefilters.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,18 @@ devStatus: 'In progress'
---


The ``DataTable`` component is a wrapper that uses the <a href="https://react-table.tanstack.com/docs">react-table</a> library to
The ``DataTable`` component is a wrapper that uses the <a href="https://github.com/TanStack/table/tree/v7/docs/src/pages/docs" target="_blank" rel="noopener noreferrer">react-table</a> library to
create tables. It can be used as is, or its subcomponents can be used on their own, allowing the developer full control.

## Filtering and sorting
Paragon currently provides a variety of filter types, and you can also define your own filter types.

In the example below, a default ``TextFilter`` component is used as the default filter for all columns. A default filter can be passed in,
or a filter component can be defined on the column using the ``Filter`` attribute. See <a href="https://react-table.tanstack.com/docs/api/useFilters">react-table filters documentation</a>
or a filter component can be defined on the column using the ``Filter`` attribute. See <a href="https://github.com/TanStack/table/blob/v7/docs/src/pages/docs/api/useFilters.md" target="_blank" rel="noopener noreferrer">react-table filters documentation</a>
for more information.

## Available filter functions
A filtering function can be defined on the column as well as the filter component. Custom filtering functions can also be defined, see <a href="https://react-table.tanstack.com/docs/api/useFilters#column-options">react-table filters documentation</a>
A filtering function can be defined on the column as well as the filter component. Custom filtering functions can also be defined, see <a href="https://github.com/TanStack/table/blob/v7/docs/src/pages/docs/api/useFilters.md#column-options" target="_blank" rel="noopener noreferrer">react-table filters documentation</a>
for more information.
Filter functions are defined on the column as the ``filter`` attribute.
<dl>
Expand Down