grommet icon indicating copy to clipboard operation
grommet copied to clipboard

Fix Datatable conflicting paginated step

Open jeferson-sb opened this issue 3 years ago • 0 comments

What does this PR do?

Uses the usePagination util so the Datatable component step can be defined with either step prop or inside paginate prop when used as an object.

Where should the reviewer start?

src/js/components/DataTable/DataTable.js

What testing has been done on this PR?

yarn test

How should this be manually tested?

Use or create a datatable story in storybook using the paginate prop https://storybook.grommet.io/?path=/story/visualizations-datatable-paginated--paginated

Do Jest tests follow these best practices?

  • [ ] screen is used for querying.
  • [ ] The correct query is used. (Refer to this list of queries)
  • [ ] userEvent is used in place of fireEvent.
  • [ ] asFragment() is used for snapshot testing.

Any background context you want to provide?

What are the relevant issues?

Issue #6221

Screenshots (if appropriate)

Do the grommet docs need to be updated?

no

Should this PR be mentioned in the release notes?

Is this change backwards compatible or is it a breaking change?

backwards compatible

jeferson-sb avatar Aug 02 '22 21:08 jeferson-sb