Browse Source

updated to auto-assign category icon - phase 1

master
jk 3 years ago
parent
commit
9234c94899
  1. 6
      config.toml
  2. 5
      content/note/5fef8a61/index.md
  3. 2
      content/note/5fef9fd0/index.md
  4. 3
      content/note/5ff0e1e2/index.md
  5. 8
      themes/nipponalba/layouts/_default/list.html
  6. 8
      themes/nipponalba/layouts/_default/single.html
  7. 10
      themes/nipponalba/layouts/index.html
  8. 2
      themes/nipponalba/layouts/partials/taxonomy/categories.html
  9. 2
      themes/nipponalba/static/css/style.css

6
config.toml

@ -53,6 +53,7 @@ siteLogo = ""
keywords = ""
favicon = "favicon/"
pronouns = "she/her"
a = "testing"
[languages.en.Params]
@ -101,6 +102,11 @@ name = "Self Development"
weight = 600
url = "/category/self-development/"
[[languages.en.menu.main]]
name = "Future Plans"
weight = 700
url = "/category/future-plan/"
[languages.jp]
weight = 10

5
content/note/5fef8a61/index.md

@ -4,15 +4,14 @@ category:
- plant-based
- vegan
- 'milk alternatives'
- 2
date: '2021-01-01 20:47:29'
draft: false
posttype: note
slug: 5fef8a61
title: note
---
# Reading note
McGivney, A. (2020, January 29). Almonds are out. Dairy is a disaster. So what milk should we drink? *The Guardian*. https://www.theguardian.com/environment/2020/jan/28/what-plant-milk-should-i-drink-almond-killing-bees-aoe?CMP=fb_gu&utm_medium=Social&utm_source=Facebook#Echobox=1606824595
Plant-based milk produces less greenhouse gas than dairy milk, but it has its drawbacks e.g. bee deaths, land and water consumptions, unsustainable practices for farmers etc.
Plant-based milk produces less greenhouse gas than dairy milk, but it has its drawbacks e.g. bee deaths, land and water consumptions, unsustainable practices for farmers etc.
According to the article, among several types of milk alternatives, oat and soy milk perform well on sustainability metrics. Hazelnuts, hemp and flax are also good. I shall try them.

2
content/note/5fef9fd0/index.md

@ -12,7 +12,7 @@ title: note
**1. Reading books**
In December 2020, I was able to finish eight books on Kindle and Libby just because I had more time and energy for myself, and I think I finally started becoming fond of reading books. I am proud of this accomplishment as I have always had admiration for those who read a lot. Looking back, keeping a book journal definitely encouraged me to keep reading. I am also realising how important it is to output in my own words what I have gained from the books -it enhances my deeper thinking, memory improvement, and the network in my knowledge. So, to make reading as a habit, I aim to read 60 books (five per month) this year.
In December 2020, I was able to finish eight books on Kindle and Libby just because I had more time and energy for myself, and I think I finally started becoming fond of reading books. I am proud of this accomplishment as I have always had admiration for those who read a lot. Looking back, keeping a book journal definitely encouraged me to keep reading. I am also realising how important it is to output in my own words what I have gained from the books -it enhances my deeper thinking, memory improvement, and the network in my knowledge. So, to make reading as a habit, I aim to read 60 books (five per month) this year.
**2. Creating my personal website**

3
content/note/5ff0e1e2/index.md

@ -5,14 +5,13 @@ category:
- consumarism
- materialism
- 'electronic waste'
- 1
date: '2021-01-02 21:13:06'
draft: false
posttype: note
slug: 5ff0e1e2
title: note
---
**Documentary note**
I came to know the Light Bulb Conspiracy in reading A Life Less Throwaway by Tara Button. I was already familiar with the things reported in the documentary (e.g. a cartel in the 1920's to shorten lightbulb life expectancy, Bernard London in New York who advocate to make planned obsolescence mandatory to end the Great Depression, Apple having been sued etc.). The sequences of the massive amount of electronic waste in Ghana was devastating. It was reported that, while shipping e-waste to the Third World countries is forbidden by international law, developed countries continue to manage to dump them there as the wastes are declared as second-hand items. It was poignant to see school kids going to the garbage mountain, burning the plastic coverage of the electronic items to get metals inside for their living, and inhaling the toxic gas from the fire while hanging around.
Dannoritzer, C., Michelson, S. (Directors) & Úbeda, J. (Producer). (2010). *The Light Bulb Conspiracy* [Motion picture]. Television Española.

8
themes/nipponalba/layouts/_default/list.html

@ -8,6 +8,14 @@
{{ if eq .Type "note"}}
<span class="archive_content h-entry entry">
<span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "2 Jan 2006 15:04 GMT" }}</time></a></span>
<span class="headline"><h1>{{ range .Params.category }}
{{ if eq . "1"}}<h1><i class="fa fa-television" aria-hidden="true" title="Documentary note"></i> Documentary note</h1>{{ end }}
{{ if eq . "2"}}<h1><i class="fa fa-book" aria-hidden="true" title="Reading note"></i> Reading note</h1>{{ end }}
{{ if eq . "3"}}<h1><i class="fa fa-pencil-square-o" aria-hidden="true" title="TODO note"></i> TODO note</h1>{{ end }}
{{ if eq . "4"}}Test{{ end }}
{{ if eq . "5"}}Test{{ end }}
{{ if eq . "6"}}Test{{ end }}
{{ end }}</h1></span>
<section class="p-name e-content">{{ .Content }}</section>
<section class="info">
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><br/>

8
themes/nipponalba/layouts/_default/single.html

@ -5,6 +5,14 @@
</section>
<section class="post_content">
<span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "2 Jan 2006 15:04 GMT" }}</time></a></span>
<span class="headline"><h1>{{ range .Params.category }}
{{ if eq . "1"}}<h1><i class="fa fa-television" aria-hidden="true" title="Documentary note"></i> Documentary note</h1>{{ end }}
{{ if eq . "2"}}<h1><i class="fa fa-book" aria-hidden="true" title="Reading note"></i> Reading note</h1>{{ end }}
{{ if eq . "3"}}<h1><i class="fa fa-pencil-square-o" aria-hidden="true" title="TODO note"></i> TODO note</h1>{{ end }}
{{ if eq . "4"}}Test{{ end }}
{{ if eq . "5"}}Test{{ end }}
{{ if eq . "6"}}Test{{ end }}
{{ end }}</h1></span>
<section class="e-content"><section class="e-content p-name">
{{ .Content }}
{{ if eq .Type "photo"}}

10
themes/nipponalba/layouts/index.html

@ -8,10 +8,18 @@
<a rel="author" class="p-author h-card" rel="me" href="https://jon.kelbie.scot">{{ .Site.Params.Author }}<img src="/images/profile1.jpg"/></a>
</section>
<span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "2 Jan 2006 15:04 GMT" }}</time></a></span>
<span class="headline">{{ range .Params.category }}
{{ if eq . "1"}}<h1><i class="fa fa-television" aria-hidden="true" title="Documentary note"></i> Documentary note</h1>{{ end }}
{{ if eq . "2"}}<h1><i class="fa fa-book" aria-hidden="true" title="Reading note"></i> Reading note</h1>{{ end }}
{{ if eq . "3"}}<h1><i class="fa fa-pencil-square-o" aria-hidden="true" title="TODO note"></i> TODO note</h1>{{ end }}
{{ if eq . "4"}}Test{{ end }}
{{ if eq . "5"}}Test{{ end }}
{{ if eq . "6"}}Test{{ end }}
{{ end }}</span>
<section class="e-content">{{ .Content }}
</section>
<section class="info">
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><br/>
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><br/>
</section>
</article> {{ end }}
</section>

2
themes/nipponalba/layouts/partials/taxonomy/categories.html

@ -1,6 +1,6 @@
<ul class="categories">
{{- range $index, $el := . -}}
<li><a class="category p-category" href="{{ ( printf "category/%s/" ( . | urlize ) ) | relLangURL }}">{{ . }}</a></li>
{{if not (in (slice "1" "2" "3" "4" "5") .)}}<li><a class="category p-category" href="{{ ( printf "category/%s/" ( . | urlize ) ) | relLangURL }}">{{ . }}</a></li>{{ end }}
{{- end -}}
</ul>

2
themes/nipponalba/static/css/style.css

@ -274,6 +274,7 @@ width:100%;
padding: 18px 0px;
font-size: 14px;
display:flex;
margin: 0 auto;
}
nav li{
position: relative;
@ -389,6 +390,7 @@ main {
.site-info a{
color: var(--text-colour);
}
.index-note, .feed, .post, #response .h-cite,
.resume header, .workhistory, .education, .skills, .feeds {
width: 98%;

Loading…
Cancel
Save