[feat] Duplicate plants warning + delete plants functionality #116
+216
−47
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What's new in this PR 🧑🌾
Description
When attempting to add plants that are already in their garden, shows a popup that there are plants to be added that are already in the garden (naming the plants), giving the user the option to proceed and add the plants again or press no and edit their details. Also added a delete button next to the plants in the review page of the add details
Screenshots
How to review
I think there are probably more efficient ways to write some of the backend functions, please let me know. Edge cases could be when having a mixture of duplicates and non duplicates and then removing some and trying again (works on my end but I doubt I tested everything).
Next steps
Maybe consolidating same plants with different seasons into the same card? Also, should they be redirected to plants page if they remove all plants from the add details?
Relevant links
Online sources
Related PRs
CC: @kylezryr