-
-
Notifications
You must be signed in to change notification settings - Fork 878
Added Dynamic Search and Filter Button in Challenge List Page #4613
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
base: master
Are you sure you want to change the base?
Conversation
Although no specific issue was created for this feature i have developed this to improve the usability and navigation on the challenge list page |
@RishabhJain2018 Sir please review it !! |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #4613 +/- ##
==========================================
- Coverage 72.93% 67.90% -5.03%
==========================================
Files 83 21 -62
Lines 5368 3689 -1679
==========================================
- Hits 3915 2505 -1410
+ Misses 1453 1184 -269
... and 64 files with indirect coverage changes
... and 64 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @wahid18-maqs , Thanks for the feature. Can you please match the selected field
and Show filters
color to match the website theme?
if (data.next !== null) { | ||
var url = data.next; | ||
var slicedUrl = url.substring(url.indexOf('challenges/challenge'), url.length); | ||
var slicedUrl = url.substring(url.indexOf('challenges/challenge')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we changing this line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have removed url.length
since substring(startIndex)
already slices to the end by default, making the code cleaner without changing functionality — but I'll add it back now.
Matched the selected field and Show Filters color with the website theme, and re-added Recording.2025-04-28.200104.mp4 |
Hi @wahid18-maqs , Thanks for the fixes. Can we please do the same formatting changes for this filter? |
Sure @RishabhJain2018 Sir |
@RishabhJain2018 Sir, I have changed the filter formatting as discussed filter-modified-1.mp4 |
$scope = $rootScope.$new(); | ||
createController = function () { | ||
return $controller('ChallengeListCtrl', {$scope: $scope}); | ||
angular.module('evalai') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @wahid18-maqs , Can you please explain the code you are removing in the tests? and how you are adding the current tests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @RishabhJain2018 Sir I went through the test suite and cleaned up some old tests that were no longer relevant, as they didn’t match the current behavior of the ChallengeListCtrl controller
. Some of the features they tested had been deprecated or were no longer in use, so removing those tests helped keep everything organized. I’ve also added new tests to cover the current features, especially around filtering and sorting. These tests make sure that filtering works as expected with different inputs, sorting is accurate for both start and end dates, and that the UI displays everything correctly. On top of that, I’ve made sure the app properly handles API errors ( handleApiError
), so we can be confident that the app behaves as it should. Thank You!!
padding-top: 30px; | ||
padding-bottom: 10px; | ||
margin-bottom: 20px; | ||
margin-top: 0px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we have so many unecessary changes here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here the changes i have made to improve spacing and clarity and I also updated filter buttons and tabs to ensure the consistency while maintaining EvalAI code standards
…EvalAI into feat/search-filter
Changes made in Unit tests for challenge list controller
Screenshot |
@RishabhJain2018 Sir I have made updates to unit testing code and improved CSS styles while following the organization's code structure and conventions. |
Okay, thanks! Hey @akanshajain231999 , Can you please review this? |
Hi, @RishabhJain2018 Sir @akanshajain231999 Ma'am just checking in — are there any changes or updates you'd like me to make? |
Description
This PR introduces two new features to the Challenge List page on the EvalAI platform:
Motivation
The addition of the dynamic search function and filter button significantly improves the user experience when navigating the challenge list on EvalAI. With the increasing number of hosted challenges, it is essential to provide users with efficient ways to find relevant challenges. These features aim to enhance usability and accessibility, making EvalAI more user-friendly.
Changes Made in Files
frontend/src/views/web/challenge-list.html
frontend/src/js/controllers/challengeListCtrl.js
$scope.$apply()
and$timeout()
for safe asynchronous updates.vm.errorMessage
).start_date
andend_date
as Date objects, addedtime_zone
andgmt_zone
fields.vm.hasAppliedFilter
,vm.isFilterVisible
.frontend/tests/controllers-test/challengeListCtrl.test.js
handleApiError()
.processChallenges()
to enrich challenge data (timezone, creator mapping, date objects).vm.getAllResults()
.vm.scrollUp()
.frontend/src/css/modules/challenge.scss
Screenshots
Recording.2025-04-26.181836.mp4
Checklist: