@@ -51,12 +51,16 @@ <h3 class="mission__statement">Provide mentorship and challenge for people of al
5151 < section class ="upcoming ">
5252 < div class ="row container-fluid ">
5353 < hr class ="upcoming-divider ">
54- < div class ="upcoming__img-container col-md-12 ">
55- < div class ="upcoming__content row ">
56- < div class ="upcoming__col col-md-5 col- 12 mr-auto ">
54+ < div class ="upcoming__img-container col-md-12 no-padding-x ">
55+ < div class ="row ">
56+ < div class ="col-12 no-padding-x ">
5757 < h2 class ="upcoming__title "> Upcoming Event</ h2 >
58+ </ div >
59+ </ div >
60+ < div class ="upcoming__content row with-padding-x ">
61+ < div class ="upcoming__col col-md-5 col-12 mr-auto ">
5862 < div class ="row ">
59- < div class ="no-gutters__col col-3 ">
63+ < div class ="no-gutters__col col-6 ">
6064 < h2 class ="post__label "> Event</ h2 >
6165 </ div >
6266 </ div >
@@ -65,9 +69,8 @@ <h2 class="post__label">Event</h2>
6569 {{ post.title }}
6670 </ div >
6771 </ div >
68-
6972 < div class ="row ">
70- < div class ="no-gutters__col col-3 ">
73+ < div class ="no-gutters__col col-6 ">
7174 < h2 class ="post__label "> Venue</ h2 >
7275 </ div >
7376 </ div >
@@ -77,7 +80,7 @@ <h2 class="post__label">Venue</h2>
7780 </ div >
7881 </ div >
7982 < div class ="row ">
80- < div class ="no-gutters__col col-3 ">
83+ < div class ="no-gutters__col col-6 ">
8184 < h2 class ="post__label "> Date</ h2 >
8285 </ div >
8386 </ div >
@@ -88,7 +91,7 @@ <h2 class="post__label">Date</h2>
8891 </ div >
8992 {% if post.project_logo %}
9093 < div class ="row ">
91- < div class ="no-gutters__col col-3 ">
94+ < div class ="no-gutters__col col-6 ">
9295 < h2 class ="post__label "> Project</ h2 >
9396 </ div >
9497 </ div >
@@ -101,56 +104,61 @@ <h2 class="post__label">Project</h2>
101104 </ div >
102105 {% endif %}
103106 </ div >
104- < div class ="upcoming__logo-col col-md-5 text-center ">
105- < div class ="upcoming__sponsor-list h-100 ">
106- < h2 class ="upcoming__sponsor-title "> Supported By</ h2 >
107- <!--HERE feed event sponsors only - we need sponsor objects not just the name.-->
108- <!--Build an array of site sponsors (all).-->
109- {% assign site_sponsors_all = "" | split: ',' %}
110- {% for sponsor in site.sponsors %}
111- {% assign site_sponsors_all = site_sponsors_all | push: sponsor %}
112- {% endfor %}
107+ < div class ="upcoming__col col-md-5 text-center ">
113108
114- <!--Build an array of sponsors for the event.-->
115- {% assign event_sponsors = "" | split: ',' %}
116- {% for sponsor in post.sponsors %}
117- {% for site_sponsor in site_sponsors_all %}
118- {% if site_sponsor.sponsor_id == sponsor %}
119- {% assign event_sponsors = event_sponsors | push: site_sponsor %}
120- {% endif %}
109+ < div class ="row ">
110+ < div class ="no-gutters__col col-6 ">
111+ < h2 class ="post__label "> Supported by</ h2 >
112+ </ div >
113+ </ div >
114+ < div class ="row ">
115+ < div class ="upcoming__event-title col-12 ">
116+ {% assign site_sponsors_all = "" | split: ',' %}
117+ {% for sponsor in site.sponsors %}
118+ {% assign site_sponsors_all = site_sponsors_all | push: sponsor %}
121119 {% endfor %}
122- {% endfor %}
123120
124- {% assign num_of_sponsors = event_sponsors | size %}
125- {% assign sponsors_remainder = num_of_sponsors | modulo: 2 %}
126-
127- {% if sponsors_remainder == 0 %}
128- {% assign num_of_sponsors_even = true %}
129- {% assign row_num_modifier = 1 %}
130- {% else %}
131- {% assign num_of_sponsors_even = false %}
132- {% assign row_num_modifier = 0 %}
133- {% endif %}
121+ <!--Build an array of sponsors for the event.-->
122+ {% assign event_sponsors = "" | split: ',' %}
123+ {% for sponsor in post.sponsors %}
124+ {% for site_sponsor in site_sponsors_all %}
125+ {% if site_sponsor.sponsor_id == sponsor %}
126+ {% assign event_sponsors = event_sponsors | push: site_sponsor %}
127+ {% endif %}
128+ {% endfor %}
129+ {% endfor %}
134130
135- {% assign num_of_rows = num_of_sponsors | divided_by: 2 | floor | minus: row_num_modifier %}
136- {% assign items_per_row = 1 %}
131+ {% assign num_of_sponsors = event_sponsors | size %}
132+ {% assign sponsors_remainder = num_of_sponsors | modulo: 2 %}
137133
138- {% for row in (0..num_of_rows) %}
139- {% if forloop.last and num_of_sponsors_even == false %}
140- {% assign items_per_row = 0 %}
134+ {% if sponsors_remainder == 0 %}
135+ {% assign num_of_sponsors_even = true %}
136+ {% assign row_num_modifier = 1 %}
137+ {% else %}
138+ {% assign num_of_sponsors_even = false %}
139+ {% assign row_num_modifier = 0 %}
141140 {% endif %}
142- < div class ="row ">
143- {% for col in (0..items_per_row) %}
144- {% assign sponsor_index = row | times: 2 | plus: col %}
145- {% assign sponsor = event_sponsors[sponsor_index] %}
146- < div class ="footer__sponsor-col col-md-12 col-lg-6 ">
147- < a class ="footer__sponsor-link " href ="{{ sponsor.sponsor_link }} ">
148- < img class ="footer__img " src ="{{ site.baseurl }}/{{ sponsor.sponsor_logo }} ">
149- </ a >
150- </ div >
151- {% endfor %}
152- </ div >
153- {% endfor %}
141+
142+ {% assign num_of_rows = num_of_sponsors | divided_by: 2 | floor | minus: row_num_modifier %}
143+ {% assign items_per_row = 1 %}
144+
145+ {% for row in (0..num_of_rows) %}
146+ {% if forloop.last and num_of_sponsors_even == false %}
147+ {% assign items_per_row = 0 %}
148+ {% endif %}
149+ < div class ="row ">
150+ {% for col in (0..items_per_row) %}
151+ {% assign sponsor_index = row | times: 2 | plus: col %}
152+ {% assign sponsor = event_sponsors[sponsor_index] %}
153+ < div class ="footer__sponsor-col col-md-12 col-lg-6 ">
154+ < a class ="footer__sponsor-link " href ="{{ sponsor.sponsor_link }} ">
155+ < img class ="footer__img " src ="{{ site.baseurl }}/{{ sponsor.sponsor_logo }} ">
156+ </ a >
157+ </ div >
158+ {% endfor %}
159+ </ div >
160+ {% endfor %}
161+ </ div >
154162 </ div >
155163 </ div >
156164 </ div >
0 commit comments