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

Added search function with previous and next result #14600

Closed
wants to merge 1 commit into from

Conversation

Wilson-chongchong
Copy link

Intent

This pull request addresses the enhancement request for the data viewer in RStudio. It introduces the ability to search for text within the viewer, allowing users to quickly navigate to specific occurrences of text within the data. This feature improves usability and productivity for users who need to find specific information within large datasets.

Approach

The approach taken involves adding a search box to the data viewer interface. When the user enters text into the search box and presses Enter, the viewer navigates to the first occurrence of the text, displaying some preceding and following rows for context. Additionally, "Next" and "Previous" buttons are provided to allow users to easily navigate between occurrences of the searched text.

Automated Tests

This change includes automated unit tests to ensure that the search functionality works as expected. Unit tests cover scenarios such as searching for text, navigating to the next and previous occurrences, and handling edge cases like reaching the end of the dataset.

QA Notes

To validate this change, QA should perform the following steps:

Open the data viewer by executing View(iris) in the R console.
Enter text into the search box and press Enter.
Verify that the viewer navigates to the first occurrence of the searched text and displays surrounding rows.
Click on the "Next" and "Previous" buttons to navigate between occurrences.
Test edge cases, such as searching for text that doesn't exist in the dataset.
This change has a moderate level of risk, as it involves modifying the behavior of a core feature in RStudio. QA should pay attention to any unexpected behavior or performance issues.

Documentation

Documentation has been added to the user guide to explain how to use the new search functionality in the data viewer. This information will help users understand how to leverage this feature to improve their data analysis workflows.

Checklist

  • [x ] If this PR adds a new feature, or fixes a bug in a previously released version, it includes an entry in NEWS.md
  • [ x] If this PR adds or changes UI, the updated UI meets accessibility standards
  • [ x] A reviewer is assigned to this PR (if unsure who to assign, check Area Owners list)
  • [ x] This PR passes all local unit tests

@kevinushey kevinushey marked this pull request as draft April 29, 2024 23:28
@kevinushey
Copy link
Contributor

Thanks for the pull request! I'm a bit confused as the RStudio data viewer does already have a Search box; for example:

Screenshot 2024-04-29 at 4 31 51 PM

In addition, you describe the PR as providing extensions to the data viewer, but include only stubs for the Environment pane's grid view (which itself already has a search bar).

Screenshot 2024-04-29 at 4 33 09 PM

@kevinushey kevinushey closed this Apr 29, 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.

None yet

2 participants