[SOLVED] Wrong Photo ration on Canvas photo in CB 2.0.1

9 years 5 months ago - 9 years 5 months ago #251708 by Wouter47
All the avatars of my users are 200 x 150 px (hxw)

However when I publisch the avatar (portait) in the canvas photo position the photo is publisched as 200 x 200.

Is this a bug or did I forgot something to keep the ration aspect?

Please Log in to join the conversation.

9 years 5 months ago #251766 by krileon
The canvas photo position scales the image based off width to 200px. Height will auto scale based off that to keep aspect ratio. The problem is this only really works well for squared images or landscape images. What the user has uploaded is a portrait sized image (height greater than width). I'll try to improve the CSS so portrait style won't lose aspect ratio, but I may not be able to support squared, landscape, and portrait all at once with CSS alone.

forge.joomlapolis.com/issues/4811


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

9 years 5 months ago #251776 by Wouter47
Replied by Wouter47 on topic Wrong Photo ration on Canvas photo in CB 2.0.1
Thanks for your reply. The photo ration is h:w=4:3. The ratio is kept correct in the userlist and when I place the profile photo elsewhere. Hope you can fix it soon, because this way I cannot implement CB version 2.0.

What is the css that supports the photo ratio in the canvas?

Please Log in to join the conversation.

9 years 5 months ago #251793 by krileon

The photo ration is h:w=4:3

Right, that's portrait (height greater than width), which the CSS was not designed for.

The ratio is kept correct in the userlist and when I place the profile photo elsewhere.

Only canvas photo display needs to enforce a size to keep with the design.I already have some ideas on how to improve this CSS for a nightly release sometime this week.

Hope you can fix it soon, because this way I cannot implement CB version 2.0.

I seriously can't see how this would stop you from using CB 2.0. It's a minor styling issue at best. Your photos are uploaded fine. The issue is entirely CSS based. The issue will be fixed in a nightly sometime this week as currently have other priorities (CB Connect upgrade finalization and release).

What is the css that supports the photo ratio in the canvas?

Width is being forced to 100%, it's the single cause of this issue. I will likely be removing this and limiting max width and height to 100% then moving the online status icon to a better location to avoid floating icon display due to smaller images.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

9 years 5 months ago #251828 by Wouter47
Replied by Wouter47 on topic Wrong Photo ration on Canvas photo in CB 2.0.1
Thanks Kyle for your quick response.

The member photo's are displayed wider than intended and I know my members. They do not like there heads look like they have been eating too much lately.

It would be verry welcome if you could create a correction somewhere this week. Please let me know.

Please Log in to join the conversation.

9 years 5 months ago #251844 by nant

Wouter47 wrote: Thanks for your reply. The photo ration is h:w=4:3. The ratio is kept correct in the userlist and when I place the profile photo elsewhere. Hope you can fix it soon, because this way I cannot implement CB version 2.0.

What is the css that supports the photo ratio in the canvas?


I have seen many sites (latest example youtube) that will totally reject an uploaded image if it is not in the proper dimensions.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.555 seconds

Facebook Twitter LinkedIn