-
-
Notifications
You must be signed in to change notification settings - Fork 171
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
Profile picture is distorted if not square #1779
Comments
We should make sure it is square than, maybe with a crop dialog like on android. |
I think the image could also be cropped to a circle, that would be nice! (E.g., Github has changed avatars from squares to circles recently.) |
I think that crop to square and show it in a circle (hiding overflowed part) would be better since apps like whatsapp or similar do that allowing the picture to be showed completely when clicking on it. With https://developer.mozilla.org/en-US/docs/Web/CSS/clip-path set in a box (block type html tag) where the image is loaded can be set easily. UPDATED: as you can see in the examples, the image fits a bigger part and the css property just "shows it" in the desired way. In this case, however, they applied the property directly to the image. |
Well, maybe I misread the issue and is just being used already, the thing is that I maintain my opinion about squares are better. |
or, maybe there is some css option that does this center+crop while keeping aspect ratio? that might be the simplest solution for now. and would probably also be needed for existing images or images from other sources. core could also force a square, however, as by the "enlarge" we do show all of the image there is some sense in keeping all details. |
Clip-path could do something better... ?? <.< |
Some more information about |
we could just crop it, I don't like css hacks to do hide the problem. |
Sorry. Just think in the other idea. |
I can't reproduce it on 1.38.1 |
just tried it, I can reproduce it, you need an image that does not have 1:1 aspect ratio. I think we really need some image cropper here. (but a good one without too many dependencies) |
fixes #1779 - a component to crop any image to a certain size by zooming and dragging the original to fit a predefined shape - this component is used in ProfileImageSelector by altering result of ImageSelector upload
The text was updated successfully, but these errors were encountered: