diff --git a/_config.yml b/_config.yml index 871edd53..3deae83e 100644 --- a/_config.yml +++ b/_config.yml @@ -33,6 +33,9 @@ collections: authors: output: true permalink: /authors/:path/ + community: + output: true + permalink: /community-blog/:title/ defaults: - scope: @@ -41,6 +44,12 @@ defaults: values: layout: "archive" type: "authors" + - scope: + path: "" + type: "community" + values: + layout: "post" + type: "community" # Pagination paginate: 6 diff --git a/_layouts/default.html b/_layouts/default.html index 2b32d4b3..9227dd8f 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -153,12 +153,20 @@ Library --> - {% if page.url == "/coc/" %} + {% if page.url == "/blog/" %} + + {% if page.url == "/community-blog/" %} + --> + + + + diff --git a/assets/css/main.scss b/assets/css/main.scss index b5f16b92..731ee029 100644 --- a/assets/css/main.scss +++ b/assets/css/main.scss @@ -12,3 +12,45 @@ @import "syntax" ; + +/* Exclusive Tabs for Home Page */ +.exclusive-tabs-header { + display: flex !important; + flex-direction: row !important; + border-bottom: 1px solid rgba(0, 0, 0, .125) !important; + margin-bottom: 27px; + padding: 0; +} +.exclusive-tab-link { + cursor: pointer !important; + opacity: 0.3 !important; + transition: all 0.3s ease; + margin-right: 40px !important; + padding-bottom: 20px !important; + display: inline-block !important; + border-bottom: 1px solid transparent !important; + margin-bottom: -1px !important; + font-weight: 700 !important; + font-size: 1.4rem !important; + color: #292b2c !important; +} +.exclusive-tab-link.is-active { + opacity: 1 !important; + border-bottom: 1px solid rgba(0,0,0,0.44) !important; +} +.exclusive-tab-link:hover { + opacity: 0.7 !important; + text-decoration: none !important; +} +.exclusive-pane:not(.is-visible) { + display: none !important; +} +.exclusive-pane.is-visible { + display: block !important; +} +.exclusive-content-area { + margin-top: 30px; +} +.pagination a { + cursor: pointer; +} diff --git a/blog.html b/blog.html index 9b383285..cd533855 100644 --- a/blog.html +++ b/blog.html @@ -1,6 +1,6 @@ --- layout: page -title: Blog +title: Monthly Meetup Blog description: List of all posts by "BangPypers – The Bangalore Python User Group". --- diff --git a/community-blog.html b/community-blog.html new file mode 100644 index 00000000..b0d7a04f --- /dev/null +++ b/community-blog.html @@ -0,0 +1,32 @@ +--- +layout: page +title: Community Blog +description: List of all posts in the Community Blog. +permalink: /community-blog/ +--- + + +
+ +
+ +
+ {% assign community_posts = site.community %} + {% assign sorted_posts = community_posts | reverse %} + {% for post in sorted_posts %} + {% assign currentDate = post.date | date: "%Y" %} + {% if currentDate != myDate %} + {% unless forloop.first %}{% endunless %} +

{{ currentDate }}

+
    + {% assign myDate = currentDate %} + {% endif %} +
  • {{ post.date | date: "%B %-d" }} - {{ post.title }}
  • + {% if forloop.last %}
{% endif %} + {% endfor %} +
+ +
+ +
diff --git a/index.html b/index.html index 37ed00d1..d22b4519 100644 --- a/index.html +++ b/index.html @@ -23,32 +23,107 @@

Featured

{% endif %} -
-
- -

All Posts

- +

+ Monthly Meetup Posts + Community Posts +

- -
- {% for post in paginator.posts %} - {% include postbox.html %} - {% endfor %} +
+ +
+
+ {% for post in paginator.posts %} + {% include postbox.html %} + {% endfor %} +
+ +
+
+ + {% include pagination.html %} + +
+
+ +
+
+ {% if site.community.size > 0 %} + {% assign sorted_community = site.community | reverse %} + {% for post in sorted_community %} + {% include postbox.html %} + {% endfor %} + {% else %} +

No community posts found.

+ {% endif %} +
+ + +
-
- -
-
- - {% include pagination.html %} - -
+