-
-
Notifications
You must be signed in to change notification settings - Fork 833
Restrict size of image and video thumbnails #5682
Conversation
…e url preview changes
…illiamkray/matrix-react-sdk into develop
i'll just keep merging in |
@williamkray Still has some test failures. Could you also add some screenshots as well? |
i keep merging develop in, but it keeps failing those tests... which i haven't touched. this PR is only for a couple CSS changes. i'll keep trying but i have no idea what they're failing on. screenshot comparison added. |
@williamkray, as far as I can tell the CI is cloning your |
thanks @SimonBrandner , i didn't see that nor did i realize it would be tied to my version of the js-sdk which i haven't really touched. i've refreshed that, hopefully that fixes the testing issues next time i merge in react-sdk upstream development. |
i just noticed Anoa's comment in my screenshot fits in nicely with this pull request, haha! that was clearly posted when the develop.element.io had the previous PR added in. |
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.
The code looks fine, though this has conflicting opinions from design/product/management on whether it should be a thing or not.
Fixes #1520 |
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.
I'm a big fan of this change, however I think that any change to image/video sizing should strive to at least keep all different shapes of images "readable". An issue with just setting a smaller max height is that while it is quite a positive change for landscape images, portrait images become squashed and hard to glean information from.
Thus I think a better solution would be to set a max area for images, and then adapt their size based on that according to their aspect ratio, in order to maintain a consistent information density. It would be nice if such an approach could be used for videos as well, however I don't know if you're able to get the aspect ratio of a video ahead of time.
i definitely understand that perspective. i'm going to defend my approach here with three main points:
|
Thank you for the contribution! We've opted to go for a version of this with a setting given the tension between small & large thumbnails: #7017 |
While my previous PR included changes to the URL preview widget that didn't go over well, community response seemed overwhelmingly positive for the changes that made the image and video thumbnails smaller. This PR is just those two changes.
Original community discussion about the changes, for reference
However, it seems like this might still be up for conversation from the design team due to Matthew's response:
Before:
After:
Signed-off-by William Kray [email protected]