Skip to content
This repository was archived by the owner on May 12, 2025. It is now read-only.

Commit 1cd3e34

Browse files
authored
Merge pull request #92 from JudahSan/main
Fix sponsor logo alignment (mobile)
2 parents fe12d51 + 56e4d42 commit 1cd3e34

File tree

3 files changed

+36
-14
lines changed

3 files changed

+36
-14
lines changed

app/helpers/chapters_helper.rb

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,17 @@ module ChaptersHelper
1717
].freeze
1818

1919
FEATURED_SPONSORS = [
20-
{ image: 'sponsors/current/nairobits.png', link: 'https://www.nairobits.com/', alt: 'Nairobits' },
20+
{ image: 'sponsors/current/solutech_official.svg', link: 'https://solutech.co.ke', alt: 'Solutech' },
2121
{ image: 'sponsors/current/finplus.png', link: 'https://finplusgroup.com', alt: 'Finplus Group' },
2222
{ image: 'sponsors/current/app_signal.png', link: 'https://www.appsignal.com', alt: 'App Signal' },
23-
{ image: 'sponsors/current/friendly_rb.jpg', link: 'https://friendlyrb.com/', alt: 'FriendlyRB' },
23+
{ image: 'sponsors/current/ruby_central.png', link: 'https://rubycentral.org/', alt: 'Ruby Central' },
24+
2425
{ image: 'sponsors/current/kopo_kopo.png', link: 'https://kopokopo.co.ke', alt: 'Kopo Kopo' },
25-
{ image: 'sponsors/current/microverse.png', link: 'https://www.microverse.org/', alt: 'Microverse' },
2626
{ image: 'sponsors/current/planet_argon.png', link: 'https://www.planetargon.com', alt: 'Planet Argon' },
27-
{ image: 'sponsors/current/ruby_central.png', link: 'https://rubycentral.org/', alt: 'Ruby Central' },
28-
{ image: 'sponsors/current/solutech_official.svg', link: 'https://solutech.co.ke', alt: 'Solutech' },
29-
{ image: 'sponsors/current/kca.png', link: 'https://www.kcau.ac.ke', alt: 'KCA University' }
27+
{ image: 'sponsors/current/friendly_rb.jpg', link: 'https://friendlyrb.com/', alt: 'FriendlyRB' },
28+
{ image: 'sponsors/current/microverse.png', link: 'https://www.microverse.org/', alt: 'Microverse' },
29+
{ image: 'sponsors/current/kca.png', link: 'https://www.kcau.ac.ke', alt: 'KCA University' },
30+
{ image: 'sponsors/current/nairobits.png', link: 'https://www.nairobits.com/', alt: 'Nairobits' }
3031
].freeze
3132

3233
PREVIOUS_SPONSORS = [
Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,34 @@
1+
<!--<div class="container mx-auto px-20 bg-zinc-50">-->
2+
<!-- <h1 class="pt-16 text-4xl text-red-600 font-bold text-center">-->
3+
<!-- Featured Sponsors-->
4+
<!-- </h1>-->
5+
6+
<!-- <div class="grid md:grid-cols-2 grid-cols-2 lg:grid-cols-4 xl:grid-cols-4 gap-2 px-20 place-content-center">-->
7+
<%# featured_sponsors.each do |sponsor| %>
8+
<%#= link_to sponsor[:link], target: '_blank' do %>
9+
<!-- <div class="items-center justify-center w-36 h-40 card place-items-center">-->
10+
<%#= image_tag sponsor[:image], alt: sponsor[:alt] %>
11+
<!-- </div>-->
12+
<%# end %>
13+
<%# end %>
14+
<!-- </div>-->
15+
<!--</div>-->
16+
117
<div class="container mx-auto px-20 bg-zinc-50">
2-
<h1 class="pt-16 text-4xl text-red-600 font-bold text-center">
18+
<h1 class="pt-16 pb-12 text-4xl text-red-600 font-bold text-center">
319
Featured Sponsors
420
</h1>
521

6-
<div class="grid md:grid-cols-2 grid-cols-2 lg:grid-cols-4 xl:grid-cols-4 gap-2 px-20 place-content-center">
22+
<div class="grid grid-cols-1 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-3 gap-2 lg:ml-28">
723
<% featured_sponsors.each do |sponsor| %>
824
<%= link_to sponsor[:link], target: '_blank' do %>
9-
<div class="items-center justify-center w-36 h-40 card place-items-center">
10-
<%= image_tag sponsor[:image], alt: sponsor[:alt] %>
25+
<div class="flex items-center justify-center w-full">
26+
<div class="w-36 h-40 card">
27+
<%= image_tag sponsor[:image], alt: sponsor[:alt] %>
28+
</div>
1129
</div>
1230
<% end %>
1331
<% end %>
1432
</div>
15-
</div>
33+
34+
</div>

app/views/landing/home/_previous_sponsors.html.erb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,14 @@
33
Previous Sponsors
44
</h1>
55

6-
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-3 gap-2 lg:ml-28">
6+
<div class="grid grid-cols-1 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-3 gap-2 lg:ml-28">
77

88
<% previous_sponsors.each do |sponsor| %>
99
<%= link_to sponsor[:link], target: '_blank' do %>
10-
<div class="items-center justify-center w-36 h-40 card place-items-center">
11-
<%= image_tag sponsor[:image], alt: sponsor[:alt] %>
10+
<div class="flex items-center justify-center w-full">
11+
<div class="w-36 h-40 card">
12+
<%= image_tag sponsor[:image], alt: sponsor[:alt] %>
13+
</div>
1214
</div>
1315
<% end %>
1416
<% end %>

0 commit comments

Comments
 (0)