Open-event-frontend: Automatic scaling feature for speakers photos

Created on 12 Jan 2020  Â·  24Comments  Â·  Source: fossasia/open-event-frontend

Is your feature request related to a problem? Please describe.
When speakers upload their photos in the system, the photos are not automatically scaled to a define size e.g 300 x 300px. When speakers are accepted, their photos appear in different size.

Describe the solution you'd like
All uploaded photos scaled to a default size no matter what is the original size of the photo.

Screen Shot 2020-01-12 at 06 48 07

bug

All 24 comments

@kushthedude @edenyay want to work on this .

@edenyay is it ok to use custom-css a little, all its need ?

@edenyay is it ok to use custom-css a little, all its need ?

Find the bug causing it rather than using css to change px

@kushthedude , i have checked from the semantic-ui git repo and found definition for ui medium image class . it is -
.ui.medium.images .image, .ui.medium.images img, .ui.medium.images svg, .ui.medium.image { width: @mediumWidth; height: auto; font-size: @medium; }
as you can see the height is set to auto, that's why i need to use custom css to over ride it .

if you want to see ui medium image definition , you can find here :https://github.com/Semantic-Org/Semantic-UI/blob/master/src/definitions/elements/image.less

/*--------------
     Sizes
---------------*/

.ui.mini.images .image,
.ui.mini.images img,
.ui.mini.images svg,
.ui.mini.image {
  width: @miniWidth;
  height: auto;
  font-size: @mini;
}
.ui.tiny.images .image,
.ui.tiny.images img,
.ui.tiny.images svg,
.ui.tiny.image {
  width: @tinyWidth;
  height: auto;
  font-size: @tiny;
}
.ui.small.images .image,
.ui.small.images img,
.ui.small.images svg,
.ui.small.image {
  width: @smallWidth;
  height: auto;
  font-size: @small;
}
.ui.medium.images .image,
.ui.medium.images img,
.ui.medium.images svg,
.ui.medium.image {
  width: @mediumWidth;
  height: auto;
  font-size: @medium;
}
.ui.large.images .image,
.ui.large.images img,
.ui.large.images svg,
.ui.large.image {
  width: @largeWidth;
  height: auto;
  font-size: @large;
}
.ui.big.images .image,
.ui.big.images img,
.ui.big.images svg,
.ui.big.image {
  width: @bigWidth;
  height: auto;
  font-size: @big;
}
.ui.huge.images .image,
.ui.huge.images img,
.ui.huge.images svg,
.ui.huge.image {
  width: @hugeWidth;
  height: auto;
  font-size: @huge;
}
.ui.massive.images .image,
.ui.massive.images img,
.ui.massive.images svg,
.ui.massive.image {
  width: @massiveWidth;
  height: auto;
  font-size: @massive;
}

@kushthedude please take a look here too .

Problem is with CSS, but try to use predefined CSS only

Or we use center crop for now, as release is also due with fixes for session form @iamareebjamal

You have to do both. Change in cropper won't fix old images

Actually we don't have a cropper for now in session speaker form!

On Thu, 16 Jan, 2020, 16:34 Areeb Jamal, notifications@github.com wrote:

You have to do both. Change in cropper won't fix old images

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLUFE3BI27ADLWWFPOTQ6A5KZA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJDVOSI#issuecomment-575100745,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLTGTEMIP5QTVHYQNH3Q6A5KZANCNFSM4KFVKXWA
.

You have to add that as well. Both have to be done

@iamareebjamal @kushthedude i have implemented the cropper for speaker form, it is working amazing :smile: and cropping the images to 300 x 300 px here is the full flow how it works - https://youtu.be/JpGALKQ0O0w

Nope it is center cropping what if speaker wants to select some other side
than centwr

On Sat, 18 Jan, 2020, 16:00 Sundaram Dubey, notifications@github.com
wrote:

@iamareebjamal https://github.com/iamareebjamal @kushthedude
https://github.com/kushthedude i have implemented the cropper for
speaker form, it is working amazing 😄 and cropping the images to 300 x
300 px here is the full flow how it works - https://youtu.be/JpGALKQ0O0w

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLUVKSMEXHHW4VW3EIDQ6LK5HA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVIDQ#issuecomment-575886350,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLVQRW2NTC5I76DA6XDQ6LK5HANCNFSM4KFVKXWA
.

Nope it is center cropping what if speaker wants to select some other side than centwr
…
On Sat, 18 Jan, 2020, 16:00 Sundaram Dubey, @.*> wrote: @iamareebjamal https://github.com/iamareebjamal @kushthedude https://github.com/kushthedude i have implemented the cropper for speaker form, it is working amazing and cropping the images to 300 x 300 px here is the full flow how it works - https://youtu.be/JpGALKQ0O0w — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#3794?email_source=notifications&email_token=AKQMTLUVKSMEXHHW4VW3EIDQ6LK5HA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVIDQ#issuecomment-575886350>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKQMTLVQRW2NTC5I76DA6XDQ6LK5HANCNFSM4KFVKXWA .

no, it's not only center cropping, selected image is like that , it is same as wizard cropper.

Other example?

On Sat, 18 Jan, 2020, 16:04 Sundaram Dubey, notifications@github.com
wrote:

Nope it is center cropping what if speaker wants to select some other side
than centwr
… <#m_5524081169392673120_>
On Sat, 18 Jan, 2020, 16:00 Sundaram Dubey, @.*> wrote: @iamareebjamal
https://github.com/iamareebjamal https://github.com/iamareebjamal
@kushthedude https://github.com/kushthedude
https://github.com/kushthedude i have implemented the cropper for speaker
form, it is working amazing and cropping the images to 300 x 300 px here is
the full flow how it works - https://youtu.be/JpGALKQ0O0w — You are
receiving this because you were mentioned. Reply to this email directly,
view it on GitHub <#3794
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLUVKSMEXHHW4VW3EIDQ6LK5HA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVIDQ#issuecomment-575886350>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLVQRW2NTC5I76DA6XDQ6LK5HANCNFSM4KFVKXWA
.

no, it's not only center cropping, selected image is like that , it is
same as wizard cropper.

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLV2IEEOSPZHLQQ5AVLQ6LLLNA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVJYI#issuecomment-575886561,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLTLBTU57CLQW5HA4XDQ6LLLNANCNFSM4KFVKXWA
.

Screenshot from 2020-01-18 16-05-18
Screenshot from 2020-01-18 16-05-25

@kushthedude is it ok?

Video with cropper moving to all corners in four direction

On Sat, 18 Jan, 2020, 16:08 Sundaram Dubey, notifications@github.com
wrote:

@kushthedude https://github.com/kushthedude is it ok?

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLQAKKDDIDSACDFBB3DQ6LL3RA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVL3Y#issuecomment-575886831,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLRUYSVZTP33YQSHOYLQ6LL3RANCNFSM4KFVKXWA
.

Video with cropper moving to all corners in four direction
…
On Sat, 18 Jan, 2020, 16:08 Sundaram Dubey, @.*> wrote: @kushthedude https://github.com/kushthedude is it ok? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#3794?email_source=notifications&email_token=AKQMTLQAKKDDIDSACDFBB3DQ6LL3RA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVL3Y#issuecomment-575886831>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKQMTLRUYSVZTP33YQSHOYLQ6LL3RANCNFSM4KFVKXWA .

@kushthedude here is updated video :https://youtu.be/dwNEKSJfba8

Working nice, make the PR

On Sat, 18 Jan, 2020, 16:16 Sundaram Dubey, notifications@github.com
wrote:

Video with cropper moving to all corners in four direction
… <#m_-2997685609569293617_>
On Sat, 18 Jan, 2020, 16:08 Sundaram Dubey, @.*> wrote: @kushthedude
https://github.com/kushthedude https://github.com/kushthedude is it ok?
— You are receiving this because you were mentioned. Reply to this email
directly, view it on GitHub <#3794
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLQAKKDDIDSACDFBB3DQ6LL3RA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVL3Y#issuecomment-575886831>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLRUYSVZTP33YQSHOYLQ6LL3RANCNFSM4KFVKXWA
.

https://youtu.be/dwNEKSJfba8

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-frontend/issues/3794?email_source=notifications&email_token=AKQMTLSFCAGEKBRPPD2G26DQ6LMXXA5CNFSM4KFVKXWKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJJVP4Q#issuecomment-575887346,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKQMTLR5N3LZMTPP6QZ2JHTQ6LMXXANCNFSM4KFVKXWA
.

thanks :pray:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mariobehling picture mariobehling  Â·  3Comments

dilpreetsio picture dilpreetsio  Â·  4Comments

codedsun picture codedsun  Â·  4Comments

iamareebjamal picture iamareebjamal  Â·  4Comments

hpdang picture hpdang  Â·  5Comments