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

Filter, Sort and Search Recipes + User Feed concurrent display of recipes #236

Merged
merged 4 commits into from
Dec 7, 2023

Conversation

BlessedLongsword
Copy link
Contributor

When the user is not logged in, they will see only 9 recipes:

image

If they scroll to the bottom, they will see this message:

image

And each button redirects to the corresponding page. When the user logs in now, they see this:

image

They can now click their profile image to go to their profile or, alternatively, can use the contextual dropdown menu when clicking on their username:

image

Typing in the search bar will dynamically filter recipes by name, following the backend model, where not only recipe titles are factored in, but also usernames of the creators and recipe ingredients:

image

image

image

image

clicking the filter funnel will prompt an off canvas where the user can select different filters:

image

When apply is clicked the filters are saved in the local storage and applied to the search, using the magic endpoint in the backend. Then, these filters appear as pills before the recipes list:
image

The condition for these pills to appear or not is based on the default filters, if any match the default corresponding filter, it will not be displayed. This is an exception with the ascending/descending filter, which is tied to the sort_by filter, and thus its visibility will depend on it. You can change the ascending/descending order or outright remove a filter using the icon on the left. This will update the recipes list and the local storage.

The clear filters button is used to restore to default values.

Last but not least, now recipes are retrieved dynamically, when reaching the end of the list, more list will be loaded, except if there are no more recipes left to retrieve.

If the user logs out, the recipes list changes to the previously mentioned one, where only 9 recipes sorted by rating appear.

@BlessedLongsword BlessedLongsword linked an issue Dec 7, 2023 that may be closed by this pull request
@BlessedLongsword
Copy link
Contributor Author

Regarding the responsiveness of the new features, it's not very responsive. Apologies.

@xvxnoah xvxnoah added the enhancement New feature or request label Dec 7, 2023
@BlessedLongsword BlessedLongsword linked an issue Dec 7, 2023 that may be closed by this pull request
Copy link
Contributor

@xvxnoah xvxnoah left a comment

Choose a reason for hiding this comment

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

Looks amazing to me, checks all acceptance criteria, and exceeded my expectations. Good job! 😎

@xvxnoah xvxnoah merged commit eb8a913 into develop Dec 7, 2023
3 checks passed
@xvxnoah xvxnoah added this to the Last Sprint milestone Dec 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment