Skip to content

Commit 28ad9d9

Browse files
authored
Merge pull request #25 from Netcentric/development-circle
Add development circle posts
2 parents 8a98c52 + 610e1af commit 28ad9d9

File tree

6 files changed

+67
-4
lines changed

6 files changed

+67
-4
lines changed

data/homepage.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,14 @@ blog:
3636
subtitle : "Updates and milestones of our open source projects"
3737
# blog post comes from 'content/blog'
3838

39-
################################ Blog ###################################
39+
######################### Development Circle ##############################
40+
developmentcircle:
41+
enable : true
42+
title : "Development Circle"
43+
subtitle : ""
44+
url: "https://www.netcentric.biz/insights/jcr:content.blogposts.developer-circle.json"
45+
46+
################################ Careers ###################################
4047
careers:
4148
enable : true
4249
title : "Careers"

themes/influencer-hugo/assets/scss/templates/_blog.scss

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,11 @@
8585
.page-item:last-child .page-link {
8686
border-radius: 0;
8787
}
88+
}
89+
90+
#developmentcircle {
91+
.card-footer {
92+
border-style: none;
93+
background-color: transparent;
94+
}
8895
}

themes/influencer-hugo/layouts/_default/post.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
</span>
2222
</span>
2323
</div>
24-
<h3 class="h4 mt-2 mb-3"><a href="{{ .Permalink }}">{{ .Title | markdownify }}</a></h3>
24+
<h3 class="h4 mt-2 mb-3"><a href="{{ .Permalink }}" title="{{ .Title | markdownify }}">{{ .Title | markdownify }}</a></h3>
2525
<div class="d-block font-italic mb-4">
2626
{{ .Summary }}..
2727
</div>

themes/influencer-hugo/layouts/_default/single.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,8 @@
3838
</div>
3939
</section>
4040

41+
{{ if .Site.Data.homepage.developmentcircle.enable }}
42+
{{- partial "development-circle.html" . -}}
43+
{{ end }}
44+
4145
{{ end }}

themes/influencer-hugo/layouts/index.html

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,6 @@ <h3 class="h4 card-title repo-title">
108108
{{ end }}
109109
{{ end }}
110110

111-
112111
{{ if .Site.Data.homepage.blog.enable }}
113112
<section class="section blog-home border-top" id="blog">
114113
<div class="container">
@@ -123,7 +122,7 @@ <h2 class="text-lg mb-3">{{ .title | markdownify }}</h2>
123122
</div>
124123
{{ end }}
125124
<div class="row">
126-
{{ range first 3 (where .Site.RegularPages "Type" "post")}}
125+
{{ range first 3 (where .Site.RegularPages "Type" "post") }}
127126
<div class="col-xl-4">
128127
{{ .Scratch.Set "blog" false }}
129128
{{ .Render "post" }}
@@ -137,4 +136,8 @@ <h2 class="text-lg mb-3">{{ .title | markdownify }}</h2>
137136
</section>
138137
{{ end }}
139138

139+
{{ if .Site.Data.homepage.developmentcircle.enable }}
140+
{{- partial "development-circle.html" . -}}
141+
{{ end }}
142+
140143
{{ end }}
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<section class="section blog-home border-top" id="developmentcircle">
2+
<div class="container">
3+
{{ with .Site.Data.homepage.developmentcircle }}
4+
<div class="row justify-content-center">
5+
<div class="col-lg-6">
6+
<div class="section-heading text-center">
7+
<h2 class="text-lg mb-3">{{ .title | markdownify }}</h2>
8+
<p>{{ .subtitle | markdownify }}</p>
9+
</div>
10+
</div>
11+
</div>
12+
13+
<div class="card-deck">
14+
{{ $repo := (getJSON .url) }}
15+
{{ range first 3 $repo }}
16+
<div class="blog-item card mb-4 border-0">
17+
{{ if .image }}
18+
<a href="{{ .url }}" title="{{ .title | markdownify }}"><img src="{{ .image | relURL }}" alt="{{ .title | markdownify }}" class="img-fluid w-100" rel="nofollow"></a>
19+
{{ end }}
20+
<div class="blog-item-content p-4">
21+
<div class="blog-meta mb-2 small">
22+
<span class="d-flex align-items-center text-black mr-4">
23+
<img class="icon mr-2" alt="Clock icon" src="/images/icons/clock.svg" />
24+
<span class="d-inline-block">{{ (time .date).Format "January 02, 2006" }}</span>
25+
</span>
26+
27+
<span class="d-flex align-items-center text-black mr-3">
28+
<img class="icon mr-2" alt="Person icon" src="/images/icons/person.svg" />
29+
<span class="d-inline-block">by {{ .authors }}</span>
30+
</span>
31+
</div>
32+
<h3 class="h4 mt-2 mb-3"><a href="{{ .url }}" title="{{ .title | markdownify }}">{{ .title | markdownify }}</a></h3>
33+
<div class="d-block font-italic mb-4">
34+
{{ .excerpt | plainify | truncate 100 }}
35+
</div>
36+
</div>
37+
</div>
38+
{{ end }}
39+
{{ end }}
40+
</div>
41+
</div>
42+
</section>

0 commit comments

Comments
 (0)