Skip to content

fix: update sorting options to use 'Featured' instead of 'Best Selling'#104

Merged
Alexandrbig1 merged 1 commit into
OpenCodeChicago:mainfrom
AparAgarwal:feature/sort-products
Oct 10, 2025
Merged

fix: update sorting options to use 'Featured' instead of 'Best Selling'#104
Alexandrbig1 merged 1 commit into
OpenCodeChicago:mainfrom
AparAgarwal:feature/sort-products

Conversation

@AparAgarwal
Copy link
Copy Markdown
Contributor

This pull request updates the product sorting options to replace "Best Selling" with "Featured" as the default and primary sort option in both the UI and sorting logic. The changes ensure consistency in naming and default behavior across the relevant components.

Sorting Option Updates:

  • Changed the label and field from "Best Selling" to "Featured" in the SORT_OPTIONS array in SortDropdown.jsx, making "Featured" the new default sort option.
  • Updated the default sortBy prop in the SortDropdown component from 'best_selling' to 'featured'.

Sorting Logic Adjustments:

  • Renamed the sorting case in the Products page from 'best_selling:desc' to 'featured:desc' and updated the corresponding comment to reflect the change. The sorting logic remains a placeholder that preserves the original order.

Copy link
Copy Markdown
Contributor

@Alexandrbig1 Alexandrbig1 left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution, and congrats on your PR being approved!
We’re excited to have your work as part of Open Code Chicago’s Hacktoberfest 2025 project.

@Alexandrbig1 Alexandrbig1 added frontend Tasks related to the frontend (React, Vite, TailwindCSS, UI components, pages) hacktoberfest Special issue for Hacktoberfest hacktoberfest-2025 Special issue for Hacktoberfest 2025 hacktoberfest-accepted This label indicates that a contribution has been accepted and counts toward Hacktoberfest rewards. react React components & UI logic labels Oct 10, 2025
@Alexandrbig1 Alexandrbig1 merged commit 51c2949 into OpenCodeChicago:main Oct 10, 2025
2 checks passed
@Alexandrbig1
Copy link
Copy Markdown
Contributor

@AparAgarwal, please check this issue: when opening the "Filter" tab it automatically closes on scroll. The tab should remain open until the user clicks the "x" button or clicks outside the filter menu. Also verify the design: the filter header must include an "x" close button and a top title that reads "Sort by".

filter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend Tasks related to the frontend (React, Vite, TailwindCSS, UI components, pages) hacktoberfest Special issue for Hacktoberfest hacktoberfest-2025 Special issue for Hacktoberfest 2025 hacktoberfest-accepted This label indicates that a contribution has been accepted and counts toward Hacktoberfest rewards. react React components & UI logic

Development

Successfully merging this pull request may close these issues.

Implement Sorting for Products API Implement Sort Functionality on All Products Page

2 participants