Support Users Directly Uploading Profile Pictures.

* Adds a `picture` attribute to `User`.
* Preserves Gravatar as a fallback option.
* Now, you should use `user.profile_picturer` instead of `gravatar_url`
* TODO: Ensure `profile_picture` handles sizing right for uploaded images.
This commit is contained in:
Michael Ball 2020-07-14 21:06:15 -07:00
parent b66f69599a
commit 3883188dcd
13 changed files with 43 additions and 18 deletions

View file

@ -1,7 +1,7 @@
.panel.panel-default.event-panel{ onClick: 'eventClicked(event, this);', "data-url" => "#{url_for(conference_program_proposal_path(@conference.short_title, event.id))}" }
.panel-body
- event.speakers_ordered.each do |speaker|
= image_tag speaker.gravatar_url, :class => "img-circle pull-right all-speaker-pic", |
= image_tag speaker.profile_picture, :class => "img-circle pull-right all-speaker-pic", |
:alt => speaker.name, |
:title => speaker.name |

View file

@ -10,8 +10,7 @@
= event.title
- event.speakers_ordered.each do |speaker|
= image_tag speaker.gravatar_url, :class => "img-circle pull-right speaker-pic", |
= image_tag speaker.profile_picture, :class => "img-circle pull-right speaker-pic", |
:alt => speaker.name, |
:title => speaker.name, |
:style => "height: #{ speaker_height(@rooms) }px; width: #{ speaker_width(@rooms) }px;"