Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.

[terra-table] Provide examples and tests for focusable elements in a table. #1850

Merged
merged 4 commits into from
Oct 23, 2023

Conversation

cm9361
Copy link
Contributor

@cm9361 cm9361 commented Oct 20, 2023

Summary

What was changed:
The tests and examples for the Terra Table were updated so that consumers could see how interactive elements work in the table and proper test coverage existed.

Why it was changed:
The change was made to improve test coverage and provide consumers with example to answer recurring questions.

Testing

This change was tested using:

  • WDIO
  • Jest
  • Visual testing (please attach a screenshot or recording)
  • Other (please describe below)
  • No tests are needed

Reviews

In addition to engineering reviews, this PR needs:

  • UX review
  • Accessibility review
  • Functional review

Additional Details

This PR resolves:

UXPLATFORM-9767


Thank you for contributing to Terra.
@cerner/terra

@cm9361 cm9361 marked this pull request as ready for review October 23, 2023 14:03
Copy link
Contributor

@adoroshk adoroshk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One minor thing I noticed is that for better readability we might want to increase the Column 1 width (or the cell with "Non Focusable Text" height). As it doesn't influence the functionality, I am approving the PR.
Screenshot 2023-10-23 at 10 41 41 AM

@@ -7,6 +7,7 @@
* Added
* Added test to cover enabling zebra striping for the `terra-table` component.
* Added test for tab focus for scrollable tables for the `terra-table` component.
* Added examples and tests to cover the behavior of interactive elements within a table for `terra=table`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: typo?

Suggested change
* Added examples and tests to cover the behavior of interactive elements within a table for `terra=table`.
* Added examples and tests to cover the behavior of interactive elements within a table for `terra-table`.

Terra.validates.element('table-focus-first-button', { columnResizeSelector: focusElementSelector });
});

it('validates that the proper grid element is selected when Tab is used to give initial focus to the grid', () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we update this to differentiate it from line 114?

@github-actions github-actions bot temporarily deployed to preview-pr-1850 October 23, 2023 16:10 Destroyed
@cm9361 cm9361 merged commit 9aca473 into main Oct 23, 2023
@cm9361 cm9361 deleted the UXPLATFORM-9767 branch October 23, 2023 21:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants