-
Notifications
You must be signed in to change notification settings - Fork 4k
Fix card layout for cards without cover #2831
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
Conversation
|
Summary of the deployments: Version 1 (production)
Version 2 (experimental)
Test content |
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
'min-[432px]:grid-cols-none', | ||
'min-[432px]:grid-rows-[auto,1fr]', | ||
], | ||
cover |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cover | |
cover && coverIsLandscape |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No I want none of these classes when there is no cover – combining the statements would still render the portrait classes if there is no cover (that's the current bug)
If there's a better way to write this logic statement I'm open to it, I don't like this double ternary
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ha I missed the null
? coverIsLandscape | ||
? 'grid-rows-[auto,1fr]' | ||
: [ | ||
'grid-cols-[40%,_1fr]', | ||
'min-[432px]:grid-cols-none', | ||
'min-[432px]:grid-rows-[auto,1fr]', | ||
] | ||
: null, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nested ternaries are a pain for readability but I guess it's fine here
I accidentally broke card layouts without covers, here's a fix

