Closed kasugaijin closed 1 month ago
@kasugaijin Happy to start this one once the other is approved.
Go for it! I would say for this we don't need to test, actually. So don't worry about that. I am not a fan of tests that couple closely with UI elements as they are a pain to manage when changing the UI at all.
@kasugaijin
I now have the heart functionality on the Liked Pets page working the same way as on the Pets page. This means that when you remove the heart, the image does not disappear, which might not align with the intended goal of using the stream functionality in this context. Would you like me to change this behavior so that the image disappears when the heart is removed, or should I leave the functionality as it is?
https://github.com/user-attachments/assets/342f5146-2dcd-4942-904b-3afa28ae35fb
Hey @ErinClaudio let's just leave as it is. We can always add in the broadcast later to update the page, but that does add additional overhead (and I suspect some undesirable overhead because it requires we touch a model) and at this stage for MVP it's not necessary.
@kasugaijin I believe this can be marked complete per https://github.com/rubyforgood/pet-rescue/pull/912
Sign in as an adopter and then like some pets on the adoptable pets page. Then go to the dashboard and look at the Liked Pets link and you will see the liked pets. This issue is just to update the UI to make it look per the image below. Please use the existing avatar component. Please copy over the heart from the existing card along with the turbo stream so it will make the request to unlike or like the pet when you click the heart