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

Bug: Not all suggestions are being displayed on insight page #1374

Closed
2 tasks done
Olaleye-Blessing opened this issue Jul 16, 2023 · 13 comments · Fixed by #1380
Closed
2 tasks done

Bug: Not all suggestions are being displayed on insight page #1374

Olaleye-Blessing opened this issue Jul 16, 2023 · 13 comments · Fixed by #1380

Comments

@Olaleye-Blessing
Copy link
Contributor

Describe the bug

Just few repos are being showed when a user searches for a repo even tho the query returns many repos.

Screenshot (782)

Steps to reproduce

Browsers

No response

Additional context (Is this in dev or production?)

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Contributing Docs

  • I agree to follow this project's Contribution Docs
@Olaleye-Blessing Olaleye-Blessing added 🐛 bug Something isn't working 👀 needs triage labels Jul 16, 2023
@aryanas159
Copy link
Contributor

@Olaleye-Blessing @brandonroberts
if (req.ok) { const res = await req.json(); const suggestions = res.items.map((item: any) => item.full_name); if (suggestions.length > 5) suggestions.length = 5; setSuggestions(suggestions);

According to this only 5 results can be displayed, is it a bug or a feature?

@babblebey
Copy link
Contributor

This thus seem like it was intentional and I want to assume it was indeed made that way in the absence of a ScrollArea component in the beta design system at initial implementation.

Here's what happen without (if (suggestions.length > 5) suggestions.length = 5;) limiting suggestions count to 5

screencast-localhost_3000-2023 07 17-07_30_36

I added a ScrollArea component to the design system recently #1283

Would any of you guys want to give implementing it into the Search component a shot?

@aryanas159
Copy link
Contributor

@babblebey Okay, I will try implementing it.

@babblebey
Copy link
Contributor

Okay, I will try implementing it.

Great 🍕 Let us know if you need any help!

You can reference the ScrollArea documentation here -> ScrollArea Story

aryanas159 added a commit to aryanas159/app that referenced this issue Jul 17, 2023
…n insight page

Signed-off-by: Aryan Singh <114330931+aryanas159@users.noreply.github.com>
@aryanas159
Copy link
Contributor

@babblebey Could you please checkout the changes I have made.

@babblebey
Copy link
Contributor

Could you please checkout the changes I have made.

Great stuff @aryanas159, kindly note that your PR #1377 doesn't exactly fix this current issue.

I have created a new issue for what your PR fixes at #1378. Take the new Issue, then edit your PR Description, relate it accordingly.

Either you or @Olaleye-Blessing can proceed to fixing this current issue with another PR.

aryanas159 added a commit to aryanas159/app that referenced this issue Jul 17, 2023
…n insight page

Signed-off-by: Aryan Singh <114330931+aryanas159@users.noreply.github.com>
@babblebey
Copy link
Contributor

Hey @aryanas159,

My apologies, I have taken notice of how separating the PRs makes them both ineffective. So let fix this!

  • Commit your second change to this branch to effect the removal of line below from the InsightPage component
if (suggestions.length > 5) suggestions.length = 5;

This way we are be able to see a working demo of the ScrollArea implemented with the full suggestions list.

@NsdHSO
Copy link
Contributor

NsdHSO commented Jul 17, 2023

@babblebey could you check this issue I think this is a feature, not a bug.

@NsdHSO
Copy link
Contributor

NsdHSO commented Jul 17, 2023

IMHO the page will be so huge if we drop the limitation, or we can make overflow only in the suggestions area to have scroll and see only 5 elements once,

@babblebey
Copy link
Contributor

could you check this issue I think this is a feature, not a bug.

@NsdHSO

True, the TableHeader component seen in the 'suggested solution' section of the issue #932 indeed implements the same logic in handling the suggestions counts as with the InsightPage component, that's where it must've gotten the idea from.

if (suggestions.length > 5) suggestions.length = 5;

IMHO the page will be so huge if we drop the limitation, or we can make overflow only in the suggestions area to have scroll and see only 5 elements once,

The goal is introduce all the suggestions without the limit and implement the ScrollArea which will surely allow us see only 5 elements at once and the rest will require a scroll as seen below

screencast-localhost_3000-2023 07 17-14_01_20

What do you think?

@NsdHSO
Copy link
Contributor

NsdHSO commented Jul 17, 2023

I think this approach is more feasible.

@aryanas159
Copy link
Contributor

@babblebey I have made a different PR and closed the other two, this should fix all the issues.

aryanas159 added a commit to aryanas159/app that referenced this issue Jul 18, 2023
bdougie pushed a commit that referenced this issue Jul 18, 2023
…#1380)

Signed-off-by: Aryan Singh <114330931+aryanas159@users.noreply.github.com>
github-actions bot pushed a commit that referenced this issue Jul 18, 2023
### [1.56.1-beta.1](v1.56.0...v1.56.1-beta.1) (2023-07-18)

### 🐛 Bug Fixes

* Issue [#1374](#1374) All suggestions are being displayed with scroll area ([#1380](#1380)) ([1de56c7](1de56c7))
@github-actions
Copy link
Contributor

🎉 This issue has been resolved in version 1.56.1-beta.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

github-actions bot pushed a commit that referenced this issue Jul 24, 2023
## [1.57.0](v1.56.0...v1.57.0) (2023-07-24)

### 🤖 Build System

* update eslint prettier config and setup commit hooks ([#1396](#1396)) ([ac9b276](ac9b276))

### 🔁 Continuous Integration

* disable husky for release ([2537649](2537649))
* fix husky command during release ([3e493a2](3e493a2))

### 🐛 Bug Fixes

* add `pullrequestLink` check into `HighlightInput` form `isDivFocused` condition ([#1406](#1406)) ([f3fda46](f3fda46))
* Auto-Scroll Not Triggered Upon Clicking 'Next Page' in Highlight… ([#1387](#1387)) ([77b161d](77b161d))
* flash of "test content" while loading in dashboard page ([#1409](#1409)) ([ad23f14](ad23f14))
* Improved the user experience of the highlights input form ([#1362](#1362)) ([2425dc4](2425dc4))
* Issue [#1374](#1374) All suggestions are being displayed with scroll area ([#1380](#1380)) ([1de56c7](1de56c7))
* Move card image api route ([#1401](#1401)) ([d650161](d650161))
* update top contributors response data ([#1397](#1397)) ([9053091](9053091))

### 🍕 Features

* add `[#100](https://github.com/open-sauced/insights/issues/100)DayOfOSS` challenge anouncement to feeds ([#1389](#1389)) ([751dbbf](751dbbf))
* add 404 page ([#1390](#1390)) ([37bd475](37bd475))
* add discord link to user profile ([#1370](#1370)) ([f94bc3b](f94bc3b))
* Add links to getting started docs ([#1395](#1395)) ([c58cc80](c58cc80))
* add upgrade access button to user settings page ([#1398](#1398)) ([671ebf4](671ebf4))
* implement improved highlights form with ai auto-summarise ([#1381](#1381)) ([023f576](023f576))
* implemented hover and highlight contribution graph ([#1404](#1404)) ([0453370](0453370))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants