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

fix(openchallenges): fix bugs related search dropdown filters on search page #2688

Merged
merged 32 commits into from
Jun 6, 2024

Conversation

rrchai
Copy link
Contributor

@rrchai rrchai commented May 17, 2024

Changelogs

  • Add flag to enable/disable loader animation
    • Disable the loader animation by default to avoid showing placeholders when scrolling to the data already loaded.
  • Enable to dynamic set height based on two inputs: # of options (pageSize), and height of each option, so it will always show all options from the first page.
  • Fixed the "empty" bug: [Bug] search dropdown filter UI shows "empty"  #2648
    • If there are selected values for dropdown filter in URL params, retrieve and append the selected values to the top of items
    • If the selected value(s) in URL params is invalid, it will be ignored.
  • Fixed a bug that the selected values are not shown in the UI when the search terms change, instead it will show "empty".

Preview

Disable loader animation

While the loading animation looks nice, a flickering behavior has been observed (see @tschaffter's message below), which is why this PR hides the animation.

Before After
v0 v1

Fix empty labels

Before After
v0 2 v1 2

b) Invalid selected values

Before After
0 3 v1 3

Fix selected values not shown in UI

The selected values, if present, will always sit on the top of options, unless the values are unselected and reset by changing search term.

Before After
0 4 1 4

@rrchai rrchai self-assigned this May 17, 2024
@tschaffter tschaffter changed the title fix(openchallnges): fix bugs related search dropdown filters on search page fix(openchallenges): fix bugs related search dropdown filters on search page May 17, 2024
@rrchai
Copy link
Contributor Author

rrchai commented May 23, 2024

@tschaffter I am not sure if the changes in this pr will fix the flicking issue you encountered 🍀

@rrchai rrchai marked this pull request as ready for review May 23, 2024 18:34
@rrchai rrchai requested review from tschaffter and vpchung as code owners May 23, 2024 18:35
@tschaffter
Copy link
Member

Yes, enabling the loading animation still leads to a flickering. See another video below where I scroll 4 times. The first scroll is fine, but the next three scrolls feature a flickering. Tested on Firefox.

Recording 2024-05-23 at 14 26 55

@rrchai
Copy link
Contributor Author

rrchai commented May 24, 2024

Yes, enabling the loading animation still leads to a flickering. See another video below where I scroll 4 times. The first scroll is fine, but the next three scrolls feature a flickering. Tested on Firefox.

If we disable loading animation, does the flickering behavior still exist? @tschaffter

@rrchai rrchai marked this pull request as draft May 24, 2024 16:40
@rrchai rrchai marked this pull request as ready for review June 6, 2024 17:05
Copy link

sonarqubecloud bot commented Jun 6, 2024

Quality Gate Passed Quality Gate passed for 'openchallenges-app'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@rrchai rrchai merged commit 045c55c into Sage-Bionetworks:main Jun 6, 2024
10 checks passed
@rrchai rrchai deleted the fix-bugs-filter branch June 6, 2024 17:18
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.

[Bug] search dropdown filter UI shows "empty"
2 participants