Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

taxonomy template changed #5

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion content/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Thanks to my schooling, I was introduced to programming when I was fifteen years

Aside from astrophysical research, I enjoy a range of activities like: reading philosophical novels; writing poetry; creating music; binging on - anime, sci-fi shows, documentaries, etc.; outdoor activities such as gardening, hiking, stargazing, etc.; and exploring open-source codes and cool software technologies. I also spend some time thinking about and working on climate action through personal lifestyle choices and pushing for systemic changes in my immediate environment. To read about some of my past side-projects [click here]({{< ref "/sideprojects" >}}).

I have filled this website with some of the poems that I have written over the years and some images from my gallery. I have also added some of the projects that I was able to bequeath life to through dedication and hard work. In other words, I am committing a small part of myself to a GitHub repository. If you want to **Astro-know-me!** [click here]({{< ref "/thoughts" >}}).
I have filled this website with some of the poems that I have written over the years and some images from my gallery. I have also added some of the projects that I was able to bequeath life to through dedication and hard work. In other words, I am committing a small part of myself to a GitHub repository. If you want to **Astro-know-me!** [click here]({{< ref "/poetry" >}}).

> Thoughts think me, thought I
But I am but a thought
Expand Down
10 changes: 5 additions & 5 deletions content/thoughts/_index.md → content/poetry/_index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Thoughts
title: Poetry
img_path: images/thoughts-bg.jpg
subtitle: Walk into the forest of thoughts, take all that you can carry into the realm of man
has_more_link: true
Expand All @@ -9,14 +9,14 @@ tagline: |-
take all that you can carry
into the realm of man
seo:
metatitle: Thoughts | Sriram Sankar
metatitle: Poetry | Sriram Sankar
description: Walk into the forest of thoughts, take all that you can carry into the realm of man
extra:
- name: 'og:type'
value: website
keyName: property
- name: 'og:title'
value: Thoughts
value: Poetry | Sriram Sankar
keyName: property
- name: 'og:description'
value: Walk into the forest of thoughts, take all that you can carry into the realm of man
Expand All @@ -28,9 +28,9 @@ seo:
- name: 'twitter:card'
value: summary_large_image
- name: 'twitter:title'
value: Sriram's thoughts
value: Poetry by Sriram
- name: 'twitter:description'
value: Sriram's thoughts
value: Poetry by Sriram
- name: 'twitter:image'
value: images/thoughts-bg.jpg
relativeUrl: true
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion content/sideprojects/asmechapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ title: ASME Student Chapter
subtitle: We did some cool things to offset some systemic problems and had a lot
of fun in the process. With the help of a global platform, we gained better
exposure to engineering.
categories: volunteering
categories: sideprojects
seo:
metatitle: How we got involved in engineering through ASME activities |
Sriram Sankar
Expand Down
2 changes: 1 addition & 1 deletion content/sideprojects/green-saao.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ excerpt: >-
a pair of lenses with a green filter.
date: '2022-06-08'
slug: greensaao
categories: volunteering
categories: sideprojects
thumb_img_path: images/greensaao.jpg
thumb_img_alt: Green SAAO - A sustainability movement
content_img_path: images/trash2work.jpg
Expand Down
2 changes: 1 addition & 1 deletion content/sideprojects/hazy-halo-music-production.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ thumb_img_path: images/humdrum-hazyhalo.jpg
thumb_img_alt: Humdrum Album Art Painted by Aiswarya
content_img_path: images/moonshine-hazyhalo.jpg
slug: hazyhalo
categories: poetry
categories: sideprojects
seo:
metatitle: Hazy Halo - Music Production
description: >-
Expand Down
2 changes: 1 addition & 1 deletion content/sideprojects/organizing-a-tedx-event.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ subtitle: "I write about my experience organizing a TEDx event and about the the
Breathtaking Disarray which was adopted from a poem that I had written in the past."
excerpt: "I write about my experience organizing a TEDx event and about the theme:
Breathtaking Disarray which was adopted from a poem that I had written in the past."
categories: volunteering
categories: sideprojects
date: '2022-06-06'
slug: tedx
thumb_img_path: images/breathtaking_disarray.jpg
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ excerpt: I trained a team of 50 students in various aspects of website building
and content marketing like WordPress website development and management,
content creation, social media marketing, graphics designing, database
creation, etc.
categories: volunteering
categories: sideprojects
date: '2022-06-05'
slug: mech-community
thumb_img_path: images/mechfisat.jpg
Expand Down
4 changes: 2 additions & 2 deletions data/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
"style": "link"
},
{
"label": "Thoughts",
"url": "/thoughts",
"label": "Poetry",
"url": "/poetry",
"style": "link"
},
{
Expand Down
2 changes: 2 additions & 0 deletions layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@
<meta name="google" content="notranslate" />
<meta name="description" content="{{ .Params.seo.description | default "" }}" />
{{ if .Params.math }}{{ partial "katex.html" . }}{{ end }}
<!--
{{ if .Params.seo.robots }}
<meta name="robots" content="{{ delimit $.Params.seo.robots "," }}">
{{ end }}
-->
{{ range $meta := .Params.seo.extra }}
{{ $key_name := $meta.keyName | default "name" }}
{{ if $meta.relativeUrl }}
Expand Down
2 changes: 1 addition & 1 deletion layouts/_default/blog.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<div class="post-feed, page-feed">
<article class="archive-feed">
{{ $posts := (.Site.GetPage "section" "/thoughts").Pages }}
{{ $posts := (.Site.GetPage "section" "/poetry").Pages }}
{{ $posts_count := $posts | len }}
{{ if gt $posts_count 0 }}
{{ $posts_sorted := $posts.ByDate.Reverse }}
Expand Down
17 changes: 17 additions & 0 deletions layouts/_default/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{{ define "content" }}
{{ $include_dict := dict "Site" .Site "page" . "image" .Params.img_path "tagline" .Params.tagline }}
{{ partial "header.html" $include_dict }}
<div id="content" class="site-content">
<main id="main" class="site-main inner">
<h1>{{ .Title }}</h1>
<ul>
{{ range .Data.Pages }}
<li><a href="{{ .Permalink }}">{{ .Title }}</a></li>
{{ end }}
</ul>
</main><!-- .site-main -->

{{ partial "footer.html" $include_dict }}

</div><!-- .site-content -->
{{ end }}
77 changes: 32 additions & 45 deletions layouts/_default/taxonomy.html
Original file line number Diff line number Diff line change
@@ -1,51 +1,38 @@
{{ define "content" }}
{{ $include_dict := dict "Site" .Site "page" . "image" .Params.img_path "tagline" .Params.tagline }}
{{ partial "header.html" $include_dict }}
<div id="content" class="site-content">
<main id="main" class="site-main inner">

{{ $include_dict := dict "Site" .Site "page" . "image" .Params.img_path "tagline" .Params.tagline }}
{{ partial "header.html" $include_dict }}
<div class="post-feed, page-feed">
<article class="archive-feed">
{{ range $name, $taxonomy := .Data.Terms }}
<article class="article-feed">
<header class="post-header">
<h2 class="post-title"><a href="{{ printf "/categories/%s/" $name }}">{{ $name }}</a></h2>
{{ with index $taxonomy.Pages 0 }}
<div class="post-meta">
{{ with .Params.description }}
<p>{{ . }}</p>
{{ end }}
</div>
{{ end }}
</header><!-- .post-header -->
{{ with index $taxonomy.Pages 0 }}
{{ with .Params.image }}
<a class="post-thumbnail" href="{{ printf "/categories/%s/" $name }}">
<img class="thumbnail, image-feed" src="{{ . }}" alt="{{ $name }}" />
</a>
{{ end }}
{{ end }}
</article><!-- .post -->
{{ end }}
</article><!-- .archive -->
</div><!-- .post-feed -->

<div id="content" class="site-content">
<main id="main" class="site-main inner">
</main><!-- .site-main -->

<div class="post-feed, page-feed">
<article class="archive-feed">
{{ $posts := (.Site.GetPage "section" "/thoughts").Pages }}
{{ $posts_count := $posts | len }}
{{ if gt $posts_count 0 }}
{{ $posts_sorted := $posts.ByDate.Reverse }}
{{ range $post := $posts_sorted }}

<article class="article-feed">
<header class="post-header">
<h2 class="post-title"><a href="{{ $post.Permalink }}" rel="bookmark">{{ $post.Params.title }}</a></h2>
<div class="post-meta">
Published on <time class="published"
datetime="{{ $post.Date | dateFormat "2006-01-02 15:04" }}">{{ $post.Date | dateFormat "January 02, 2006" }}</time>
</div>
</header><!-- .post-header -->
{{ if $post.Params.thumb_img_path }}
<a class="post-thumbnail" href="{{ $post.Permalink }}">
<img class="thumbnail, image-feed" src="{{ $post.Params.thumb_img_path | relURL }}" alt="{{ $post.Params.thumb_img_alt }}" />
</a>
{{ end }}
<div class="post-content">
<p>{{ $post.Params.excerpt }}</p>
</div><!-- .post-content -->
{{ if and (eq $.Params.has_more_link true) $.Params.more_link_text }}
<p class="read-more">
<a class="read-more-link" href="{{ $post.Permalink }}">{{ $.Params.more_link_text }} <span class="icon-arrow-right" aria-hidden="true"></span></a>
</p>
{{ end }}
</article><!-- .post -->

{{ end }}
{{ end }}
</article><!-- .archive -->
</div><!-- .post-feed -->

</main><!-- .site-main -->

{{ partial "footer.html" $include_dict }}

</div><!-- .site-content -->
{{ partial "footer.html" $include_dict }}

</div><!-- .site-content -->
{{ end }}
2 changes: 1 addition & 1 deletion layouts/partials/header_alt.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<header id="header-alt" class="site-header-alt">
<nav id="single-navigation" class="site-navigation-alt" aria-label="Main Navigation">
<a class="home-link" href="{{ "/thoughts" | relURL }}"><span class="icon-arrow-left"
<a class="home-link" href="{{ "/poetry" | relURL }}"><span class="icon-arrow-left"
aria-hidden="true"></span> All Articles</a>
</nav><!-- .site-navigation-alt -->
</header><!-- .site-header-alt -->
2 changes: 1 addition & 1 deletion layouts/partials/related.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ <h2>Related content</h2>
</div>
<div class="article-feed">
<div>
{{ $related := (where (.Site.RegularPages.Related .) "section" "/thoughts") | first 2 }}
{{ $related := (where (.Site.RegularPages.Related .) "section" "/poetry") | first 2 }}
{{ range $related }}
<div>
{{ $permalink := .Permalink }}
Expand Down
8 changes: 4 additions & 4 deletions static/admin/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ site_url: https://sriramsankar.netlify.app
logo_url: https://sriramsankar.netlify.app/static/images/srs-logo-black.svg

collections:
- name: "thoughts"
label: "thoughts"
- name: "poetry"
label: "poetry"
slug: "{{slug}}" #This slug variable is different from that of preview_path
preview_path: "blog/{{year}}/{{month}}/{{slug}}"
folder: "content/thoughts"
folder: "content/poetry"
identifier_field: title
create: true
extension: md
file: "content/thoughts/.md"
file: "content/poetry/.md"
format: frontmatter
fields:
- { label: "Title", name: "title", widget: "string" }
Expand Down