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

Use the popover property consistently across cards #3207

Conversation

cj12312021
Copy link
Collaborator

@cj12312021 cj12312021 commented Nov 29, 2022

For some strange reason, performer, studio, and tag cards don't use the popovers property to handle the popovers, while the gallery, image, movie, and scene cards do. This pull request fixes this inconsistency. With this fix, it is now possible to add simple CSS to fix the hovering popover issue than can sometimes be seen in cards.

With this fix, the margin-top: auto style on the hr element can now consistently position the popover at the bottom of the card. Lucie Novac's card shows the issue without this fix. Salee Lee's card was edited in the image below to simulate this fix.

Screenshot 2022-11-28 190946

@DogmaDragon
Copy link
Collaborator

How will popovers look when there are 100+ or 1000+ items attached? Like studios or popular tags?

@cj12312021
Copy link
Collaborator Author

It would behave the same as it did before:
Screenshot 2022-11-28 193613

@cj12312021
Copy link
Collaborator Author

cj12312021 commented Nov 29, 2022

Here are screenshots of tags from with the change.
Screenshot 2022-11-28 193947
(I did hack in the values to simliate overflow)

Also note that this change does not include the margin CSS I mentioned earlier. I intentionally excluded that CSS.

@DogmaDragon
Copy link
Collaborator

Here are screenshots of tags from with the change. Screenshot 2022-11-28 193947 (I did hack in the values to simliate overflow)

Also note that this change does not include the margin CSS I mentioned earlier. I intentionally excluded that CSS.

👍 sorry I was thinking about hover, not popover, been doing other things when this pinged and I completely misunderstood what was happening...

@cj12312021
Copy link
Collaborator Author

👍 sorry I was thinking about hover, not popover, been doing other things when this pinged and I completely misunderstood what was happening...

No worries

@WithoutPants WithoutPants added the improvement Something needed tweaking. label Nov 30, 2022
@WithoutPants WithoutPants added this to the Version 0.19.0 milestone Nov 30, 2022
@WithoutPants WithoutPants merged commit d2395e5 into stashapp:develop Nov 30, 2022
@ghost
Copy link

ghost commented Jan 3, 2023

This broke my css snipset so hard it cant be repaired :/
I used to hide the bottom part when not in "hover" but now that its has a different parent, it cant be done anymore...
https://discord.com/channels/559159668438728723/644934273459290145/1034948111614890065
I will need custom js to reposition it where it was before in the tree. Sad..

Also i dont understand why it is cleaner to get the button group outside of the card section. The button is part of the card section. This sounds like a dirty fix to your other issue

@cj12312021
Copy link
Collaborator Author

cj12312021 commented Jan 5, 2023

The card components were written with a popover attribute that, before the change, was only properly used by the movie, gallery, and scene cards. The inconsistency there made creating a clean recommendation/front page tricky when I initially did that work. At the time, I could only properly fix the spacing issue on the cards I mentioned earlier. This tweak is the difference between cards that look like:

Screenshot 2023-01-04 192040

Compared to:

Screenshot 2023-01-04 192102

I think it's hard to argue which of the 2 is better. If you want to share your CSS on discord, I could help you with a fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Something needed tweaking.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants