Skip to content

Commit aa671fa

Browse files
Added get_project.html - include to obtain project objects.
Adjusted locations_variable_generator to use location.sponsor variable. Simplified liquid logic in post.html. Standardized post.md files. Added pandas.md project. Added project logo to the event list. Added pandas logo to images. Removed old title photo. Added versions for landscape and portrait modes of the new title photo. Modifying javascript to add active class to correct elements (in progress). Used new images as the title for the home page.
1 parent 1963029 commit aa671fa

39 files changed

+130
-121
lines changed

_includes/get_host_sponsor.html

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@
1111
Post object containing yml variable sponsors.
1212

1313
Returns:
14-
host_sponsor: sponsor object
14+
sponsor: sponsor object
1515
Object from collection sponsors.
1616
{% endcomment %}
1717

18-
{% assign host_sponsor_id = include.event.sponsors | first %}
19-
{% assign host_sponsor = site.sponsors | where:"obj_id", host_sponsor_id | first %}
18+
{% assign sponsor_id = include.event.sponsor %}
19+
{% assign sponsor = site.sponsors | where:"obj_id", sponsor_id | first %}
20+

_includes/get_project.html

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{% comment %}
2+
get_project.html (event):
3+
4+
Obtain project object for the event.
5+
6+
Get the event's foreign key project and use its first object in the array
7+
as project object.
8+
9+
Parameters:
10+
event: jekyll post object
11+
Post object containing yml variable project.
12+
13+
Returns:
14+
project: project object
15+
Object from collection projects.
16+
{% endcomment %}
17+
18+
{% assign project_id = include.event.project %}
19+
{% assign project = site.projects | where:"obj_id", project_id | first %}

_includes/locations_variable_generator.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
var locations = [
3737
{% for location in include.locations_array %}
3838
{% if location.is_post %}
39-
{% assign host_sponsor_id = location.sponsors | first %}
39+
{% assign host_sponsor_id = location.sponsor %}
4040
{% assign host_sponsor = site.sponsors | where:"obj_id", host_sponsor_id | first %}
4141
{% capture prefix %}
4242
"address": "{{ host_sponsor.address }}",

_layouts/post.html

Lines changed: 10 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -6,34 +6,12 @@
66
{% assign image = "static/images/events/default_image_800x800px.jpeg" %}
77
{% endif %}
88
{% include get_host_sponsor.html event = page %}
9-
{% for item in site.projects %}
10-
{% if item.obj_id == page.project %}
11-
{% assign project = item %}
12-
{% endif %}
13-
{% endfor %}
14-
{% for item in site.sponsors %}
15-
{% if item.obj_id == page.sponsor %}
16-
{% assign sponsor = item %}
17-
{% endif %}
18-
{% endfor %}
9+
{% include get_project.html event = page %}
1910
<html lang="en">
20-
<head>
21-
<style>
22-
.post__img-container {
23-
background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url("{{ site.baseurl }}/{{ image }}");
24-
}
25-
26-
@media (min-width: 769px) {
27-
.post__img-container {
28-
background-image: linear-gradient(75deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6) 80%, rgba(0, 0, 0, 0.6) 80%, black 87%, black 100%), url("{{ site.baseurl }}/{{ image }}");
29-
}
30-
}
31-
</style>
32-
</head>
3311
<body class="body">
3412
{% include navigation.html %}
3513
<main>
36-
<section id="post" class="post">
14+
<article class="post">
3715
<div class="container-fluid">
3816
<div class="row">
3917
<div class="post__content col-12">
@@ -51,20 +29,21 @@ <h2 class="post__title">Level: {{ page.level }}</h2>
5129
<p class="post_paragraph">More information about {{ project.name }}: <a href="{{ project.website }}">{{ project.website }}</a></p>
5230
<p class="post__paragraph">{{ page.content }}</p>
5331
<hr>
54-
<h2 class="post__address-title">Set up instructions</h2>
55-
{{ project.setup_html }}
32+
{% if project.setup_html %}
33+
<h2 class="post__address-title">Set up instructions</h2>
34+
{{ project.setup_html }}
35+
{% endif %}
5636
</div>
5737
<div class="post__info col-md-4">
5838
<h1 class="post__content-title">Location</h1>
59-
<p class="post__address-title">{{ host_sponsor.name }}</p>
39+
<p class="post__address-title">{{ sponsor.name }}</p>
6040
<a class="post__sponsor-container post__sponsor-link" href="{{ host_sponsor.link }}">
6141
<img class="post__sponsor-img"
62-
src="{{ site.baseurl }}/{{ host_sponsor.logo }}"
42+
src="{{ site.baseurl }}/{{ sponsor.logo }}"
6343
alt="Sponsor logo">
6444
</a>
6545
<p class="post__address">{{ page.date | date: "%e %B %Y" }}, {{ page.time }}</p>
66-
<!--<img class="post__sponsor-img" src="{{ site.baseurl}}/{{ host_sponsor.logo }}">-->
67-
<p class="post__address">{{ host_sponsor.address }}</p>
46+
<p class="post__address">{{ sponsor.address }}</p>
6847
<div id="chapters__map"></div>
6948
{% comment %}
7049
Create a javascript variable for use in the function adding map markers.
@@ -78,28 +57,8 @@ <h1 class="post__content-title">Location</h1>
7857
</script>
7958
</div>
8059
</div>
81-
<!--{% for sponsor in page.sponsors %}-->
82-
<!--{% assign sponsor_obj = site.sponsors | where:"obj_id", sponsor | first %}-->
83-
<!--<div class="row flex-nowrap">-->
84-
<!--<div class="post__sponsor-col col-md-12">-->
85-
<!--<div class="row">-->
86-
<!--<div class="post__logo-col col-sm-3 col-12">-->
87-
<!--<h3 class="post__sponsor-name">{{ sponsor_obj.name }}</h3>-->
88-
<!--<a class="post__sponsor-container post__sponsor-link" href="{{ sponsor_obj.link }}">-->
89-
<!--<img class="post__sponsor-img"-->
90-
<!--src="{{ site.baseurl }}/{{ sponsor_obj.logo }}"-->
91-
<!--alt="Sponsor logo">-->
92-
<!--</a>-->
93-
<!--</div >-->
94-
<!--<div class="post__sponsor-info-col col-12 col-sm-auto col-xl-7 ">-->
95-
<!--<p class="post__sponsor-content">{{ sponsor_obj.content}}</p>-->
96-
<!--</div>-->
97-
<!--</div>-->
98-
<!--</div>-->
99-
<!--</div>-->
100-
<!--{% endfor %}-->
10160
</div>
102-
</section>
61+
</article>
10362
{% include footer.html %}
10463
</main>
10564
{% include scripts.html %}

_posts/2017-10-04-Bokeh-As-A-Backend-For-Pandas.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@ date: 2017-10-04
66
time: "18:30"
77
meetup_link: https://www.meetup.com/Python-Sprints/events/243422372/
88
event_link:
9-
project: Pandas
9+
project: pandas
1010
image: static/images/events/pandas_bokeh_backend_harvey_nash_960x539px.jpeg
11-
sponsors:
12-
- harvey_nash
11+
sponsor: harvey_nash
1312
---
1413

1514
According to this recent blog post by [Stack Overflow](https://stackoverflow.com/), Python is declared as the fastest-growing major programming language.

_posts/2017-10-24-PyMC3.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@ date: 2017-10-24
66
time: "18:30"
77
meetup_link: https://www.meetup.com/Python-Sprints/events/244062594/
88
event_link:
9-
project: PyMC3
9+
project: pymc3
1010
image: static/images/events/pymc3_zopa_960x539px.jpeg
11-
sponsors:
12-
- zopa
11+
sponsor: zopa
1312
---
1413

1514
Probabilistic programming are a family of programming languages where a probabilistic model can be specified, in order to do inference over unknown variables.

_posts/2017-11-01-www.python.org-Part1.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ meetup_link: https://www.meetup.com/Python-Sprints/events/244388482/
88
event_link:
99
project: python.org
1010
image: static/images/events/python_dot_org_part1_bloomberg_960x539px.jpeg
11-
sponsors:
12-
- bloomberg
11+
sponsor: bloomberg
1312
---
1413

1514
This sprint part of a series (until the features are complete). That's probably 2 or 3 sprints in total. Every event is independent, and you don't need to attend the first part to attend the second (or the other way round).

_posts/2017-12-06-python-dateutil.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ meetup_link: https://www.meetup.com/Python-Sprints/events/245317647/
88
event_link:
99
project: date-util
1010
image: static/images/events/dateutil_bloomberg_960x539px.jpeg
11-
sponsors:
12-
- bloomberg
11+
sponsor: bloomberg
1312
---
1413

1514
This time we will be working in [python-dateutil](https://github.com/dateutil/dateutil), one of the most downloaded libraries from PyPI and the de-facto extension for date and times manipulation in Python.

_posts/2018-03-10-Pandas-Documentation-Sprint.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,9 @@ date: 2018-03-10
66
time: "10:00"
77
meetup_link: https://www.meetup.com/Python-Sprints/events/247097848/
88
event_link: https://python-sprints.github.io/pandas/
9-
project: Pandas
9+
project: pandas
1010
image: static/images/events/pandas_documentation_sprint_1280_720px.jpg
11-
sponsors:
12-
- bloomberg
13-
- python_software_foundation
14-
- numfocus
11+
sponsor: bloomberg
1512
---
1613

1714
Pandas is an open source Python library for data manipulation and analysis. Its popularity is skyrocketing, and it is becoming the de-facto standard for data science and data engineering. But the number of core developers and contributors did not grow as fast as its popularity, and things like the API documentation would benefit from some help.

_posts/2018-03-20-Pandas-Beginners-Friendly.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@ date: 2018-03-20
66
time: "18:30"
77
meetup_link: https://www.meetup.com/Python-Sprints/events/248711552/
88
event_link:
9-
project: Pandas
9+
project: pandas
1010
image:
11-
sponsors:
12-
- harvey_nash
11+
sponsor: harvey_nash
1312
---
1413
After the success of #pandasSprint, with around 500 participants, and almost 200 pull requests sent, we're back to our regular sprints.
1514
For the ones who missed it, you can get an idea on how it was checking this feed:

0 commit comments

Comments
 (0)