aboutsummaryrefslogtreecommitdiff
path: root/layouts
diff options
context:
space:
mode:
authorKaran Jayachandra <mail@karanjayachandra.com>2026-02-01 20:01:56 +0100
committerKaran Jayachandra <mail@karanjayachandra.com>2026-02-01 20:01:56 +0100
commitf510077aaefb1477fad28563e2637c424332ae61 (patch)
tree2707f9d42a6bce50a8ebeec30b61aa1c2dbcb8a6 /layouts
parent28ca1aa004ee80b6325526db1479ba05acd22367 (diff)
Added the python post
Diffstat (limited to 'layouts')
-rw-r--r--layouts/_default/baseof.html58
-rw-r--r--layouts/_default/section.html19
-rw-r--r--layouts/_default/single.html9
3 files changed, 60 insertions, 26 deletions
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index d8c9aec..1e893be 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -1,28 +1,34 @@
<!DOCTYPE html>
-<html lang="en-gb">
- <head>
- <meta charset="utf-8">
- <meta name="description" content="Come collaborate to create the next generation of RF products. On this website you can find Karan's qualifications and projects." />
- <meta name="keywords" content="Karan, Jayachandra, RF, Signal Processing, Engineer">
- <meta name="author" content="Karan Jayachandra">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title> {{ site.Title }} </title>
- <link rel="stylesheet" href="/main.css">
- <link rel="icon" href="/favicon-light.png" type="image/x-icon">
- <link rel="icon" href="/favicon-light.png" type="image/x-icon" media="(prefers-color-scheme: light)">
- <link rel="icon" href="/favicon-dark.png" type="image/x-icon" media="(prefers-color-scheme: dark)">
- </head>
- <body>
- <nav>
- <ul>
- <a href="/"><li>Home</li></a>
- <a href="https://gitlab.com/KaranJayachandra"><li>Gitlab</li></a>
- <a href="https://karanjayachandra.gitlab.io/cv"><li>CV</li></a>
- <a href="https://www.linkedin.com/in/karanjayachandra"><li>LinkedIn</li></a>
- </ul>
- </nav>
- <main>
- {{ block "main" . }}{{ end }}
- </main>
- </body>
+<html>
+ <head lang="en-gb">
+ <meta charset="utf-8" />
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ {{- $title := ( .Title ) -}}
+ {{- $siteTitle := ( .Site.Title ) -}}
+ {{- if .IsHome -}}
+ <title> {{ $siteTitle }} </title>
+ {{- else -}}
+ <title> {{ $siteTitle }} | {{ $title }} </title>
+ {{- end -}}
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <meta name="description" content="{{ with .Description }}{{ . }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end }}" />
+ <meta name="keywords" content="Karan, Jayachandra, Notes">
+ <meta name="author" content="Karan Jayachandra">
+ <link rel="stylesheet" type="text/css" media="screen" href="https://karanj.com/main.css"/>
+ <link rel="icon" href="https://karanj.com/favicon-light.png" type="image/x-icon">
+ <link rel="icon" href="https://karanj.com/favicon-light.png" type="image/x-icon" media="(prefers-color-scheme: light)">
+ <link rel="icon" href="https://karanj.com/favicon-dark.png" type="image/x-icon" media="(prefers-color-scheme: dark)">
+ </head>
+ <body>
+ <nav>
+ <ul>
+ <a href="/"><li>Home</li></a>
+ <a href="https://gitlab.com/KaranJayachandra"><li>Gitlab</li></a>
+ <a href="https://karanjayachandra.gitlab.io/cv"><li>CV</li></a>
+ <a href="/Posts"><li>Posts</li></a>
+ </ul>
+ </nav>
+ <main> {{- block "main" . }}{{- end }} </main>
+ </body>
+ <p style="margin-bottom:1cm;"></p>
</html> \ No newline at end of file
diff --git a/layouts/_default/section.html b/layouts/_default/section.html
new file mode 100644
index 0000000..a27e808
--- /dev/null
+++ b/layouts/_default/section.html
@@ -0,0 +1,19 @@
+{{ define "main" }}
+<h1>{{ strings.Title .Section }}</h1>
+<table style="width: 100%">
+ <colgroup>
+ <col span="1" style="width: 10%;">
+ <col span="1" style="width: 30%;">
+ <col span="1" style="width: 60%;">
+ </colgroup>
+ {{ $pages := where .Site.RegularPages "Type" "in" .Site.Params.mainSections }}
+ {{ $paginator := .Paginate (where $pages "Params.hidden" "ne" true) }}
+ {{ range $index, $element := $paginator.Pages }}
+ <tr>
+ <td style="border: none; text-align: right;">{{ add $index 1 }}</td>
+ <td style="border: none; text-align: center;">{{ dateFormat "2006-01-02" $element.Date }}</td>
+ <td style="border: none;"><a href="{{ .RelPermalink }}">{{ $element.Title }}</a></td>
+ </tr>
+ {{ end }}
+</table>
+{{ end }} \ No newline at end of file
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
new file mode 100644
index 0000000..379bdc5
--- /dev/null
+++ b/layouts/_default/single.html
@@ -0,0 +1,9 @@
+{{ define "main" }}
+<article>
+ <h1>{{ .Title }}</h1>
+ <div><time>{{ dateFormat ":date_medium" .Date }}</time></div>
+ {{ .Content }}
+</article>
+<hr style="border-bottom: dotted 1px; border-top: none;" >
+<footer>Back to <a href="/Posts">Posts<a></footer>
+{{ end }} \ No newline at end of file