Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions app/assets/stylesheets/partials/_sponsors.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,3 @@
flex-wrap: wrap;
align-items: center;
}

.sponsor-header-margin {
margin-bottom: 35px;
}
4 changes: 2 additions & 2 deletions app/views/shared/_sponsors.html.haml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.row.align-items-center
- sponsors.each do |sponsor|
.col-4.col-md-3.col-lg-2.mt-3
= link_to image_tag(sponsor.avatar, class: 'small-image', alt: sponsor.name), sponsor.website, title: sponsor.name, class: 'd-inline-block'
.col-4.col-md-3.col-lg-2.mt-4.d-flex.justify-content-center
= link_to image_tag(sponsor.avatar, class: 'small-image mw-100', alt: sponsor.name), sponsor.website, title: sponsor.name, class: 'd-inline-block border-0'
15 changes: 5 additions & 10 deletions app/views/sponsors/index.html.haml
Original file line number Diff line number Diff line change
@@ -1,25 +1,20 @@
.stripe.reverse
.row
.large-12.columns
.col.col-lg-9
%h2 Sponsors
%p.lead
Without our sponsors running <strong>codebar</strong> would be impossible. They provide us with space, food and drinks, internet, and they also help us cover our running costs.
%p.lead
Thank you for sharing our dream of creating a more welcoming, equal and diverse tech industry.

%p
%p.mb-0
If you are interested in becoming a host please do get in touch with us at #{mail_to "hello@codebar.io", "hello@codebar.io"}
='.'

- ['gold', 'silver', 'bronze', 'community', 'standard'].each do |level|
- if @sponsor_levels[level]
.stripe.reverse
.row
.large-12.columns
%h3.sponsor-header-margin.text-center
.col
%h3.text-center
= sponsorship_level_title(level)
- @sponsor_levels[level].in_groups_of(6) do |grouped_sponsors|
.row.sponsor-row
- grouped_sponsors.compact.each do |sponsor|
.medium-2.small-4.columns.sponsor-image
= link_to image_tag(sponsor.avatar, class: "small-image", alt: sponsor.name), sponsor.website
= render partial: 'shared/sponsors', object: @sponsor_levels[level].compact
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice spot! If you want to take this one step further, I noticed that app/views/chapter/show.html.haml could br DRYed up as well using this partial…

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gnclmorais yep, it's coming up in a future PR

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:happy_dance: