add yesterdays and todays posts
3
.gitmodules
vendored
@ -1,3 +0,0 @@
|
||||
[submodule "themes/gokarna"]
|
||||
path = themes/gokarna
|
||||
url = https://github.com/gokarna-theme/gokarna-hugo.git
|
||||
@ -1,11 +1,13 @@
|
||||
---
|
||||
date: {{ .Date }}
|
||||
description: ""
|
||||
draft: false
|
||||
lastmod: {{ .Date }}
|
||||
showTableOfContents: true
|
||||
tags: [ ]
|
||||
type: "post"
|
||||
title: "{{ replace .Name "-" " " | title }}"
|
||||
image: ""
|
||||
image: "images/"
|
||||
image_alt: ""
|
||||
---
|
||||
|
||||
|
||||
112
config.toml
@ -4,7 +4,6 @@ title = "Foss Cat"
|
||||
theme = "gokarna"
|
||||
enableRobotsTXT= true
|
||||
enableEmoji = true
|
||||
# code highlighting: use CSS classes so customHeadHTML can override colors
|
||||
# pygmentsStyle = "catppuccin-frappe"
|
||||
|
||||
[params]
|
||||
@ -21,8 +20,8 @@ customHeadHTML = '''
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
|
||||
<link rel="manifest" href="/site.webmanifest">
|
||||
<!-- Maple Mono font via fontsource CDN -->
|
||||
<style>
|
||||
/* --- Maple Mono font --- */
|
||||
@font-face {
|
||||
font-family: 'Maple Mono';
|
||||
font-style: normal;
|
||||
@ -50,114 +49,6 @@ customHeadHTML = '''
|
||||
html, body, code, pre, .post-content, .post-title {
|
||||
font-family: 'Maple Mono', monospace !important;
|
||||
}
|
||||
|
||||
/* --- Kimber (base16) theme: Light mode overrides --- */
|
||||
:root {
|
||||
--light-primary-color: 255, 255, 230; /* base07 #FFFFE6 warm cream */
|
||||
--light-secondary-color: #C3C3B4; /* base06 borders/dividers */
|
||||
--light-tertiary-color: #222222; /* base00 code block bg */
|
||||
--light-text-color: #222222; /* base00 text */
|
||||
}
|
||||
|
||||
/* Light mode: header shadow */
|
||||
.header-shadow {
|
||||
box-shadow: rgb(195, 195, 180) 0px -1px 0px 0px inset;
|
||||
}
|
||||
/* Light mode: blockquote text */
|
||||
blockquote {
|
||||
color: #5A5A5A; /* base04 */
|
||||
}
|
||||
/* Light mode: post dates */
|
||||
.post-date {
|
||||
color: #5A5A5A; /* base04 */
|
||||
}
|
||||
|
||||
/* --- Kimber syntax highlighting (base16 palette) --- */
|
||||
/* Background */
|
||||
.bg { color: #DEDEE7; background-color: #222222; }
|
||||
.chroma { color: #DEDEE7; background-color: #222222; }
|
||||
/* Line infrastructure */
|
||||
.chroma .lnlinks { outline: none; text-decoration: none; color: inherit; }
|
||||
.chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
|
||||
.chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
|
||||
.chroma .hl { background-color: #313131; } /* base01 highlight */
|
||||
.chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em; color: #5A5A5A; } /* base04 */
|
||||
.chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em; color: #5A5A5A; } /* base04 */
|
||||
.chroma .line { display: flex; }
|
||||
/* Keywords - base0E #86CACD (light teal) */
|
||||
.chroma .k { color: #86CACD; }
|
||||
.chroma .kc { color: #86CACD; }
|
||||
.chroma .kd { color: #86CACD; }
|
||||
.chroma .kn { color: #86CACD; }
|
||||
.chroma .kp { color: #86CACD; }
|
||||
.chroma .kr { color: #86CACD; }
|
||||
.chroma .kt { color: #D8B56D; } /* base0A types */
|
||||
/* Names */
|
||||
.chroma .na { color: #537C9C; } /* base0D attributes */
|
||||
.chroma .nc { color: #D8B56D; } /* base0A classes */
|
||||
.chroma .no { color: #476C88; } /* base09 constants */
|
||||
.chroma .nd { color: #D8B56D; } /* base0A decorators */
|
||||
.chroma .ni { color: #DEDEE7; } /* base05 entities */
|
||||
.chroma .ne { color: #C88C8C; } /* base08 exceptions */
|
||||
.chroma .nl { color: #DEDEE7; } /* base05 labels */
|
||||
.chroma .nn { color: #D8B56D; } /* base0A namespaces */
|
||||
.chroma .nt { color: #C88C8C; } /* base08 tags */
|
||||
.chroma .nb { color: #DEDEE7; } /* base05 builtins */
|
||||
.chroma .bp { color: #DEDEE7; } /* base05 builtin pseudo */
|
||||
.chroma .nv { color: #C88C8C; } /* base08 variables */
|
||||
.chroma .vc { color: #C88C8C; } /* base08 */
|
||||
.chroma .vg { color: #C88C8C; } /* base08 */
|
||||
.chroma .vi { color: #C88C8C; } /* base08 */
|
||||
.chroma .vm { color: #C88C8C; } /* base08 */
|
||||
.chroma .nf { color: #537C9C; } /* base0D functions */
|
||||
.chroma .fm { color: #537C9C; } /* base0D */
|
||||
/* Strings - base0B #99C899 (sage green) */
|
||||
.chroma .s { color: #99C899; }
|
||||
.chroma .sa { color: #99C899; }
|
||||
.chroma .sb { color: #99C899; }
|
||||
.chroma .sc { color: #99C899; }
|
||||
.chroma .dl { color: #99C899; }
|
||||
.chroma .sd { color: #99C899; font-style: italic; }
|
||||
.chroma .s2 { color: #99C899; }
|
||||
.chroma .se { color: #78B4B4; } /* base0C escape chars */
|
||||
.chroma .sh { color: #99C899; }
|
||||
.chroma .si { color: #78B4B4; } /* base0C interpolation */
|
||||
.chroma .sx { color: #99C899; }
|
||||
.chroma .sr { color: #78B4B4; } /* base0C regex */
|
||||
.chroma .s1 { color: #99C899; }
|
||||
.chroma .ss { color: #99C899; }
|
||||
/* Numbers - base09 #476C88 (steel blue) */
|
||||
.chroma .m { color: #476C88; }
|
||||
.chroma .mb { color: #476C88; }
|
||||
.chroma .mf { color: #476C88; }
|
||||
.chroma .mh { color: #476C88; }
|
||||
.chroma .mi { color: #476C88; }
|
||||
.chroma .il { color: #476C88; }
|
||||
.chroma .mo { color: #476C88; }
|
||||
/* Operators - base05 #DEDEE7 */
|
||||
.chroma .o { color: #DEDEE7; }
|
||||
.chroma .ow { color: #86CACD; } /* base0E operator words */
|
||||
/* Comments - base03 #644646 (dusty mauve) */
|
||||
.chroma .c { color: #644646; font-style: italic; }
|
||||
.chroma .ch { color: #644646; font-style: italic; }
|
||||
.chroma .cm { color: #644646; font-style: italic; }
|
||||
.chroma .c1 { color: #644646; font-style: italic; }
|
||||
.chroma .cs { color: #644646; font-style: italic; }
|
||||
.chroma .cp { color: #D8B56D; } /* base0A preprocessor */
|
||||
.chroma .cpf { color: #99C899; } /* base0B preproc file */
|
||||
/* Generic */
|
||||
.chroma .gd { color: #C88C8C; } /* base08 deleted */
|
||||
.chroma .ge { font-style: italic; }
|
||||
.chroma .gr { color: #C88C8C; } /* base08 error */
|
||||
.chroma .gh { color: #537C9C; font-weight: bold; } /* base0D heading */
|
||||
.chroma .gi { color: #99C899; } /* base0B inserted */
|
||||
.chroma .go { color: #644646; } /* base03 output */
|
||||
.chroma .gp { color: #644646; } /* base03 prompt */
|
||||
.chroma .gs { font-weight: bold; }
|
||||
.chroma .gu { color: #78B4B4; font-weight: bold; } /* base0C subheading */
|
||||
.chroma .gt { color: #C88C8C; } /* base08 traceback */
|
||||
.chroma .gl { text-decoration: underline; }
|
||||
.chroma .w { color: #555D55; } /* base02 whitespace */
|
||||
</style>
|
||||
'''
|
||||
# customFooterHTML = '<p>foot123</p>'
|
||||
@ -167,7 +58,6 @@ avatarSize = "size-s"
|
||||
numberPostsOnHomePage = 5
|
||||
showPostsOnHomePage = "recent"
|
||||
|
||||
|
||||
[params.meta]
|
||||
favicon = true
|
||||
svg = false
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
## Hello Weary Traveler
|
||||
No tracking or data collection. Just my blog, my thoughts.
|
||||
|
||||
Took alot of effort to fetch those bytes, hope I have something here worth your while.
|
||||
Took effort to fetch these bytes, hope I have something here worth your while.
|
||||
|
||||
26
content/posts/dog-based-search-path.md
Normal file
@ -0,0 +1,26 @@
|
||||
---
|
||||
date: 2026-02-23T00:53:05-07:00
|
||||
description: "Wondering what sort of algorithm my dog uses for navigation"
|
||||
image: "/images/otto-on-nature-path-algorithm.jpg"
|
||||
lastmod: 2026-02-23T01:08:53-07:00
|
||||
showTableOfContents: false
|
||||
tags: ["dogs", "optimization"]
|
||||
title: "Dog Based Search Path"
|
||||
type: "post"
|
||||
---
|
||||
|
||||
I was walking today on my preferred route.
|
||||
|
||||
I can leave my house, walk through a park behind it, cross a neighborhood road, walk through a "nature park" (where the nature is left to do its thing), cross a church parking lot, then take a canal-like path through tall natural grasses back to my neighborhood. Then its just some sidewalks to get back home.
|
||||
|
||||
Its wonderful! It helps me feel like I'm actually out in nature and escape from suburban sprawl.
|
||||
|
||||
While walking along the path, Otto came running up to check in with me, as he does after having sufficiently strayed off.
|
||||
|
||||
The path seems like it was a part of a pond or lake shore, as there is a steep drop off on one side. Otto happened to be on this side, and as he approached, I could see the "path" through many bushes and up a very steep, albiet short, ridge wall. I thought quickly and efficiently to myself that he would not be able to scale it.
|
||||
|
||||
Despite my extremely based and factual take, Otto charged ahead. And with little more effort than he noramlly gives while sprinting around, he crested and came to pant next to me with such ease!
|
||||
|
||||
Our drastically different calculus made me wonder. I wondered if dogs have some complex decision hierarchy like we do. I wondered if he just tried the first path he could see, whether or not it was viable.
|
||||
|
||||
I remember also reading _Entangled Life_ by Merlin Sheldrake, and hearing how slime molds perform various search algorithms in mazes to find food. I wonder how many biological processes should be mapped more frequently to the world of computure science!
|
||||
@ -1,12 +1,12 @@
|
||||
---
|
||||
date: 2025-03-03T09:19:07-07:00
|
||||
description: "I learned the importance of taking time away from the computer in software development"
|
||||
lastmod: 2025-03-03T09:19:07-07:00
|
||||
lastmod: 2026-02-23T01:08:53-07:00
|
||||
showTableOfContents: true
|
||||
type: "post"
|
||||
title: "TIL: Hammock Driven Development"
|
||||
image: "images/hammock.jpg"
|
||||
alt: "hammock with a cat"
|
||||
image_alt: "hammock with a cat"
|
||||
tags: ["clojure", "practices", "rich hickey", "til"]
|
||||
---
|
||||
|
||||
|
||||
78
content/posts/seeing-the-blind-men-and-the-elephant.md
Normal file
@ -0,0 +1,78 @@
|
||||
---
|
||||
date: 2026-02-21T19:52:06-07:00
|
||||
description: "An old parable poorly applied"
|
||||
image: "images/elephant-and-blind-men.png"
|
||||
image_alt: "Still of an elephant and blind men from the animated short video Discovering Truth by the LDS YouTube channel."
|
||||
lastmod: 2026-02-23T01:08:53-07:00
|
||||
showTableOfContents: false
|
||||
tags: ["philosophy", "buddhism", "truth"]
|
||||
title: "Seeing the Blind Men and the Elephant"
|
||||
type: "post"
|
||||
---
|
||||
|
||||
# Which Man is Blind?
|
||||
|
||||
A few days ago I listened to [an interview by Alex O'Connor (YouTube)](https://www.youtube.com/watch?v=wCo7QozGKWA&pp=ygUMYWxleCBvY29ubm9y) with the Hindu monk [Swami Sarvapriyananda (Wikipedia)](https://en.wikipedia.org/wiki/Swami_Sarvapriyananda) (Swami in his name is a title, much like a Father or Bishop in Christian practices).
|
||||
|
||||
In the interview, Swami Sarvapriyananda mentioned an old Buddhist parable, [_the blind men and an elephant_ (Wikipedia)](https://en.wikipedia.org/wiki/Blind_men_and_an_elephant). The poet [John Godfrey Saxe (Wikipedia)](https://en.wikipedia.org/wiki/John_Godfrey_Saxe) most famously introduced the parable to western audiences.
|
||||
|
||||
<!-- Using (non-breaking space) for spaces at the beginning of the line -->
|
||||
<!-- And adding two extra spaces at the end of a line preserves the newline -->
|
||||
> It was six men of Indostan
|
||||
> To learning much inclined,
|
||||
> Who went to see the Elephant
|
||||
> (Though all of them were blind),
|
||||
> That each by observation
|
||||
> Might satisfy his mind
|
||||
>
|
||||
> Moral:
|
||||
> So oft in theologic wars,
|
||||
> The disputants, I ween,
|
||||
> Rail on in utter ignorance
|
||||
> Of what each other mean,
|
||||
> And prate about an Elephant
|
||||
> Not one of them has seen!
|
||||
|
||||
I suprisingly recognized the parable, from a much earlier time in my life, from a very different source. I could even picture the animated elephant with the westerner's stereotypical depiction of "Indians" (eastern kind) grasping at its parts.
|
||||
|
||||
## The Whole Truth
|
||||
|
||||
In [Dieter F. Uchtdorf's talk (speeches.byu.com)](https://speeches.byu.edu/talks/dieter-f-uchtdorf/what-is-truth/), to students of Brigham Young University, an apostle of the Church of Jesus Christ of Latter-Day Saints spoke about the importance of seeing the whole Truth.
|
||||
|
||||
> The thing about truth is that it exists beyond belief.
|
||||
|
||||
The church later made a short animated video, clipping up his talk in a nice portable format that I remember watching many times as a kid. Growing up, Sundays were special days, so YouTube was only kocher on a church affiliated channel. I had watched each of those videos many times over. :grin:
|
||||
|
||||
I reflected today on the possibility that this parable of the elephant may have been misconstrued or appropriated by Uchtdorf for his, or more generally, for the church's, purposes. I wondered how exactly he had presented the parable those years ago, and if it matched its original intended purpose.
|
||||
|
||||
|
||||
I think my gut instinct was to use this as some sort of fodder. Pointing out a mistake on the part of Uchtdorf could really reaffirm my decision to step away from the mormon faith. On further reflection and researching for this post, I think it makes more sense, and is intelectually more honest, to compare how this story has been applied. As Wikipedia states, the parable "has been used to illustrate a range of truths and fallacies".
|
||||
|
||||
And isn't that how parables, allegories, and friends all work? We mold them to our time. The cultural morays shape the parts of the elephant the blind men see. For the 500 B.C.E. crowd its a plowshare, a mortar, and a pestle, and for us modern folk, a spear, a tree, and a snake; for an elephant's tusk, leg, and tail respectively.
|
||||
|
||||
## Ancient Elephants
|
||||
|
||||
In the earliest version of the parable, found in the [Tittha Sutta 6.4 (accesstoinsight.com)](https://www.accesstoinsight.org/tipitaka/kn/ud/ud.6.04.than.html), the Buddha highlights the flawed position of the sages in his day:
|
||||
|
||||
> In the same way, monks, the wanderers of other sects are blind & eyeless. They don't know what is beneficial and what is harmful. They don't know what is the Dhamma and what is non-Dhamma. [^1]
|
||||
|
||||
Buddha here clearly seems to indicate he sees the elephant for what it is, not these monks of other sects.
|
||||
|
||||
And what about my favorite German pilot?
|
||||
|
||||
## Modern Parables
|
||||
|
||||
Other than taking a strong position against Flat Earthers:
|
||||
|
||||
> For example, in spite of one-time overwhelming consensus, the earth isn’t flat.
|
||||
|
||||
Utchdorf claims there is such a thing as absolute truth. And this truth, like seeing the whole elephant clearly, "is His gospel. It is the gospel of Jesus Christ. Jesus Christ is 'the way, the truth, and the life.'"
|
||||
|
||||
## The Battle for the Elephant
|
||||
|
||||
And so it seems, from my cursory investigation, that this parable has been used by each to advance their own perspective, which is ironic.
|
||||
|
||||
Not sure why the thought crossed my mind, but I'm trying to write everyday, and so I thought it'd supply an interesting lens into my mind these days.
|
||||
|
||||
[^1]: [Buddha in Tittha Sutta 6.4, text snippet on accesstoinsight.com](https://www.accesstoinsight.org/tipitaka/kn/ud/ud.6.04.than.html#:~:text=In%20the%20same%20way%2C%20monks%2C%20the%20wanderers%20of%20other%20sects%20are%20blind%20%26%20eyeless%2E%20They%20don%27t%20know%20what%20is%20beneficial%20and%20what%20is%20harmful%2E%20They%20don%27t%20know%20what%20is%20the%20Dhamma%20and%20what%20is%20non%2DDhamma%2E)
|
||||
|
||||
BIN
static/images/elephant-and-blind-men.png
Normal file
|
After Width: | Height: | Size: 1.1 MiB |
BIN
static/images/otto-on-nature-path-algorithm.jpg
Normal file
|
After Width: | Height: | Size: 3.7 MiB |
@ -1 +0,0 @@
|
||||
Subproject commit 83480ceb2a7aa2256fd175d666ecadc01444f380
|
||||
2
themes/gokarna/.github/FUNDING.yml
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
github: gokarna-theme
|
||||
buy_me_a_coffee: avijitgupta
|
||||
38
themes/gokarna/.github/workflows/screenshot.yml
vendored
Normal file
@ -0,0 +1,38 @@
|
||||
name: Update screenshots
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
update-screenshots:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
pull-requests: write
|
||||
contents: write
|
||||
|
||||
steps:
|
||||
- name: Check out the code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Run screenshotter container
|
||||
run: docker run -v $(pwd):/app ghcr.io/gokarna-theme/gokarna-hugo/screenshotter
|
||||
|
||||
- name: Create PR
|
||||
run: |
|
||||
if [[ -z $(git status images --porcelain) ]]; then
|
||||
echo "No changes found"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
git config --global user.name 'github-actions[bot]'
|
||||
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
|
||||
git checkout -b auto-update-screenshots
|
||||
git add images/
|
||||
git commit -m 'chore: update screenshots'
|
||||
git push origin auto-update-screenshots -f
|
||||
gh pr create -B main -H auto-update-screenshots --title 'chore: update screenshots' --body 'Created by GitHub action'
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
22
themes/gokarna/.github/workflows/stale-bot.yml
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
name: 'Close stale issues and mark inactive PRs'
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * 0' # At 00:00 on every Sunday
|
||||
|
||||
jobs:
|
||||
stale:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
issues: write
|
||||
pull-requests: write
|
||||
contents: read
|
||||
steps:
|
||||
- uses: actions/stale@v9
|
||||
with:
|
||||
stale-issue-message: 'This issue is stale because it has been open for 90 days with no activity. Remove stale label or comment or this will be closed in 30 days.'
|
||||
stale-pr-message: 'This PR is stale because it has been open for 90 days with no activity.'
|
||||
close-issue-message: 'This issue was closed due to inactivity'
|
||||
days-before-stale: 90
|
||||
days-before-close: 30
|
||||
days-before-pr-close: -1
|
||||
exempt-all-assignees: true
|
||||
6
themes/gokarna/.gitignore
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
.DS_Store
|
||||
geckodriver.log
|
||||
.idea/
|
||||
.hugo_build.lock
|
||||
# Ignore build dir (hugo server)
|
||||
exampleSite/public/
|
||||
17
themes/gokarna/Containerfile
Normal file
@ -0,0 +1,17 @@
|
||||
FROM python:alpine
|
||||
|
||||
# Enable monospace fonts
|
||||
RUN apk add font-inconsolata fontconfig
|
||||
RUN fc-cache -fv
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Install dependencies
|
||||
RUN apk add firefox geckodriver hugo
|
||||
|
||||
COPY requirements.txt requirements.txt
|
||||
RUN pip install --requirement requirements.txt
|
||||
|
||||
# We mount the gokarna source code to avoid rebuilding the image
|
||||
|
||||
CMD [ "python", "./screenshot.py" ]
|
||||
675
themes/gokarna/LICENSE
Normal file
@ -0,0 +1,675 @@
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU General Public License is a free, copyleft license for
|
||||
software and other kinds of works.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
the GNU General Public License is intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users. We, the Free Software Foundation, use the
|
||||
GNU General Public License for most of our software; it applies also to
|
||||
any other work released this way by its authors. You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to prevent others from denying you
|
||||
these rights or asking you to surrender the rights. Therefore, you have
|
||||
certain responsibilities if you distribute copies of the software, or if
|
||||
you modify it: responsibilities to respect the freedom of others.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must pass on to the recipients the same
|
||||
freedoms that you received. You must make sure that they, too, receive
|
||||
or can get the source code. And you must show them these terms so they
|
||||
know their rights.
|
||||
|
||||
Developers that use the GNU GPL protect your rights with two steps:
|
||||
(1) assert copyright on the software, and (2) offer you this License
|
||||
giving you legal permission to copy, distribute and/or modify it.
|
||||
|
||||
For the developers' and authors' protection, the GPL clearly explains
|
||||
that there is no warranty for this free software. For both users' and
|
||||
authors' sake, the GPL requires that modified versions be marked as
|
||||
changed, so that their problems will not be attributed erroneously to
|
||||
authors of previous versions.
|
||||
|
||||
Some devices are designed to deny users access to install or run
|
||||
modified versions of the software inside them, although the manufacturer
|
||||
can do so. This is fundamentally incompatible with the aim of
|
||||
protecting users' freedom to change the software. The systematic
|
||||
pattern of such abuse occurs in the area of products for individuals to
|
||||
use, which is precisely where it is most unacceptable. Therefore, we
|
||||
have designed this version of the GPL to prohibit the practice for those
|
||||
products. If such problems arise substantially in other domains, we
|
||||
stand ready to extend this provision to those domains in future versions
|
||||
of the GPL, as needed to protect the freedom of users.
|
||||
|
||||
Finally, every program is threatened constantly by software patents.
|
||||
States should not allow patents to restrict development and use of
|
||||
software on general-purpose computers, but in those that do, we wish to
|
||||
avoid the special danger that patents applied to a free program could
|
||||
make it effectively proprietary. To prevent this, the GPL assures that
|
||||
patents cannot be used to render the program non-free.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Use with the GNU Affero General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU Affero General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the special requirements of the GNU Affero General Public License,
|
||||
section 13, concerning interaction through a network will apply to the
|
||||
combination as such.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
<program> Copyright (C) <year> <name of author>
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, your program's commands
|
||||
might be different; for a GUI interface, you would use an "about box".
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU GPL, see
|
||||
<https://www.gnu.org/licenses/>.
|
||||
|
||||
The GNU General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library, you
|
||||
may consider it more useful to permit linking proprietary applications with
|
||||
the library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License. But first, please read
|
||||
<https://www.gnu.org/licenses/why-not-lgpl.html>.
|
||||
|
||||
106
themes/gokarna/README.md
Normal file
@ -0,0 +1,106 @@
|
||||
# Gokarna
|
||||
|
||||
Gokarna is an opinionated theme with a focus on minimalism and simplicity.
|
||||
|
||||
### Authors:
|
||||
|
||||
- [Yash Mehrotra](https://yashmehrotra.com)
|
||||
- [Avijit Gupta](https://twitter.com/526avijit)
|
||||
|
||||
#### Major Contributors
|
||||
- [James Davidson](https://jamesdavidson.xyz)
|
||||
- [David Kröll](https://davidkroell.com)
|
||||
- [Mansoor Barri](https://mansoorbarri.com)
|
||||
|
||||
### Demo: [https://gokarna-hugo.netlify.app](https://gokarna-hugo.netlify.app)
|
||||
|
||||
## Support the developer
|
||||
|
||||
<a href="https://github.com/sponsors/gokarna-theme">
|
||||
<img src="https://img.shields.io/badge/Sponsor-❤-red?style=for-the-badge" width="170" height="37" alt="Sponsor us">
|
||||
</a>
|
||||
|
||||
[](https://www.buymeacoffee.com/avijitgupta)
|
||||
|
||||
## Features
|
||||
|
||||
Gokarna is fast, responsive, and [SEO-friendly](#performance).
|
||||
|
||||
- Light and dark modes
|
||||
- [Feather](https://feathericons.com/) and [Simple](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#icons-on-homepage) icons
|
||||
- [KaTeX](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#katex) math typesetting
|
||||
- [Syntax highlighting](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#syntax-highlighting)
|
||||
- [Custom HTML, JavaScript, and CSS](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#custom-head-and-footer-html)
|
||||
- [Configurable Table of Contents](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#table-of-contents)
|
||||
- Español (Spanish/Catalan), Deutsch (German), Français (French), Polski (Polish), Português Brasileiro (Brazilian Portuguese), Русский (Russian), and 正體字 (Traditional Chinese) [translations](https://github.com/gokarna-theme/gokarna-hugo/tree/main/i18n)
|
||||
- Google Lato fonts
|
||||
- Auto-generated RSS feed
|
||||
|
||||
And more...
|
||||
|
||||
## Screenshots
|
||||
|
||||
### Homepage
|
||||
|
||||
Light Mode | Dark Mode
|
||||
:-------------------------:|:-------------------------:
|
||||
 | 
|
||||
|
||||
### Post page
|
||||
|
||||
Light Mode | Dark Mode
|
||||
:-------------------------:|:-------------------------:
|
||||
 | 
|
||||
|
||||
### List page
|
||||
|
||||
Light Mode | Dark Mode
|
||||
:-------------------------:|:-------------------------:
|
||||
 | 
|
||||
|
||||
## Installation
|
||||
|
||||
Follow the steps in [Theme Documentation - Basics](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#installation).
|
||||
|
||||
```sh
|
||||
git submodule add https://github.com/gokarna-theme/gokarna-hugo.git themes/gokarna
|
||||
```
|
||||
|
||||
## Customization
|
||||
|
||||
For a complete guide on customization, please consult the [basic](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/) and [advanced](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/) documentation.
|
||||
|
||||
Examples include:
|
||||
|
||||
- [Add an avatar](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#avatar-url) and [change its size](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#avatar-size)
|
||||
- [Add text to the footer](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#footer)
|
||||
- [Change how dates are formatted on posts](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#date-format)
|
||||
- [Choose the syntax highlighting color scheme](https://gokarna-hugo.netlify.app/posts/theme-documentation-advanced/#syntax-highlighting)
|
||||
- [Compose navigation menu items](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#basic-configuration)
|
||||
- [Define the site's accent color](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#accent-color)
|
||||
Change the color of hyperlinks, including icons.
|
||||
- [Display recent or popular posts on the home page](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#display-posts-on-the-home-page)
|
||||
- [Inject custom HTML](https://gokarna-hugo.netlify.app/posts/theme-documentation-basics/#custom-head-html)
|
||||
Use the `<head>` and `<footer>` elements to add arbitrary HTML, JavaScript, and CSS.
|
||||
|
||||
## Translations
|
||||
|
||||
Change [`languageCode`](https://gohugo.io/content-management/multilingual/#configure-languages) to use one of [our translations](https://github.com/gokarna-theme/gokarna-hugo/tree/main/i18n).
|
||||
|
||||
Missing a language? Make Gokarna multilingual by [creating a translation table](https://gohugo.io/functions/lang/translate/#simple-translations).
|
||||
|
||||
## Inspiration
|
||||
|
||||
The theme is inspired by, and accordingly named after, [Gokarna](https://en.wikipedia.org/wiki/Gokarna,_Karnataka), a small and peaceful beach town on the west coast of India.
|
||||
|
||||

|
||||
|
||||
## Performance
|
||||
|
||||
Google Lighthouse score: 100%
|
||||
|
||||

|
||||
|
||||
## LICENSE
|
||||
|
||||
This code is licensed under [GNU GPLv3](https://www.gnu.org/licenses/gpl-3.0.html)
|
||||
8
themes/gokarna/archetypes/default.md
Normal file
@ -0,0 +1,8 @@
|
||||
---
|
||||
date: {{ .Date }}
|
||||
# image: ""
|
||||
lastmod: {{ now.Format "2006-01-02" }}
|
||||
showTableOfContents: false
|
||||
title: "{{ replace .File.ContentBaseName `-` ` ` | title }}"
|
||||
type: "page"
|
||||
---
|
||||
10
themes/gokarna/archetypes/posts.md
Normal file
@ -0,0 +1,10 @@
|
||||
---
|
||||
date: {{ .Date }}
|
||||
# description: ""
|
||||
# image: ""
|
||||
lastmod: {{ now.Format "2006-01-02" }}
|
||||
showTableOfContents: false
|
||||
# tags: ["",]
|
||||
title: "{{ replace .File.ContentBaseName `-` ` ` | title }}"
|
||||
type: "post"
|
||||
---
|
||||
@ -1,11 +1,10 @@
|
||||
/* Kimber (base16) dark theme override for Gokarna */
|
||||
/* Overrides themes/gokarna/assets/css/dark.css via Hugo asset resolution */
|
||||
|
||||
:root {
|
||||
--dark-primary-color: 34, 34, 34; /* base00 #222222 */
|
||||
--dark-secondary-color: #313131; /* base01 */
|
||||
--dark-tertiary-color: #555D55; /* base02 */
|
||||
--dark-text-color: #DEDEE7; /* base05 */
|
||||
--dark-primary-color: 34, 34, 34; /* Kimber base00 #222222 */
|
||||
--dark-secondary-color: #313131; /* Kimber base01 */
|
||||
--dark-tertiary-color: #555D55; /* Kimber base02 */
|
||||
--dark-text-color: #DEDEE7; /* Kimber base05 */
|
||||
--dark-muted-color: #C3C3B4; /* Kimber base06 dates/blockquotes */
|
||||
--dark-shadow-color: 49, 49, 49; /* Kimber base01 as RGB triplet */
|
||||
}
|
||||
|
||||
html {
|
||||
@ -27,8 +26,8 @@ html {
|
||||
}
|
||||
|
||||
a:hover .feather-moon {
|
||||
fill: #DEDEE7; /* base05 */
|
||||
color: #DEDEE7;
|
||||
fill: var(--dark-text-color);
|
||||
color: var(--dark-text-color);
|
||||
}
|
||||
|
||||
.gk-social-icons-list .gk-social-icon,
|
||||
@ -59,12 +58,12 @@ a:hover .feather-moon {
|
||||
}
|
||||
|
||||
blockquote {
|
||||
color: #C3C3B4; /* base06 */
|
||||
color: var(--dark-muted-color);
|
||||
border-left-color: var(--dark-secondary-color);
|
||||
}
|
||||
|
||||
hr {
|
||||
color: var(--dark-secondary-color);
|
||||
color: var(--dark-tertiary-color);
|
||||
}
|
||||
|
||||
table thead {
|
||||
@ -87,14 +86,26 @@ pre {
|
||||
}
|
||||
|
||||
.header-shadow {
|
||||
box-shadow: rgb(49, 49, 49) 0px -1px 0px 0px inset; /* base01 */
|
||||
box-shadow: rgb(var(--dark-shadow-color)) 0px -1px 0px 0px inset;
|
||||
}
|
||||
|
||||
.post .post-date, .prev-post-date, .next-post-date {
|
||||
color: var(--dark-muted-color);
|
||||
}
|
||||
|
||||
.list-posts .post-date {
|
||||
color: var(--dark-muted-color);
|
||||
}
|
||||
|
||||
.arrow-logo {
|
||||
background-color: var(--dark-secondary-color);
|
||||
}
|
||||
|
||||
/* Post dates */
|
||||
.post-date {
|
||||
color: #C3C3B4; /* base06 */
|
||||
/* TODO: Check if this is needed or not */
|
||||
/*
|
||||
img,
|
||||
video {
|
||||
filter: hue-rotate(180deg) contrast(100%) invert(100%);
|
||||
-webkit-filter: hue-rotate(180deg) contrast(100%) invert(100%);
|
||||
}
|
||||
*/
|
||||
704
themes/gokarna/assets/css/main.css
Normal file
@ -0,0 +1,704 @@
|
||||
:root {
|
||||
--content-width: 1120px;
|
||||
--container-width: 810px;
|
||||
|
||||
--light-primary-color: 255, 255, 230; /* Kimber base07 #FFFFE6 warm cream */
|
||||
--light-secondary-color: #C3C3B4; /* Kimber base06 borders/dividers */
|
||||
--light-tertiary-color: #222222; /* Kimber base00 code block bg */
|
||||
--light-text-color: #222222; /* Kimber base00 primary text */
|
||||
--light-muted-color: #5A5A5A; /* Kimber base04 dates/blockquotes */
|
||||
--light-code-color: #DEDEE7; /* Kimber base05 code foreground */
|
||||
--light-shadow-color: 195, 195, 180; /* Kimber base06 as RGB triplet */
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: Lato;
|
||||
font-weight: 400;
|
||||
src: url("/fonts/Lato-Regular.ttf");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: Lato;
|
||||
font-weight: 700;
|
||||
src: url("/fonts/Lato-Bold.ttf");
|
||||
}
|
||||
|
||||
html {
|
||||
background-color: rgb(var(--light-primary-color));
|
||||
color: var(--light-text-color);
|
||||
font-family: "Lato", sans-serif;
|
||||
font-size: var(--font-size);
|
||||
min-height: 100%;
|
||||
position: relative;
|
||||
scroll-behavior: smooth;
|
||||
}
|
||||
|
||||
body {
|
||||
margin-bottom: 170px;
|
||||
}
|
||||
|
||||
body.blog-post.has-post-navigation {
|
||||
margin-bottom: 80px;
|
||||
}
|
||||
|
||||
b,
|
||||
strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
a {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
/* This is set in partials/head.html and is populated via config */
|
||||
a:hover {
|
||||
color: var(--accent-color);
|
||||
fill: var(--accent-color);
|
||||
}
|
||||
|
||||
main#content {
|
||||
margin: 90px auto 0;
|
||||
width: var(--content-width);
|
||||
}
|
||||
|
||||
main#content > .container {
|
||||
margin: auto;
|
||||
width: 75%;
|
||||
max-width: var(--container-width);
|
||||
}
|
||||
|
||||
.post.container {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.post-toc {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
padding-left: 50px;
|
||||
vertical-align: top;
|
||||
/* Would be 25% had there been no margins or border box on all inline blocks */
|
||||
width: 24%;
|
||||
}
|
||||
|
||||
#toc {
|
||||
position: fixed;
|
||||
top: 80px;
|
||||
bottom: 20px;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
#toc ul {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
#toc ul li {
|
||||
margin-top: 12px;
|
||||
}
|
||||
|
||||
#toc ul li a.level-1 {
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
#toc ul li a.level-2 {
|
||||
padding-left: 10px;
|
||||
}
|
||||
|
||||
#toc ul li a.level-3 {
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
#toc ul li a.level-4 {
|
||||
padding-left: 30px;
|
||||
}
|
||||
|
||||
#toc ul li a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#toc ul li a.active {
|
||||
color: var(--accent-color);
|
||||
}
|
||||
|
||||
img {
|
||||
height: auto;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
/* HEADER */
|
||||
.header {
|
||||
background-color: rgba(var(--light-primary-color), 0.95);
|
||||
color: inherit;
|
||||
height: 50px;
|
||||
left: 0;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
transition: box-shadow 0.3s ease-in-out;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
}
|
||||
|
||||
.header a {
|
||||
text-decoration: none;
|
||||
}
|
||||
.header .header-nav {
|
||||
height: 50px;
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.header-nav .avatar {
|
||||
border-radius: 18px;
|
||||
float: left;
|
||||
height: 100%;
|
||||
margin-left: 15px;
|
||||
}
|
||||
.header-nav .avatar img {
|
||||
border-radius: 100%;
|
||||
display: block;
|
||||
height: 38px;
|
||||
margin-top: 5px;
|
||||
overflow: hidden;
|
||||
width: 38px;
|
||||
}
|
||||
.header-nav .nav-title {
|
||||
display: inline-block;
|
||||
height: 100%;
|
||||
line-height: 50px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
.nav-title a {
|
||||
height: 50px;
|
||||
}
|
||||
.header-nav .nav-links {
|
||||
float: right;
|
||||
line-height: 50px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.nav-links .nav-link {
|
||||
display: inline-block;
|
||||
padding: 0 2px;
|
||||
}
|
||||
.nav-links .nav-link a {
|
||||
display: block;
|
||||
padding: 0 6px;
|
||||
}
|
||||
.nav-link a svg {
|
||||
height: 20px;
|
||||
margin: -3px auto;
|
||||
stroke-width: 2;
|
||||
width: 20px;
|
||||
}
|
||||
.nav-item a svg {
|
||||
height: 20px;
|
||||
margin: -3px auto;
|
||||
stroke-width: 2;
|
||||
width: 20px;
|
||||
}
|
||||
.nav-links .nav-link.icon a {
|
||||
padding: 0 8px;
|
||||
}
|
||||
.nav-links .nav-icons-divider {
|
||||
border-color: inherit;
|
||||
border-left: 1.5px solid;
|
||||
color: var(--light-secondary-color);
|
||||
margin: 0 10px;
|
||||
}
|
||||
.nav-links .dark-theme-toggle:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
a:hover .feather-sun {
|
||||
fill: var(--light-text-color);
|
||||
color: var(--light-text-color);
|
||||
}
|
||||
|
||||
.dark-theme-toggle .feather {
|
||||
height: 22px;
|
||||
stroke-linecap: round;
|
||||
stroke-linejoin: round;
|
||||
width: 22px;
|
||||
}
|
||||
#hamburger-menu-toggle {
|
||||
display: none;
|
||||
}
|
||||
#hamburger-menu-toggle .feather {
|
||||
height: 24px;
|
||||
stroke-linecap: round;
|
||||
stroke-linejoin: round;
|
||||
width: 24px;
|
||||
}
|
||||
.nav-hamburger-list {
|
||||
background: rgb(var(--light-primary-color));
|
||||
border-bottom: solid 1.5px var(--light-secondary-color);
|
||||
border-top: solid 1.5px var(--light-secondary-color);
|
||||
list-style-type: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
z-index: 5;
|
||||
}
|
||||
.nav-hamburger-list a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
/* FOOTER */
|
||||
.footer {
|
||||
bottom: 0;
|
||||
color: inherit;
|
||||
left: 0;
|
||||
margin-left: 30%;
|
||||
overflow: hidden;
|
||||
padding: 40px 0;
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
width: 40%;
|
||||
}
|
||||
|
||||
.footer span {
|
||||
display: block;
|
||||
font-size: 0.85em;
|
||||
font-weight: 300;
|
||||
padding: 1px 0;
|
||||
}
|
||||
|
||||
/** COMMON **/
|
||||
.flex-break {
|
||||
flex-basis: 100%;
|
||||
height: 0;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.visibility-hidden {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.header-shadow {
|
||||
box-shadow: rgb(var(--light-shadow-color)) 0px 1px 5px;
|
||||
}
|
||||
|
||||
/* TAGS */
|
||||
.post-tags {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
}
|
||||
.post-tags .post-tag {
|
||||
border: 1.5px solid;
|
||||
border-radius: 4px;
|
||||
box-sizing: border-box;
|
||||
color: inherit;
|
||||
display: inline-block;
|
||||
font-size: 14px;
|
||||
}
|
||||
.post-tags .post-tag:hover {
|
||||
background-color: var(--light-text-color);
|
||||
color: rgb(var(--light-primary-color));
|
||||
}
|
||||
.post-tag a {
|
||||
color: inherit;
|
||||
display: block;
|
||||
padding: 6px 12px;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* CODE BLOCKS */
|
||||
code,
|
||||
pre {
|
||||
background-color: var(--light-tertiary-color);
|
||||
box-sizing: border-box;
|
||||
color: var(--light-code-color);
|
||||
}
|
||||
|
||||
pre {
|
||||
font-size: 0.95rem;
|
||||
overflow: auto;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
code {
|
||||
box-decoration-break: clone;
|
||||
word-wrap: break-word;
|
||||
font-size: 0.8em;
|
||||
}
|
||||
|
||||
:not(pre) > code {
|
||||
background-color: var(--light-secondary-color) !important;
|
||||
color: var(--light-text-color);
|
||||
padding: 1px 4px;
|
||||
}
|
||||
|
||||
pre code {
|
||||
font-size: 0.9em;
|
||||
}
|
||||
|
||||
/*
|
||||
Fix iOS font sizing in code blocks
|
||||
Author: https://github.com/bglw
|
||||
Source: https://github.com/adityatelange/hugo-PaperMod/issues/828#issuecomment-1171994855
|
||||
*/
|
||||
code {
|
||||
text-size-adjust: 100%;
|
||||
-ms-text-size-adjust: 100%;
|
||||
-moz-text-size-adjust: 100%;
|
||||
-webkit-text-size-adjust: 100%;
|
||||
}
|
||||
|
||||
blockquote {
|
||||
border-left: 2px solid var(--light-secondary-color);
|
||||
color: var(--light-muted-color);
|
||||
padding-left: 1rem;
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
hr {
|
||||
color: var(--light-secondary-color);
|
||||
margin: 50px auto;
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
margin: 30px 0;
|
||||
text-align: left;
|
||||
display: block;
|
||||
overflow-x: auto;
|
||||
}
|
||||
|
||||
table thead {
|
||||
background-color: var(--light-secondary-color);
|
||||
}
|
||||
|
||||
table td,
|
||||
table th {
|
||||
padding: 1.4rem;
|
||||
}
|
||||
|
||||
table td {
|
||||
border-bottom: 1px solid var(--light-secondary-color);
|
||||
}
|
||||
|
||||
/* HOME PAGE */
|
||||
.home-about {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.home-about .avatar img {
|
||||
border-radius: 50%;
|
||||
height: auto;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
/* Avatar sizes (default is M) - XS, S, M, L, XL */
|
||||
.home-about .avatar img.size-xs {
|
||||
height: 7rem;
|
||||
width: 7rem;
|
||||
}
|
||||
|
||||
.home-about .avatar img.size-s {
|
||||
height: 9rem;
|
||||
width: 9rem;
|
||||
}
|
||||
|
||||
.home-about .avatar img.size-m {
|
||||
height: 11rem;
|
||||
width: 11rem;
|
||||
}
|
||||
|
||||
.home-about .avatar img.size-l {
|
||||
height: 13rem;
|
||||
width: 13rem;
|
||||
}
|
||||
|
||||
.home-about .avatar img.size-xl {
|
||||
height: 15rem;
|
||||
width: 15rem;
|
||||
}
|
||||
|
||||
.home-about h1 {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
.home-about h2 {
|
||||
font-size: 1.2em;
|
||||
}
|
||||
|
||||
.gk-social-icons {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.gk-social-icons .gk-social-icons-list {
|
||||
display: inline-block;
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.gk-social-icons-list .gk-social-icon {
|
||||
box-sizing: border-box;
|
||||
display: inline-block;
|
||||
fill: var(--light-text-color);
|
||||
height: 24px;
|
||||
margin: 0 6px;
|
||||
width: 24px;
|
||||
}
|
||||
|
||||
.gk-social-icon a svg path {
|
||||
transition: fill 0.15s ease;
|
||||
}
|
||||
|
||||
.home-content {
|
||||
line-height: 1.25;
|
||||
width: 80%;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.home-posts {
|
||||
margin: 0 auto;
|
||||
padding-top: 10px;
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
/* SINGLE */
|
||||
.post [role="doc-subtitle"] {
|
||||
font-size: 1.1em;
|
||||
font-style: italic;
|
||||
}
|
||||
.post {
|
||||
/* Prevent long strings from overflowing */
|
||||
overflow-wrap: break-word;
|
||||
}
|
||||
.post .post-date, .prev-post-date, .next-post-date {
|
||||
color: var(--light-muted-color);
|
||||
}
|
||||
.post .post-content {
|
||||
line-height: 1.7;
|
||||
margin-top: 50px;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
.post-content h1, .post-content h2, .post-content h3, .post-content h4 {
|
||||
scroll-margin-top: 55px;
|
||||
}
|
||||
.post-content h1 {
|
||||
margin-top: 40px;
|
||||
}
|
||||
.post-content h2 {
|
||||
margin-top: 35px;
|
||||
}
|
||||
.post-content h3 {
|
||||
margin-top: 30px;
|
||||
}
|
||||
.post-content h4 {
|
||||
margin-top: 25px;
|
||||
}
|
||||
.post-content h5 {
|
||||
margin-top: 20px;
|
||||
}
|
||||
.post-content img {
|
||||
display: block;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
/* LIST */
|
||||
.list-posts .list-title {
|
||||
text-align: center;
|
||||
}
|
||||
.list-posts .posts-year {
|
||||
margin-top: 70px;
|
||||
}
|
||||
.list-posts .post-title {
|
||||
margin: 18px 0 0 15px;
|
||||
}
|
||||
.list-posts .post-title a {
|
||||
text-decoration: none;
|
||||
}
|
||||
.post-title .post-link,
|
||||
.post-title .post-date {
|
||||
display: inline-block;
|
||||
}
|
||||
.post-title .post-link {
|
||||
/* This magic number is the largest width that keeps the post-date div from
|
||||
* causing the line to wrap with the longest possible date string
|
||||
* "September 22, 2022"
|
||||
*/
|
||||
width: 73%;
|
||||
}
|
||||
.tags-list .post-tags {
|
||||
margin-top: 50px;
|
||||
}
|
||||
.tags-list .post-tags .post-tag {
|
||||
margin: 2px 5px;
|
||||
padding: 0;
|
||||
}
|
||||
.tags-list .post-tags .post-tag a {
|
||||
border-radius: inherit;
|
||||
padding: 0;
|
||||
}
|
||||
.tags-list .post-tags .post-tag a div {
|
||||
display: inline-block;
|
||||
}
|
||||
.tags-list .post-tags .post-tag a .tag-name {
|
||||
padding: 5px 8px;
|
||||
}
|
||||
.tags-list .post-tags .post-tag a .tag-posts-count {
|
||||
background-color: var(--light-secondary-color);
|
||||
border-radius: inherit;
|
||||
color: inherit;
|
||||
opacity: 0.8;
|
||||
padding: 6px;
|
||||
position: relative;
|
||||
z-index: 0;
|
||||
}
|
||||
.tags-list .post-tags .post-tag:hover a .tag-posts-count {
|
||||
background-color: var(--light-text-color);
|
||||
color: rgb(var(--light-primary-color));
|
||||
}
|
||||
|
||||
.text-404 {
|
||||
margin-top: 125px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 1120px) {
|
||||
main#content {
|
||||
width: auto;
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 820px) {
|
||||
body {
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
|
||||
.flex-break {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.home-about .avatar img {
|
||||
border-radius: 50%;
|
||||
height: 7rem;
|
||||
width: 7rem;
|
||||
}
|
||||
|
||||
.nav-links .nav-link,
|
||||
.nav-icons-divider {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#hamburger-menu-toggle {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
main#content {
|
||||
box-sizing: border-box;
|
||||
padding: 0 1.5rem;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.home-content, .home-posts {
|
||||
width: auto;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
main#content .container {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.home-about {
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
#toc {
|
||||
display:none;
|
||||
}
|
||||
|
||||
.list-posts {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.list-posts .post-date {
|
||||
color: var(--light-muted-color);
|
||||
}
|
||||
|
||||
.footer {
|
||||
margin-left: 0;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 820px) {
|
||||
.nav-hamburger-list {
|
||||
visibility: hidden !important;
|
||||
}
|
||||
}
|
||||
|
||||
/*Accessibility*/
|
||||
.sr-only {
|
||||
position: absolute;
|
||||
left: -10000px;
|
||||
top: auto;
|
||||
width: 1px;
|
||||
height: 1px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.post-navigation {
|
||||
padding: 40px 0;
|
||||
}
|
||||
|
||||
.post-navigation::after {
|
||||
clear: both;
|
||||
content: "";
|
||||
display: table;
|
||||
}
|
||||
|
||||
.prev-post {
|
||||
float: left;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.next-post {
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.prev-post, .next-post {
|
||||
max-width: 33%;
|
||||
}
|
||||
|
||||
/* back to top button */
|
||||
.arrow-logo {
|
||||
background-color: transparent;
|
||||
border-radius: 50%;
|
||||
bottom: 20px;
|
||||
cursor: pointer;
|
||||
display: none;
|
||||
font-size: 24px;
|
||||
padding: 10px;
|
||||
padding-right: 8px;
|
||||
position: fixed;
|
||||
right: 20px;
|
||||
z-index: 5;
|
||||
background-color: var(--light-tertiary-color);
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
}
|
||||
|
||||
.arrow-logo path{
|
||||
fill: var(--light-secondary-color)
|
||||
}
|
||||
|
||||
.arrow-logo:hover {
|
||||
fill: var(--accent-color);
|
||||
}
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
#btt-button {
|
||||
visibility: hidden;
|
||||
}
|
||||
}
|
||||
2
themes/gokarna/assets/css/normalize.min.css
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%}body{margin:0}main{display:block}h1{font-size:2em;margin:.67em 0}hr{box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}
|
||||
/*# sourceMappingURL=normalize.min.css.map */
|
||||
96
themes/gokarna/assets/css/syntax.css
Normal file
@ -0,0 +1,96 @@
|
||||
/* Kimber (base16) syntax highlighting for Chroma */
|
||||
/* Base16 Kimber by Mishka Nguyen (https://github.com/akhsiM) */
|
||||
|
||||
/* Background */
|
||||
.bg { color: var(--light-code-color); background-color: var(--light-tertiary-color); }
|
||||
.chroma { color: var(--light-code-color); background-color: var(--light-tertiary-color); }
|
||||
|
||||
/* Line infrastructure */
|
||||
.chroma .lnlinks { outline: none; text-decoration: none; color: inherit; }
|
||||
.chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; }
|
||||
.chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; }
|
||||
.chroma .hl { background-color: #313131; } /* base01 highlight */
|
||||
.chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em; color: #5A5A5A; } /* base04 */
|
||||
.chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em; color: #5A5A5A; } /* base04 */
|
||||
.chroma .line { display: flex; }
|
||||
|
||||
/* Keywords - base0E #86CACD (light teal) */
|
||||
.chroma .k { color: #86CACD; }
|
||||
.chroma .kc { color: #86CACD; }
|
||||
.chroma .kd { color: #86CACD; }
|
||||
.chroma .kn { color: #86CACD; }
|
||||
.chroma .kp { color: #86CACD; }
|
||||
.chroma .kr { color: #86CACD; }
|
||||
.chroma .kt { color: #D8B56D; } /* base0A types */
|
||||
|
||||
/* Names */
|
||||
.chroma .na { color: #537C9C; } /* base0D attributes */
|
||||
.chroma .nc { color: #D8B56D; } /* base0A classes */
|
||||
.chroma .no { color: #476C88; } /* base09 constants */
|
||||
.chroma .nd { color: #D8B56D; } /* base0A decorators */
|
||||
.chroma .ni { color: #DEDEE7; } /* base05 entities */
|
||||
.chroma .ne { color: #C88C8C; } /* base08 exceptions */
|
||||
.chroma .nl { color: #DEDEE7; } /* base05 labels */
|
||||
.chroma .nn { color: #D8B56D; } /* base0A namespaces */
|
||||
.chroma .nt { color: #C88C8C; } /* base08 tags */
|
||||
.chroma .nb { color: #DEDEE7; } /* base05 builtins */
|
||||
.chroma .bp { color: #DEDEE7; } /* base05 builtin pseudo */
|
||||
.chroma .nv { color: #C88C8C; } /* base08 variables */
|
||||
.chroma .vc { color: #C88C8C; } /* base08 */
|
||||
.chroma .vg { color: #C88C8C; } /* base08 */
|
||||
.chroma .vi { color: #C88C8C; } /* base08 */
|
||||
.chroma .vm { color: #C88C8C; } /* base08 */
|
||||
.chroma .nf { color: #537C9C; } /* base0D functions */
|
||||
.chroma .fm { color: #537C9C; } /* base0D */
|
||||
|
||||
/* Strings - base0B #99C899 (sage green) */
|
||||
.chroma .s { color: #99C899; }
|
||||
.chroma .sa { color: #99C899; }
|
||||
.chroma .sb { color: #99C899; }
|
||||
.chroma .sc { color: #99C899; }
|
||||
.chroma .dl { color: #99C899; }
|
||||
.chroma .sd { color: #99C899; font-style: italic; }
|
||||
.chroma .s2 { color: #99C899; }
|
||||
.chroma .se { color: #78B4B4; } /* base0C escape chars */
|
||||
.chroma .sh { color: #99C899; }
|
||||
.chroma .si { color: #78B4B4; } /* base0C interpolation */
|
||||
.chroma .sx { color: #99C899; }
|
||||
.chroma .sr { color: #78B4B4; } /* base0C regex */
|
||||
.chroma .s1 { color: #99C899; }
|
||||
.chroma .ss { color: #99C899; }
|
||||
|
||||
/* Numbers - base09 #476C88 (steel blue) */
|
||||
.chroma .m { color: #476C88; }
|
||||
.chroma .mb { color: #476C88; }
|
||||
.chroma .mf { color: #476C88; }
|
||||
.chroma .mh { color: #476C88; }
|
||||
.chroma .mi { color: #476C88; }
|
||||
.chroma .il { color: #476C88; }
|
||||
.chroma .mo { color: #476C88; }
|
||||
|
||||
/* Operators - base05 #DEDEE7 */
|
||||
.chroma .o { color: #DEDEE7; }
|
||||
.chroma .ow { color: #86CACD; } /* base0E operator words */
|
||||
|
||||
/* Comments - base03 #644646 (dusty mauve) */
|
||||
.chroma .c { color: #644646; font-style: italic; }
|
||||
.chroma .ch { color: #644646; font-style: italic; }
|
||||
.chroma .cm { color: #644646; font-style: italic; }
|
||||
.chroma .c1 { color: #644646; font-style: italic; }
|
||||
.chroma .cs { color: #644646; font-style: italic; }
|
||||
.chroma .cp { color: #D8B56D; } /* base0A preprocessor */
|
||||
.chroma .cpf { color: #99C899; } /* base0B preproc file */
|
||||
|
||||
/* Generic */
|
||||
.chroma .gd { color: #C88C8C; } /* base08 deleted */
|
||||
.chroma .ge { font-style: italic; }
|
||||
.chroma .gr { color: #C88C8C; } /* base08 error */
|
||||
.chroma .gh { color: #537C9C; font-weight: bold; } /* base0D heading */
|
||||
.chroma .gi { color: #99C899; } /* base0B inserted */
|
||||
.chroma .go { color: #644646; } /* base03 output */
|
||||
.chroma .gp { color: #644646; } /* base03 prompt */
|
||||
.chroma .gs { font-weight: bold; }
|
||||
.chroma .gu { color: #78B4B4; font-weight: bold; } /* base0C subheading */
|
||||
.chroma .gt { color: #C88C8C; } /* base08 traceback */
|
||||
.chroma .gl { text-decoration: underline; }
|
||||
.chroma .w { color: #555D55; } /* base02 whitespace */
|
||||
13
themes/gokarna/assets/js/feather-icons.min.js
vendored
Normal file
146
themes/gokarna/assets/js/main.js
Normal file
@ -0,0 +1,146 @@
|
||||
document.addEventListener('DOMContentLoaded', ready, false);
|
||||
|
||||
const THEME_PREF_STORAGE_KEY = "theme-preference";
|
||||
const THEME_TO_ICON_CLASS = {
|
||||
'dark': 'feather-moon',
|
||||
'light': 'feather-sun'
|
||||
};
|
||||
const THEME_TO_ICON_TEXT_CLASS = {
|
||||
'dark': 'Dark mode',
|
||||
'light': 'Light mode'
|
||||
};
|
||||
let toggleIcon = '';
|
||||
let darkThemeCss = '';
|
||||
|
||||
const HEADING_TO_TOC_CLASS = {
|
||||
'H1': 'level-1',
|
||||
'H2': 'level-2',
|
||||
'H3': 'level-3',
|
||||
'H4': 'level-4'
|
||||
}
|
||||
|
||||
function ready() {
|
||||
feather.replace({ 'stroke-width': 1, width: 20, height: 20 });
|
||||
setThemeByUserPref();
|
||||
|
||||
if (document.querySelector('main#content > .container') !== null &&
|
||||
document.querySelector('main#content > .container').classList.contains('post')) {
|
||||
if (document.getElementById('TableOfContents') !== null) {
|
||||
fixTocItemsIndent();
|
||||
createScrollSpy();
|
||||
} else {
|
||||
document.querySelector('main#content > .container.post').style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
// Elements to inject
|
||||
const svgsToInject = document.querySelectorAll('img.svg-inject');
|
||||
// Do the injection
|
||||
SVGInjector(svgsToInject);
|
||||
|
||||
const observer = new MutationObserver(() => {
|
||||
normalizeSvgPaths();
|
||||
});
|
||||
|
||||
observer.observe(document.body, { childList: true, subtree: true });
|
||||
|
||||
function normalizeSvgPaths() {
|
||||
document.querySelectorAll('.nav-link a .svg-inject').forEach(path => {
|
||||
const bbox = path.getBBox();
|
||||
const scaleX = 20 / bbox.width;
|
||||
const scaleY = 20 / bbox.height;
|
||||
const scale = Math.min(scaleX, scaleY);
|
||||
|
||||
path.setAttribute('transform', `scale(${scale}) translate(${-bbox.x}, ${-bbox.y})`);
|
||||
path.setAttribute('stroke', 'currentColor');
|
||||
path.setAttribute('stroke-width', '1');
|
||||
path.setAttribute('fill', 'transparent');
|
||||
});
|
||||
}
|
||||
|
||||
document.getElementById('hamburger-menu-toggle').addEventListener('click', () => {
|
||||
const hamburgerMenu = document.getElementsByClassName('nav-hamburger-list')[0]
|
||||
const hamburgerMenuToggleTarget = document.getElementById("hamburger-menu-toggle-target")
|
||||
if (hamburgerMenu.classList.contains('visibility-hidden')) {
|
||||
hamburgerMenu.classList.remove('visibility-hidden');
|
||||
hamburgerMenuToggleTarget.setAttribute("aria-checked", "true");
|
||||
} else {
|
||||
hamburgerMenu.classList.add('visibility-hidden');
|
||||
hamburgerMenuToggleTarget.setAttribute("aria-checked", "false");
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
window.addEventListener('scroll', () => {
|
||||
if (window.innerWidth <= 820) {
|
||||
// For smaller screen, show shadow earlier
|
||||
toggleHeaderShadow(50);
|
||||
} else {
|
||||
toggleHeaderShadow(100);
|
||||
}
|
||||
});
|
||||
|
||||
function fixTocItemsIndent() {
|
||||
document.querySelectorAll('#TableOfContents a').forEach($tocItem => {
|
||||
const itemId = $tocItem.getAttribute("href").substring(1)
|
||||
$tocItem.classList.add(HEADING_TO_TOC_CLASS[document.getElementById(itemId).tagName]);
|
||||
});
|
||||
}
|
||||
|
||||
function createScrollSpy() {
|
||||
var elements = document.querySelectorAll('#toc a');
|
||||
document.addEventListener('scroll', function() {
|
||||
elements.forEach(function(element) {
|
||||
const boundingRect = document.getElementById(element.getAttribute('href').substring(1)).getBoundingClientRect();
|
||||
if (boundingRect.top <= 55 && boundingRect.bottom >= 0) {
|
||||
elements.forEach(function(elem) {
|
||||
elem.classList.remove('active');
|
||||
});
|
||||
element.classList.add('active');
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function toggleHeaderShadow(scrollY) {
|
||||
if (window.scrollY > scrollY) {
|
||||
document.querySelectorAll('.header').forEach(function(item) {
|
||||
item.classList.add('header-shadow')
|
||||
})
|
||||
} else {
|
||||
document.querySelectorAll('.header').forEach(function(item) {
|
||||
item.classList.remove('header-shadow')
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
function setThemeByUserPref() {
|
||||
darkThemeCss = document.getElementById("dark-theme");
|
||||
const savedTheme = localStorage.getItem(THEME_PREF_STORAGE_KEY) ||
|
||||
(window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light');
|
||||
const darkThemeToggles = document.querySelectorAll('.dark-theme-toggle');
|
||||
setTheme(savedTheme, darkThemeToggles);
|
||||
darkThemeToggles.forEach(el => el.addEventListener('click', toggleTheme, { capture: true }))
|
||||
}
|
||||
|
||||
function toggleTheme(event) {
|
||||
toggleIcon = event.currentTarget.querySelector("a svg.feather");
|
||||
if (toggleIcon.classList[1] === THEME_TO_ICON_CLASS.dark) {
|
||||
setThemeAndStore('light', [event.currentTarget]);
|
||||
} else if (toggleIcon.classList[1] === THEME_TO_ICON_CLASS.light) {
|
||||
setThemeAndStore('dark', [event.currentTarget]);
|
||||
}
|
||||
}
|
||||
|
||||
function setTheme(themeToSet, targets) {
|
||||
darkThemeCss.disabled = themeToSet === 'light';
|
||||
targets.forEach((target) => {
|
||||
target.querySelector('a').innerHTML = feather.icons[THEME_TO_ICON_CLASS[themeToSet].split('-')[1]].toSvg();
|
||||
target.querySelector(".dark-theme-toggle-screen-reader-target").textContent = [THEME_TO_ICON_TEXT_CLASS[themeToSet]];
|
||||
});
|
||||
}
|
||||
|
||||
function setThemeAndStore(themeToSet, targets) {
|
||||
setTheme(themeToSet, targets);
|
||||
localStorage.setItem(THEME_PREF_STORAGE_KEY, themeToSet);
|
||||
}
|
||||
9
themes/gokarna/assets/js/svg-injector.min.js
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
/**
|
||||
* SVGInjector v1.1.3 - Fast, caching, dynamic inline SVG DOM injection library
|
||||
* https://github.com/iconic/SVGInjector
|
||||
*
|
||||
* Copyright (c) 2014-2015 Waybury <hello@waybury.com>
|
||||
* @license MIT
|
||||
*/
|
||||
!function(t,e){"use strict";function r(t){t=t.split(" ");for(var e={},r=t.length,n=[];r--;)e.hasOwnProperty(t[r])||(e[t[r]]=1,n.unshift(t[r]));return n.join(" ")}var n="file:"===t.location.protocol,i=e.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1"),o=Array.prototype.forEach||function(t,e){if(void 0===this||null===this||"function"!=typeof t)throw new TypeError;var r,n=this.length>>>0;for(r=0;n>r;++r)r in this&&t.call(e,this[r],r,this)},a={},l=0,s=[],u=[],c={},f=function(t){return t.cloneNode(!0)},p=function(t,e){u[t]=u[t]||[],u[t].push(e)},d=function(t){for(var e=0,r=u[t].length;r>e;e++)!function(e){setTimeout(function(){u[t][e](f(a[t]))},0)}(e)},v=function(e,r){if(void 0!==a[e])a[e]instanceof SVGSVGElement?r(f(a[e])):p(e,r);else{if(!t.XMLHttpRequest)return r("Browser does not support XMLHttpRequest"),!1;a[e]={},p(e,r);var i=new XMLHttpRequest;i.onreadystatechange=function(){if(4===i.readyState){if(404===i.status||null===i.responseXML)return r("Unable to load SVG file: "+e),n&&r("Note: SVG injection ajax calls do not work locally without adjusting security setting in your browser. Or consider using a local webserver."),r(),!1;if(!(200===i.status||n&&0===i.status))return r("There was a problem injecting the SVG: "+i.status+" "+i.statusText),!1;if(i.responseXML instanceof Document)a[e]=i.responseXML.documentElement;else if(DOMParser&&DOMParser instanceof Function){var t;try{var o=new DOMParser;t=o.parseFromString(i.responseText,"text/xml")}catch(l){t=void 0}if(!t||t.getElementsByTagName("parsererror").length)return r("Unable to parse SVG file: "+e),!1;a[e]=t.documentElement}d(e)}},i.open("GET",e),i.overrideMimeType&&i.overrideMimeType("text/xml"),i.send()}},h=function(e,n,a,u){var f=e.getAttribute("data-src")||e.getAttribute("src");if(!/\.svg/i.test(f))return void u("Attempted to inject a file with a non-svg extension: "+f);if(!i){var p=e.getAttribute("data-fallback")||e.getAttribute("data-png");return void(p?(e.setAttribute("src",p),u(null)):a?(e.setAttribute("src",a+"/"+f.split("/").pop().replace(".svg",".png")),u(null)):u("This browser does not support SVG and no PNG fallback was defined."))}-1===s.indexOf(e)&&(s.push(e),e.setAttribute("src",""),v(f,function(i){if("undefined"==typeof i||"string"==typeof i)return u(i),!1;var a=e.getAttribute("id");a&&i.setAttribute("id",a);var p=e.getAttribute("title");p&&i.setAttribute("title",p);var d=[].concat(i.getAttribute("class")||[],"injected-svg",e.getAttribute("class")||[]).join(" ");i.setAttribute("class",r(d));var v=e.getAttribute("style");v&&i.setAttribute("style",v);var h=[].filter.call(e.attributes,function(t){return/^data-\w[\w\-]*$/.test(t.name)});o.call(h,function(t){t.name&&t.value&&i.setAttribute(t.name,t.value)});var g,m,b,y,A,w={clipPath:["clip-path"],"color-profile":["color-profile"],cursor:["cursor"],filter:["filter"],linearGradient:["fill","stroke"],marker:["marker","marker-start","marker-mid","marker-end"],mask:["mask"],pattern:["fill","stroke"],radialGradient:["fill","stroke"]};Object.keys(w).forEach(function(t){g=t,b=w[t],m=i.querySelectorAll("defs "+g+"[id]");for(var e=0,r=m.length;r>e;e++){y=m[e].id,A=y+"-"+l;var n;o.call(b,function(t){n=i.querySelectorAll("["+t+'*="'+y+'"]');for(var e=0,r=n.length;r>e;e++)n[e].setAttribute(t,"url(#"+A+")")}),m[e].id=A}}),i.removeAttribute("xmlns:a");for(var x,S,k=i.querySelectorAll("script"),j=[],G=0,T=k.length;T>G;G++)S=k[G].getAttribute("type"),S&&"application/ecmascript"!==S&&"application/javascript"!==S||(x=k[G].innerText||k[G].textContent,j.push(x),i.removeChild(k[G]));if(j.length>0&&("always"===n||"once"===n&&!c[f])){for(var M=0,V=j.length;V>M;M++)new Function(j[M])(t);c[f]=!0}var E=i.querySelectorAll("style");o.call(E,function(t){t.textContent+=""}),e.parentNode.replaceChild(i,e),delete s[s.indexOf(e)],e=null,l++,u(i)}))},g=function(t,e,r){e=e||{};var n=e.evalScripts||"always",i=e.pngFallback||!1,a=e.each;if(void 0!==t.length){var l=0;o.call(t,function(e){h(e,n,i,function(e){a&&"function"==typeof a&&a(e),r&&t.length===++l&&r(l)})})}else t?h(t,n,i,function(e){a&&"function"==typeof a&&a(e),r&&r(1),t=null}):r&&r(0)};"object"==typeof module&&"object"==typeof module.exports?module.exports=exports=g:"function"==typeof define&&define.amd?define(function(){return g}):"object"==typeof t&&(t.SVGInjector=g)}(window,document);
|
||||
//# sourceMappingURL=svg-injector.map.js
|
||||
1273
themes/gokarna/exampleSite/content/posts/emoji-support.md
Normal file
49
themes/gokarna/exampleSite/content/posts/lorem-ipsum.md
Normal file
@ -0,0 +1,49 @@
|
||||
---
|
||||
title: "Lorem Ipsum"
|
||||
date: 2021-04-15T23:39:49+05:30
|
||||
tags: ["xyz", "def"]
|
||||
type: "post"
|
||||
image: "/images/lorem-ipsum/quick-fox.png"
|
||||
showTableOfContents: false
|
||||
---
|
||||
|
||||
# Heading 1
|
||||
|
||||
"Lorem ipsum dolor sit amet, consectetaur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."
|
||||
|
||||
This continues at length and variously. The text is not really Greek, but badly garbled Latin. It started life as extracted phrases from sections 1.10.32 and 1.10.33 of Cicero's "De Finibus Bonorum et Malorum" ("The Extremes of Good and Evil"), which read:
|
||||
|
||||
## Heading 2
|
||||
|
||||
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?
|
||||
|
||||
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et molestiae non recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
|
||||
|
||||
### Heading 3
|
||||
|
||||
"Lorem ipsum dolor sit amet, consectetaur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."
|
||||
|
||||
This continues at length and variously. The text is not really Greek, but badly garbled Latin. It started life as extracted phrases from sections 1.10.32 and 1.10.33 of Cicero's "De Finibus Bonorum et Malorum" ("The Extremes of Good and Evil"), which read:
|
||||
|
||||
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?
|
||||
|
||||
|
||||
#### Heading 4
|
||||
|
||||
At ver
|
||||
"Lorem ipsum dolor sit amet, consectetaur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."
|
||||
|
||||
This continues at length and variously. The text is not really Greek, but badly garbled Latin. It started life as extracted phrases from sections 1.10.32 and 1.10.33 of Cicero's "De Finibus Bonorum et Malorum" ("The Extremes of Good and Evil"), which read:
|
||||
|
||||
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?
|
||||
|
||||
##### Heading 5
|
||||
|
||||
At ver
|
||||
"Lorem ipsum dolor sit amet, consectetaur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."
|
||||
|
||||
This continues at length and variously. The text is not really Greek, but badly garbled Latin. It started life as extracted phrases from sections 1.10.32 and 1.10.33 of Cicero's "De Finibus Bonorum et Malorum" ("The Extremes of Good and Evil"), which read:
|
||||
|
||||
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?
|
||||
|
||||
At ver
|
||||
128
themes/gokarna/exampleSite/content/posts/markdown-syntax.md
Normal file
@ -0,0 +1,128 @@
|
||||
---
|
||||
title: "Markdown Syntax Guide"
|
||||
date: 2019-06-19
|
||||
description: "Sample article showcasing basic Markdown syntax and formatting for HTML elements."
|
||||
tags: ["markdown", "css", "html"]
|
||||
type: post
|
||||
weight: 20
|
||||
showTableOfContents: true
|
||||
---
|
||||
|
||||
This article offers a sample of basic Markdown syntax that can be used in Hugo content files, also it shows whether basic HTML elements are decorated with CSS in a Hugo theme.
|
||||
|
||||
# Headings
|
||||
|
||||
The following HTML `<h1>`—`<h6>` elements represent six levels of section headings. `<h1>` is the highest section level while `<h6>` is the lowest.
|
||||
|
||||
# H1
|
||||
## H2
|
||||
### H3
|
||||
#### H4
|
||||
##### H5
|
||||
###### H6
|
||||
|
||||
## Paragraph
|
||||
|
||||
Xerum, quo qui aut unt expliquam qui dolut labo. Aque venitatiusda cum, voluptionse latur sitiae dolessi aut parist aut dollo enim qui voluptate ma dolestendit peritin re plis aut quas inctum laceat est volestemque commosa as cus endigna tectur, offic to cor sequas etum rerum idem sintibus eiur? Quianimin porecus evelectur, cum que nis nust voloribus ratem aut omnimi, sitatur? Quiatem. Nam, omnis sum am facea corem alique molestrunt et eos evelece arcillit ut aut eos eos nus, sin conecerem erum fuga. Ri oditatquam, ad quibus unda veliamenimin cusam et facea ipsamus es exerum sitate dolores editium rerore eost, temped molorro ratiae volorro te reribus dolorer sperchicium faceata tiustia prat.
|
||||
|
||||
Itatur? Quiatae cullecum rem ent aut odis in re eossequodi nonsequ idebis ne sapicia is sinveli squiatum, core et que aut hariosam ex eat.
|
||||
|
||||
## Blockquotes
|
||||
|
||||
The blockquote element represents content that is quoted from another source, optionally with a citation which must be within a `footer` or `cite` element, and optionally with in-line changes such as annotations and abbreviations.
|
||||
|
||||
### Blockquote without attribution
|
||||
|
||||
> Tiam, ad mint andaepu dandae nostion secatur sequo quae.
|
||||
> **Note** that you can use *Markdown syntax* within a blockquote.
|
||||
|
||||
### Blockquote with attribution
|
||||
|
||||
> Don't communicate by sharing memory, share memory by communicating.
|
||||
> — Rob Pike[^1]
|
||||
|
||||
[^1]: The above quote is excerpted from Rob Pike's [talk](https://www.youtube.com/watch?v=PAAkCSZUG1c) during Gopherfest, November 18, 2015.
|
||||
|
||||
## Tables
|
||||
|
||||
Tables aren't part of the core Markdown spec, but Hugo supports them out-of-the-box.
|
||||
|
||||
Name | Age
|
||||
--------|------
|
||||
Bob | 27
|
||||
Alice | 23
|
||||
|
||||
### Inline Markdown within tables
|
||||
|
||||
| Italics | Bold | Code |
|
||||
| -------- | -------- | ------ |
|
||||
| *italics* | **bold** | `code` |
|
||||
|
||||
## Code Blocks
|
||||
|
||||
### Code block with backticks
|
||||
|
||||
```html
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Example HTML5 Document</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Test</p>
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
### Code block indented with four spaces
|
||||
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Example HTML5 Document</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Test</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
### Code block with Hugo's internal highlight shortcode
|
||||
|
||||
{{< highlight html >}}
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Example HTML5 Document</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Test</p>
|
||||
</body>
|
||||
</html>
|
||||
{{< /highlight >}}
|
||||
|
||||
## List Types
|
||||
|
||||
### Ordered List
|
||||
|
||||
1. First item
|
||||
2. Second item
|
||||
3. Third item
|
||||
|
||||
### Unordered List
|
||||
|
||||
* List item
|
||||
* Another item
|
||||
* And another item
|
||||
|
||||
### Nested list
|
||||
|
||||
* Fruit
|
||||
* Apple
|
||||
* Orange
|
||||
* Banana
|
||||
* Dairy
|
||||
* Milk
|
||||
* Cheese
|
||||
@ -0,0 +1,398 @@
|
||||
---
|
||||
weight: 15
|
||||
title: "Theme Documentation - Advanced"
|
||||
date: 2020-05-06T21:29:01+08:00
|
||||
description: "Discover how to maximise Gokarna's potential"
|
||||
tags: ["installation", "configuration", "markdown"]
|
||||
type: post
|
||||
showTableOfContents: true
|
||||
---
|
||||
|
||||
Gokarna is an opinionated theme with a focus on minimalism and simplicity.
|
||||
|
||||
## Content Types
|
||||
|
||||
This theme supports two types of content types: `post` and `page`. To specify them, you need to add them in your markdown metadata.
|
||||
|
||||
### Post
|
||||
|
||||
This is the default blog post type which will be shown in your "Posts" section and who's tags will be indexed. Basically, a normal blog post.
|
||||
|
||||
```markdown
|
||||
---
|
||||
title: "Hello, world!"
|
||||
date: 2021-01-01
|
||||
description: "A blog post"
|
||||
image: "/path/to/image.png"
|
||||
type: "post"
|
||||
tags: ["blog"]
|
||||
---
|
||||
|
||||
# Hello World!
|
||||
This is my blog.
|
||||
```
|
||||
|
||||
### Page
|
||||
|
||||
We introduced this type to distinguish between blog posts and normal markdown pages. The reason to create this was to give the user complete freedom in creating their website. You can use this to create a portfolio of your projects or showcase your designs. The possibilities are endless and the choice is yours.
|
||||
|
||||
```markdown
|
||||
---
|
||||
title: "Hello, world!"
|
||||
image: "/path/to/image.png"
|
||||
type: "page"
|
||||
---
|
||||
|
||||
# Projects
|
||||
Keep an eye on this space for my upcoming projects
|
||||
```
|
||||
|
||||
### Table of Contents
|
||||
|
||||
To show `Table of Contents`, update your config by adding
|
||||
```toml
|
||||
[markup]
|
||||
[markup.tableOfContents]
|
||||
startLevel = 1
|
||||
endLevel = 3
|
||||
ordered = false
|
||||
```
|
||||
|
||||
And then on each page add the attribute `showTableOfContents: true` **(Note: It is disabled by default)**
|
||||
|
||||
```markdown
|
||||
---
|
||||
title: "Hello, world!"
|
||||
image: "/path/to/image.png"
|
||||
type: "page"
|
||||
showTableOfContents: true
|
||||
---
|
||||
```
|
||||
|
||||
Detailed configuration can be found on [Hugo's official documentation](https://gohugo.io/getting-started/configuration-markup/#table-of-contents)
|
||||
|
||||
## Weights
|
||||
|
||||
The `weight` attribute can be added in the markdown metadata for `post` types. We have an option in our hugo.toml: `params.showPostsOnHomePage` which allows you to:
|
||||
|
||||
1. Show popular posts on home page if the value is set to `popular`. It sorts the all the posts by it's weight attribute in ascending order.
|
||||
2. Show recent posts on home page if the value is set to `recent`
|
||||
3. Do not show anything if the variable is unset or an empty string.
|
||||
|
||||
## Homepage
|
||||
|
||||
### About description text
|
||||
|
||||
In extension to the basic configuration with the `description` field, it's also possible to write the about section using markdown.
|
||||
|
||||
Create a file called `_index.md` in the `content` directory and write your content there.
|
||||
|
||||
> **Attention**: Don't use frontmatter in this file. It would also render it.
|
||||
|
||||
```markdown
|
||||
# Gokarna
|
||||
Gokarna is a small temple town located in the Uttara Kannada district of Karnataka state in southern India.
|
||||
|
||||
## Beaches
|
||||
Something about beaches, **which is *very* important**.
|
||||
|
||||
- every
|
||||
- beach
|
||||
- is beautiful
|
||||
```
|
||||
|
||||
Having the above about section in place, results in the following homepage:
|
||||
|
||||

|
||||
|
||||
|
||||
## Icons
|
||||
Gokarna supports popular social media icons (Github, Linkedin, Twitter, StackOverflow, Dribbble, etc.) out of the box. See full list of supported icons [on GitHub](https://github.com/gokarna-theme/gokarna-hugo/tree/main/static/icons).
|
||||
|
||||
### Icons on homepage
|
||||
|
||||
To display icons on the homepage, simply update the `socialIcons` config param with a list of name and url of each icon. The specified `name` should exactly match one of the names from [the `icons` directory](https://github.com/gokarna-theme/gokarna-hugo/tree/main/static/svg/icons).
|
||||
If you want to add more icons, you can download the svg directly from [Simple Icons' website](https://simpleicons.org/) and place them in your local icons directory (`/static/svg/icons/`)
|
||||
|
||||
```toml
|
||||
[params]
|
||||
socialIcons = [
|
||||
{name = "twitter", url = "https://example.com"},
|
||||
{name = "linkedin", url = "https://example.com"},
|
||||
{name = "stackoverflow", url = "https://example.com"},
|
||||
]
|
||||
```
|
||||
|
||||
Preview:
|
||||
|
||||

|
||||
|
||||
|
||||
### Icons in header
|
||||
|
||||
[Feather](https://feathericons.com) icons has a comprehensive list of icons which are more general purpose and not limited to social media.
|
||||
Therefore, we use feather as an additional source of icons. Here is an example of how to add custom icons in the header using feather:
|
||||
|
||||
```toml
|
||||
[[menu.main]]
|
||||
identifier = "github"
|
||||
url = "https://github.com"
|
||||
weight = 3
|
||||
# Using feather-icons
|
||||
pre = "<span data-feather='github'></span>"
|
||||
```
|
||||
|
||||
The same icon in this case could also be added without feather:
|
||||
|
||||
```toml
|
||||
[[menu.main]]
|
||||
identifier = "github"
|
||||
url = "https://www.buymeacoffee.com/"
|
||||
weight = 3
|
||||
# Without using feather-icons
|
||||
pre = "<img class='svg-inject' src='/icons/github.svg' />"
|
||||
```
|
||||
|
||||
You can add `params` allowing menu link to open in a new tab, for example:
|
||||
```toml
|
||||
[[menu.main]]
|
||||
identifier = "github"
|
||||
url = "https://github.com/zerodahero"
|
||||
weight = 4
|
||||
# We use feather-icons: https://feathericons.com/
|
||||
pre = "<span data-feather='github'></span>"
|
||||
[menu.main.params]
|
||||
newPage = true
|
||||
```
|
||||
|
||||
## Custom Head and Footer HTML
|
||||
|
||||
The goal of this feature is to give the user more control over the theme. It's functioning is very straightforward - "You can inject any HTML you want in the `<head>` tag" . This may seem simple at first, but it opens up a lot of possibilities.
|
||||
|
||||
## Custom Comment HTML
|
||||
|
||||
Similar to custom head and footer HTML, you can add custom HTML for comments at the end of every post. Its in a `<div>` with the id `comments` which can be then customized with your external CSS.
|
||||
|
||||
The purpose of this is to freely use any comments platform of your choosing
|
||||
|
||||
### For example
|
||||
```toml
|
||||
customCommentHTML = """
|
||||
<script src="https://utteranc.es/client.js"
|
||||
repo="526avijitgupta/gokarna"
|
||||
issue-term="title"
|
||||
theme="github-dark"
|
||||
crossorigin="anonymous"
|
||||
async></script>
|
||||
"""
|
||||
```
|
||||
|
||||
### Bring your own scripts
|
||||
|
||||
Add your own JavaScript or CSS by putting them in the `static/` folder and importing them into your HTML.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
customHeadHTML = '''
|
||||
<script>console.log("Custom script or import");</script>
|
||||
<script src="/js/custom.js"></script>
|
||||
'''
|
||||
customFooterHTML = '''
|
||||
<div>Comment SDK Integration</div>
|
||||
<script>console.log("Custom script or import");</script>
|
||||
<script src="/js/custom.js"></script>
|
||||
'''
|
||||
```
|
||||
|
||||
### Analytics
|
||||
|
||||
Integration with any analytics tool: This was a personal pet peeve. User privacy is our primary concern and this meant not using Google Analytics or any of the popular tools.
|
||||
|
||||
We preferred privacy friendly tools like [Umami](https://umami.is/) & [Fathom Analytics](https://usefathom.com/), but the downside was that no theme supported them out of the box which led to either changing the theme source code or contributing supporting code to the original theme (both of which are good ways to extend the theme, but not our ideal choice)
|
||||
|
||||
Giving users the freedom to add anything in the HTML via hugo.toml seemed like an elegant way to solve the problem.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
customHeadHTML = '''
|
||||
<script async defer data-website-id="website-id" src="https://analytics.example.com/script.js"></script>
|
||||
'''
|
||||
```
|
||||
|
||||
### KaTeX
|
||||
|
||||
KaTeX is a math typesetting library for the web which lets you write beautiful equations. To use it, add the javascript as mentioned in [their documentation](https://katex.org/docs/browser.html) in our `params.customHeadHTML`.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
customHeadHTML = '''
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.css" integrity="sha384-5TcZemv2l/9On385z///+d7MSYlvIEw9FuZTIdZ14vJLqWphw7e7ZPuOiCHJcFCP" crossorigin="anonymous">
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.js" integrity="sha384-cMkvdD8LoxVzGF/RPUKAcvmm49FQ0oxwDF3BGKtDXcEc+T1b2N+teh/OJfpU0jr6" crossorigin="anonymous"></script>
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/contrib/auto-render.min.js" integrity="sha384-hCXGrW6PitJEwbkoStFjeJxv+fSOOQKOPbJxSfM6G5sWZjAyWhXiTIIAmQqnlLlh" crossorigin="anonymous"
|
||||
onload="renderMathInElement(document.body);"></script>
|
||||
<script>
|
||||
document.addEventListener("DOMContentLoaded", function() {
|
||||
renderMathInElement(document.body, {
|
||||
// customised options
|
||||
// • auto-render specific keys, e.g.:
|
||||
delimiters: [
|
||||
{left: '$$', right: '$$', display: true},
|
||||
{left: '$', right: '$', display: false},
|
||||
],
|
||||
// • rendering keys, e.g.:
|
||||
throwOnError : false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
'''
|
||||
```
|
||||
|
||||
> Note: Make sure you use the latest version of KaTeX and use the correct script tags as described in [their documentation](https://katex.org/docs/browser.html)
|
||||
|
||||
Then the equation `$$y_t = \beta_0 + \beta_1 x_t + \epsilon_t$$` wrapped by double `$$` is displayed as:
|
||||
|
||||
$$y_t = \beta_0 + \beta_1 x_t + \epsilon_t$$
|
||||
ihl equation `$y_t = \beta_0 + \beta_1 x_t + \epsilon_t$` wrapped by single `$` is displayed inline as $y_t = \beta_0 + \beta_1 x_t + \epsilon_t$.
|
||||
|
||||
### Comments
|
||||
|
||||
Integration with any comments SDK is possible. All you have to do is add the relevant HTML/JavaScript in the `customFooterHTML` param.
|
||||
|
||||
An example with commento:
|
||||
|
||||
```toml
|
||||
[params]
|
||||
customFooterHTML = '''
|
||||
<div id="commento"></div>
|
||||
<script defer src="{{ .Site.Params.CommentoURL }}/js/commento.js"></script>
|
||||
<noscript>Please enable JavaScript to load the comments.</noscript>
|
||||
'''
|
||||
```
|
||||
|
||||
|
||||
## Syntax Highlighting
|
||||
|
||||
Hugo lets you choose the color scheme for the codeblocks. You can choose from the options here: https://xyproto.github.io/splash/docs/all.html
|
||||
|
||||
After choosing your theme, just update the `pygmentsStyle` attribute in hugo.toml.
|
||||
|
||||
```toml
|
||||
pygmentsStyle = "monokai"
|
||||
```
|
||||
|
||||
You can read more about syntax highlighting on the [official hugo docs](https://gohugo.io/content-management/syntax-highlighting/).
|
||||
|
||||
## Site Metadata
|
||||
|
||||
Gokarna enables you to improve the SEO performance of your website with minimal effort.
|
||||
|
||||
### Image preview
|
||||
|
||||
We make sure your pages are social media ready.
|
||||
|
||||

|
||||
|
||||
```markdown
|
||||
---
|
||||
title: "Hello, world!"
|
||||
image: "/path/to/image.png"
|
||||
---
|
||||
```
|
||||
|
||||
> Note: If no image is specified in the markdown metadata, the site avatar is automatically used instead.
|
||||
|
||||
### SEO keywords
|
||||
|
||||
The keywords relevant for SEO are composed of the page `tags` as defined below:
|
||||
|
||||
```markdown
|
||||
---
|
||||
title: "Hello, world!"
|
||||
tags: ["hello", "world"]
|
||||
---
|
||||
```
|
||||
|
||||
and the `metaKeywords` specified in the hugo.toml:
|
||||
|
||||
```markdown
|
||||
[params]
|
||||
metaKeywords = ["blog", "gokarna", "hugo"]
|
||||
```
|
||||
|
||||
## Page title and H1
|
||||
|
||||
By default, Gokarna uses `.Title` for the `<title>` and `<h1>` elements, in addition to the OpenGraph (`og:title`) and Twitter (`twitter:title`) properties within `<meta>` elements.
|
||||
|
||||
```yaml
|
||||
---
|
||||
title: "8 Facts About Me - #7 Will Shock You!"
|
||||
---
|
||||
```
|
||||
|
||||
To define H1 separately from the page title, use the `h1` param in your front matter:
|
||||
|
||||
```yaml
|
||||
---
|
||||
title: "8 Facts About Me - #7 Will Shock You!"
|
||||
h1: "8 Facts About Me"
|
||||
---
|
||||
```
|
||||
|
||||
## Hide tags, date or description of posts
|
||||
|
||||
Tags can be used to categorize posts (e.g.: Project or Blog), and be hidden on
|
||||
the posts. Use the `params.hiddenTags` field in `hugo.toml`.
|
||||
A post's date and description can be hidden if it has at least one tag listed in
|
||||
`params.tagsHidePostDate` or `params.tagsHidePostDescription`, respectively.
|
||||
|
||||
|
||||
```toml
|
||||
[params]
|
||||
[params.hidden]
|
||||
tags = ["project", "blog"]
|
||||
tagsPostDate = ["project"]
|
||||
tagsPostDescription = ["project"]
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
identifier = "projects"
|
||||
url = "/tags/project/"
|
||||
name = "My Projects"
|
||||
weight = 1
|
||||
[[menu.main]]
|
||||
identifier = "blog"
|
||||
url = "/tags/blog/"
|
||||
name = "Blog"
|
||||
weight = 2
|
||||
```
|
||||
|
||||
## Site-wide copyright notice
|
||||
|
||||
Define the [copyright notice for your site](https://gohugo.io/methods/site/copyright/). The notice will only be displayed on [page Kinds](#content-types).
|
||||
|
||||
For example, the following configuration in `hugo.toml` and front matter respectively...
|
||||
|
||||
```toml
|
||||
copyright = "Verbatim copying and distribution of this entire article are permitted worldwide, without royalty, in any medium, provided this notice is preserved."
|
||||
```
|
||||
|
||||
```
|
||||
date: 2020-06-17
|
||||
lastmod: 2024-02-05
|
||||
```
|
||||
|
||||
Will produce this footer:
|
||||
|
||||
> © 2020-2024 The Marauders Verbatim copying and distribution of this entire article are permitted worldwide, without royalty, in any medium, provided this notice is preserved.
|
||||
|
||||
`copyright` can include [Markdown syntax](https://www.markdownguide.org/tools/hugo/). This is best used for including hyperlinks, emoji, or text formatting.
|
||||
|
||||
The years of `.Date` and `.Lastmod` are used to create a date range for your copyrighted material.
|
||||
|
||||
## Minification
|
||||
|
||||
`hugo`'s HTML output can be [minified](https://gohugo.io/hugo-pipes/minification/#usage), resulting in smaller files. This makes your site more performant (especially when paired with compression), and may confer a better [Google Lighthouse](https://pagespeed.web.dev/) score.
|
||||
|
||||
```toml
|
||||
[minify]
|
||||
minifyOutput = true
|
||||
```
|
||||
@ -0,0 +1,345 @@
|
||||
---
|
||||
weight: 10
|
||||
title: "Theme Documentation - Basics"
|
||||
date: 2020-03-06T21:29:01+08:00
|
||||
description: "A guide to getting started with Gokarna"
|
||||
tags: ["installation", "configuration", "markdown"]
|
||||
type: post
|
||||
showTableOfContents: true
|
||||
---
|
||||
|
||||
Gokarna is an opinionated theme with a focus on minimalism and simplicity.
|
||||
|
||||
## Installation
|
||||
|
||||
Follow these steps to initialize your new website.
|
||||
|
||||
If you are new to [Hugo](https://gohugo.io/), we suggest following this [great documentation for beginners](https://gohugo.io/getting-started/quick-start/).
|
||||
|
||||
### a. Create Your Project {#create-your-project}
|
||||
|
||||
Hugo provides a `new` subcommand to create a new website:
|
||||
|
||||
```bash
|
||||
hugo new site my-website
|
||||
cd my-website
|
||||
```
|
||||
|
||||
### b. Install the Theme {#install-the-theme}
|
||||
|
||||
The theme's repository is: [https://github.com/gokarna-theme/gokarna-hugo](https://github.com/gokarna-theme/gokarna-hugo).
|
||||
|
||||
Make this repository a submodule of your Git project:
|
||||
|
||||
```bash
|
||||
git init
|
||||
git submodule add https://github.com/gokarna-theme/gokarna-hugo.git themes/gokarna
|
||||
```
|
||||
|
||||
### c. Basic Configuration {#basic-configuration}
|
||||
|
||||
A simple Hugo [configuration file](https://gohugo.io/getting-started/configuration/#configuration-file) with [menu items](https://gohugo.io/content-management/menus/#properties-front-matter).
|
||||
|
||||
Gokarna supports [adding Feather icons to the header](/posts/theme-documentation-advanced/#icons-in-header).
|
||||
|
||||
```toml
|
||||
baseURL = "https://example.org/"
|
||||
defaultContentLanguage = "en"
|
||||
# Automatically generate robots.txt
|
||||
enableRobotsTXT = true
|
||||
languageCode = "en"
|
||||
theme = "gokarna"
|
||||
title = "My New Hugo Site"
|
||||
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
# Display name
|
||||
name = "Posts"
|
||||
|
||||
# Relative URL slug (appended to baseURL)
|
||||
url = "/posts/"
|
||||
|
||||
# Lower weights are listed first in the menu (leftmost); higher weights are
|
||||
# listed last in the menu (rightmost)
|
||||
weight = 1
|
||||
|
||||
[[menu.main]]
|
||||
name = "Tags"
|
||||
url = "/tags/"
|
||||
weight = 2
|
||||
|
||||
[[menu.main]]
|
||||
# Unique identifiers are required for menu entries without a name property,
|
||||
# or for menu entries which re-use a name
|
||||
identifier = "github"
|
||||
|
||||
# Absolute URL to external resource
|
||||
url = "https://github.com"
|
||||
weight = 3
|
||||
|
||||
# Surround the menu entry (or name) with HTML content, such as Feather
|
||||
# icons: https://feathericons.com
|
||||
pre = "<span data-feather='github'></span>"
|
||||
post = ""
|
||||
```
|
||||
|
||||
|
||||
### d. Create Your First Post {#create-your-first-post}
|
||||
|
||||
Use the [`new` subcommand](https://gohugo.io/commands/hugo_new/#hugo-new) to create a post (in [the `content/` directory](https://gohugo.io/content-management/organization/#organization-of-content-source)):
|
||||
|
||||
```bash
|
||||
hugo new posts/'My First Post'.md
|
||||
```
|
||||
|
||||
Two [content types](https://gohugo.io/content-management/types/) are supported in Gokarna:
|
||||
|
||||
1. `type: "post"`
|
||||
|
||||
A blog post consisting of a [page title](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title#page_titles_and_seo), [meta description](https://developer.mozilla.org/en-US/docs/Learn/HTML/Introduction_to_HTML/The_head_metadata_in_HTML#adding_an_author_and_description), creation/last modified dates, [SEO keywords (tags)](/posts/theme-documentation-advanced/#seo-keywords), and Markdown content.
|
||||
|
||||
Read more about Posts in the [advanced documentation](/posts/theme-documentation-advanced/#post).
|
||||
|
||||
2. `type: "page"`
|
||||
|
||||
A standalone page which only renders Markdown. Best used for custom pages (e.g. your [portfolio](/projects/)) which should not feature in your [Posts](/posts/) timeline.
|
||||
|
||||
Read more about Pages in the [advanced documentation](/posts/theme-documentation-advanced/#page).
|
||||
|
||||
#### Using archetypes
|
||||
|
||||
`hugo new` will automatically use an appropriate [archetype](https://gohugo.io/content-management/archetypes/#lookup-order) (see [`archetypes/`](https://github.com/gokarna-theme/gokarna-hugo/tree/main/archetypes)) and insert [front matter](https://gohugo.io/content-management/front-matter/) depending on the location of your content:
|
||||
|
||||
- `hugo new posts/$post-name.md` automatically sets `type: "post"`
|
||||
- `hugo new $page-name.md` automatically sets `type: "page"`
|
||||
|
||||
Gokarna employs [custom front matter](/posts/theme-documentation-advanced/#content-types), which is included in the archetypes:
|
||||
|
||||
- The creation date of the file is automatically set (e.g. `date: 2023-12-25`)
|
||||
- The file name is used as the default title (e.g. `title: "My First Post"`)
|
||||
|
||||
### e. Launching the Website Locally {#launching-the-website-locally}
|
||||
|
||||
Use the [`server` subcommand](https://gohugo.io/commands/hugo_server/#synopsis) to view your site.
|
||||
|
||||
```bash
|
||||
hugo server
|
||||
```
|
||||
|
||||
Go to [`http://localhost:1313`](http://localhost:1313/) (if no other Hugo servers are running; Hugo will use an [ephemeral port](https://en.wikipedia.org/wiki/Ephemeral_port) if one or more servers are running concurrently on the host).
|
||||
|
||||
### f. Build the Website {#build-the-website}
|
||||
|
||||
Use the `hugo` command to build your site.
|
||||
|
||||
```bash
|
||||
hugo
|
||||
```
|
||||
|
||||
A `public` folder will be generated, containing all static content and assets for your website. It can be hosted on any web server.
|
||||
|
||||
The website can be automatically published and hosted with [Netlify](https://www.netlify.com/), [AWS Amplify](https://gohugo.io/hosting-and-deployment/hosting-on-aws-amplify/), [GitHub Pages](https://gohugo.io/hosting-and-deployment/hosting-on-github/), [Render](https://gohugo.io/hosting-and-deployment/hosting-on-render/), and more...
|
||||
|
||||
## Configuration
|
||||
|
||||
In addition to [Hugo global configuration](https://gohugo.io/overview/configuration/) and [menu configuration](#basic-configuration), Gokarna lets you define the following [parameters](https://gohugo.io/methods/site/params/) in your site configuration.
|
||||
|
||||
See this sample `hugo.toml`, which uses Gokarna's default values, and [exampleSite's `hugo.toml`](https://github.com/gokarna-theme/gokarna-hugo/blob/main/exampleSite/hugo.toml):
|
||||
|
||||
```toml
|
||||
[params]
|
||||
# Choose the color shown when hyperlinks are hovered over
|
||||
accentColor = "#FF4D4D"
|
||||
|
||||
# Resource URL for the site avatar (home page and header)
|
||||
avatarURL = "/images/avatar.webp"
|
||||
|
||||
# Describe the avatar for screen readers
|
||||
avatarAltText = "avatar"
|
||||
|
||||
# Set the avatar's size: size-xs, size-s, size-m, size-l & size-xl
|
||||
avatarSize = "size-m"
|
||||
|
||||
# Inject arbitrary HTML via the <head> tag
|
||||
# Best used for importing custom JavaScript, CSS, or analytics
|
||||
customHeadHTML = ""
|
||||
|
||||
# Configure how post dates are displayed
|
||||
dateFormat = "January 2, 2006"
|
||||
|
||||
# Home page meta description
|
||||
description = "Sky above, sand below & peace within"
|
||||
|
||||
# Footer text (i.e. author/project name)
|
||||
footer = "The Marauders"
|
||||
|
||||
# Define SEO keywords
|
||||
metaKeywords = ["blog", "gokarna", "hugo"]
|
||||
|
||||
# Define how many posts are displayed on the home page
|
||||
# showPostsOnHomePage must be "popular" or "recent"
|
||||
numberPostsOnHomePage = 4
|
||||
|
||||
# Display a "back to top" button on posts and pages: true, false
|
||||
# May not render on smaller screen sizes
|
||||
showBackToTopButton = true
|
||||
|
||||
# Display posts on the home page:
|
||||
# "popular" (order posts by weight)
|
||||
# "recent" (order posts by date)
|
||||
# "", unset (do not display)
|
||||
showPostsOnHomePage = ""
|
||||
|
||||
# Show the previous and next post in your timeline: "true", "false"
|
||||
# Incompatible with Weight
|
||||
togglePreviousAndNextButtons = false
|
||||
```
|
||||
|
||||
### Accent color
|
||||
|
||||
The color displayed when a user hovers over hyperlinks (`<a>` tags), expressed as a [hexadecimal](https://developer.mozilla.org/en-US/docs/Web/CSS/hex-color).
|
||||
|
||||
```toml
|
||||
[params]
|
||||
accentColor = "#FF4D4D"
|
||||
```
|
||||
|
||||
### Avatar URL
|
||||
|
||||
The avatar's resource URL, displayed on the [home page](/) and header (top-left).
|
||||
|
||||
Images are typically placed into the [`assets/`](https://gohugo.io/getting-started/directory-structure/#assets) or [`static/`](https://gohugo.io/getting-started/directory-structure/#static) directories (which are copied to the top-level directory [at build time](#build-the-website)).
|
||||
|
||||
```toml
|
||||
[params]
|
||||
avatarURL = "/images/avatar.webp"
|
||||
```
|
||||
|
||||
### Avatar size
|
||||
|
||||
Set the avatar's size as: `size-xs`, `size-s`, `size-m`, `size-l`, or `size-xl`.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
avatarSize = "size-m"
|
||||
```
|
||||
|
||||
### Custom Head HTML
|
||||
|
||||
Add arbitrary HTML code to the [`<head>` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/head).
|
||||
|
||||
```toml
|
||||
[params]
|
||||
customHeadHTML = "<script>console.log('Any HTML')</script>"
|
||||
```
|
||||
|
||||
Examples are available in the [advanced documentation](/posts/theme-documentation-advanced/#bring-your-own-scripts).
|
||||
|
||||
### Date format
|
||||
|
||||
[Configure how posts date are displayed](https://gohugo.io/functions/time/format/), using [date strings](https://pkg.go.dev/time#pkg-constants).
|
||||
|
||||
```toml
|
||||
[params]
|
||||
dateFormat = "2 January, 2006"
|
||||
```
|
||||
|
||||
### Description
|
||||
|
||||
[Meta description](https://developer.mozilla.org/en-US/docs/Learn/HTML/Introduction_to_HTML/The_head_metadata_in_HTML#adding_an_author_and_description) to display on the home page, below the title and avatar.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
description = "Sky above, sand below & peace within"
|
||||
```
|
||||
|
||||
### Display content on the home page
|
||||
|
||||
Markdown content in `content/_index.md` will be rendered on the home page, below the social icons.
|
||||
|
||||
### Display posts on the home page
|
||||
|
||||
Recent and popular posts can be shown on the home page:
|
||||
|
||||
- `popular`: Sort posts in ascending order of their [Weight](https://gohugo.io/methods/page/weight/)
|
||||
|
||||
**If any post on your site defines `weight`, you cannot enable [Previous and Next buttons](#previous-and-next-buttons).**
|
||||
|
||||
- `recent`: Sort posts in ascending order of [Date](https://gohugo.io/methods/page/date/)
|
||||
|
||||
- Do not show anything if the variable is:
|
||||
- unset
|
||||
- an empty string (`""`)
|
||||
|
||||
The number of posts displayed on the home page can be changed by setting `numberPostsOnHomePage`. If `numberPostsOnHomePage` is equal to `""` or `0`, the default value (`4`) is used.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
showPostsOnHomePage = ""
|
||||
numberPostsOnHomePage = 4
|
||||
```
|
||||
|
||||
### Favicons
|
||||
|
||||
Place favicons into the `static/` directory. The following files are supported:
|
||||
|
||||
- `apple-touch-icon.png` (180x180)
|
||||
- `favicon-32x32.png` (32x32)
|
||||
- `favicon-16x16.png` (16x16)
|
||||
- `mstile-150x150.png` (150x150)
|
||||
- `android-chrome-192x192.png` (192x192)
|
||||
- `android-chrome-512x512.png` (512x512)
|
||||
|
||||
Favicons can be generated using services such as [favicon.io](https://favicon.io), or [realfavicongenerator.net](https://realfavicongenerator.net/).
|
||||
|
||||
### Font size
|
||||
|
||||
Set the content [`font-size`](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size).
|
||||
|
||||
Note that '[defining font sizes in px is not accessible](https://developer.mozilla.org/en-US/docs/Web/CSS/font-size#pixels)'.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
fontSize = "1.1rem" # equal to 17.6px
|
||||
```
|
||||
|
||||
### Footer
|
||||
|
||||
Text to display in the footer section, typically the name of the author or project.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
footer = "The Marauders"
|
||||
```
|
||||
|
||||
`footer` can include [Markdown syntax](https://www.markdownguide.org/tools/hugo/) - best used for including hyperlinks, emoji, or text formatting.
|
||||
|
||||
### Previous and Next buttons
|
||||
|
||||
At the bottom of a post, show the previous and next post chronologically.
|
||||
|
||||
**Warning**: Not compatible with the `.Weight` parameter.
|
||||
|
||||
If any post front matter contains `weight`, the posts will not appear by Date. See [Hugo's default sort](https://gohugo.io/templates/lists#default-weight--date--linktitle--filepath).
|
||||
|
||||
```toml
|
||||
[params]
|
||||
togglePreviousAndNextButtons = false
|
||||
```
|
||||
|
||||
### Reading time
|
||||
|
||||
Display a post's [estimated reading time](https://gohugo.io/methods/page/readingtime/) in minutes.
|
||||
|
||||
```toml
|
||||
[params]
|
||||
displayReadingTime = false
|
||||
```
|
||||
|
||||
### robots.txt
|
||||
|
||||
[Automatically generate](https://gohugo.io/templates/robots/) a `robots.txt` file, used to ['manage crawler traffic to your site'](https://developers.google.com/search/docs/crawling-indexing/robots/intro).
|
||||
|
||||
```toml
|
||||
enableRobotsTXT = true
|
||||
```
|
||||
10
themes/gokarna/exampleSite/content/projects/_index.md
Normal file
@ -0,0 +1,10 @@
|
||||
---
|
||||
title: "Projects"
|
||||
type: page
|
||||
---
|
||||
|
||||
## Hello, my projects are:
|
||||
|
||||
1. [Tatooine](/projects/tatooine/)
|
||||
2. [Hydra](/projects/hydra/)
|
||||
3. [Bludhaven](/projects/bludhaven/)
|
||||
8
themes/gokarna/exampleSite/content/projects/bludhaven.md
Normal file
@ -0,0 +1,8 @@
|
||||
---
|
||||
title: Blüdhaven
|
||||
type: page
|
||||
---
|
||||
|
||||
## History
|
||||
|
||||
Blüdhaven was a former whaling town, which was officially incorporated as a "Commonwealth" in 1912. The town had a generally poor socio-economic populace, owing in part to failed efforts to transform itself into a manufacturing and shipping center.
|
||||
8
themes/gokarna/exampleSite/content/projects/hydra.md
Normal file
@ -0,0 +1,8 @@
|
||||
---
|
||||
title: Hydra
|
||||
type: page
|
||||
---
|
||||
|
||||
## Motto
|
||||
|
||||
Cut off one head, and two will take their place.
|
||||
8
themes/gokarna/exampleSite/content/projects/tatooine.md
Normal file
@ -0,0 +1,8 @@
|
||||
---
|
||||
title: Tatooine
|
||||
type: page
|
||||
---
|
||||
|
||||
## A long time ago in a galaxy far, far away....
|
||||
|
||||
A project was planned, but never completed.
|
||||
102
themes/gokarna/exampleSite/hugo.toml
Normal file
@ -0,0 +1,102 @@
|
||||
baseURL = "https://gokarna-hugo.netlify.app"
|
||||
defaultContentLanguage = "en"
|
||||
enableEmoji = true
|
||||
enableRobotsTXT = true
|
||||
languageCode = "en"
|
||||
# Choose one of emacs, trac or perldoc
|
||||
pygmentsStyle = "monokai"
|
||||
theme = "gokarna"
|
||||
title = "Gokarna"
|
||||
|
||||
[params]
|
||||
avatarAltText = "avatar"
|
||||
avatarSize = "size-m"
|
||||
avatarURL = "/images/avatar.webp"
|
||||
|
||||
customHeadHTML = """
|
||||
<!-- KaTeX -->
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.css" integrity="sha384-5TcZemv2l/9On385z///+d7MSYlvIEw9FuZTIdZ14vJLqWphw7e7ZPuOiCHJcFCP" crossorigin="anonymous">
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/katex.min.js" integrity="sha384-cMkvdD8LoxVzGF/RPUKAcvmm49FQ0oxwDF3BGKtDXcEc+T1b2N+teh/OJfpU0jr6" crossorigin="anonymous"></script>
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.22/dist/contrib/auto-render.min.js" integrity="sha384-hCXGrW6PitJEwbkoStFjeJxv+fSOOQKOPbJxSfM6G5sWZjAyWhXiTIIAmQqnlLlh" crossorigin="anonymous"></script>
|
||||
<script>
|
||||
document.addEventListener("DOMContentLoaded", function() {
|
||||
renderMathInElement(document.body, {
|
||||
// customised options
|
||||
// • auto-render specific keys, e.g.:
|
||||
delimiters: [
|
||||
{left: '$$', right: '$$', display: true},
|
||||
{left: '$', right: '$', display: false},
|
||||
],
|
||||
// • rendering keys, e.g.:
|
||||
throwOnError : false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
"""
|
||||
|
||||
description = "Sky above, sand below and peace within"
|
||||
footer = "The Marauders"
|
||||
metaKeywords = ["blog", "gokarna", "hugo"]
|
||||
showBackToTopButton = true # true or false for "back to top" button on posts and pages
|
||||
|
||||
socialIcons = [
|
||||
{name = "twitter", url = "https://example.com"},
|
||||
{name = "linkedin", url = "https://example.com"},
|
||||
{name = "stackoverflow", url = "https://example.com"},
|
||||
{name = "dribbble", url = "https://example.com"},
|
||||
{name = "instagram", url = "https://example.com"},
|
||||
{name = "twitch", url = "https://example.com"},
|
||||
{name = "email", url = "mailto:example@example.com"}
|
||||
]
|
||||
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
name = "Home"
|
||||
pre = "<span data-feather='home'></span>"
|
||||
url = "/"
|
||||
weight = 1
|
||||
|
||||
[[menu.main]]
|
||||
name = "Posts"
|
||||
pre = "<span data-feather='book'></span>"
|
||||
url = "/posts/"
|
||||
weight = 2
|
||||
|
||||
[[menu.main]]
|
||||
name = "Projects"
|
||||
pre = "<span data-feather='code'></span>"
|
||||
url = "/projects/"
|
||||
weight = 3
|
||||
|
||||
[[menu.main]]
|
||||
name = "Tags"
|
||||
pre = "<span data-feather='tag'></span>"
|
||||
url = "/tags/"
|
||||
weight = 4
|
||||
|
||||
[[menu.main]]
|
||||
identifier = "github"
|
||||
pre = "<span data-feather='github'></span>"
|
||||
url = "https://github.com/gokarna-theme/gokarna-hugo"
|
||||
weight = 5
|
||||
|
||||
[[menu.main]]
|
||||
identifier = "buymeacoffee"
|
||||
pre = "<span data-feather='coffee'></span>"
|
||||
url = "https://www.buymeacoffee.com/avijitgupta"
|
||||
weight = 6
|
||||
|
||||
[[menu.main]]
|
||||
identifier = "rss"
|
||||
pre = "<span data-feather='rss'></span>"
|
||||
url = "/index.xml"
|
||||
weight = 7
|
||||
|
||||
[markup]
|
||||
[markup.tableOfContents]
|
||||
startLevel = 1
|
||||
endLevel = 4
|
||||
ordered = false
|
||||
|
||||
[minify]
|
||||
minifyOutput = true
|
||||
BIN
themes/gokarna/exampleSite/static/android-chrome-192x192.png
Normal file
|
After Width: | Height: | Size: 56 KiB |
BIN
themes/gokarna/exampleSite/static/android-chrome-512x512.png
Normal file
|
After Width: | Height: | Size: 306 KiB |
BIN
themes/gokarna/exampleSite/static/apple-touch-icon.png
Normal file
|
After Width: | Height: | Size: 50 KiB |
BIN
themes/gokarna/exampleSite/static/favicon-16x16.png
Normal file
|
After Width: | Height: | Size: 811 B |
BIN
themes/gokarna/exampleSite/static/favicon-32x32.png
Normal file
|
After Width: | Height: | Size: 2.4 KiB |
BIN
themes/gokarna/exampleSite/static/favicon.ico
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
themes/gokarna/exampleSite/static/images/avatar.webp
Normal file
|
After Width: | Height: | Size: 32 KiB |
|
After Width: | Height: | Size: 81 KiB |
|
After Width: | Height: | Size: 70 KiB |
|
After Width: | Height: | Size: 71 KiB |
|
After Width: | Height: | Size: 439 KiB |
1
themes/gokarna/exampleSite/static/site.webmanifest
Normal file
@ -0,0 +1 @@
|
||||
{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}
|
||||
1
themes/gokarna/exampleSite/themes/gokarna
Symbolic link
@ -0,0 +1 @@
|
||||
../../
|
||||
18
themes/gokarna/i18n/de.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Letzte Einträge'
|
||||
[Popular]
|
||||
others = 'Einträge'
|
||||
[error404]
|
||||
other = 'Diese Seite existiert (noch) nicht, gehen Sie zu zurück auf'
|
||||
[home]
|
||||
other = 'Startseite'
|
||||
[nothing]
|
||||
other = 'Hier gibt es noch nichts zu sehen 😉'
|
||||
[previous]
|
||||
other = 'Vorheriger Eintrag'
|
||||
[next]
|
||||
other = 'Nächster Eintrag'
|
||||
[tags]
|
||||
other = 'Tags'
|
||||
[Posts]
|
||||
other = 'Einträge'
|
||||
18
themes/gokarna/i18n/en.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Recent Posts'
|
||||
[Popular]
|
||||
other = 'Posts'
|
||||
[error404]
|
||||
other = 'This page does not exist, go'
|
||||
[home]
|
||||
other = 'home'
|
||||
[nothing]
|
||||
other = 'Nothing to see here, yet 😉'
|
||||
[previous]
|
||||
other = 'Previous'
|
||||
[next]
|
||||
other = 'Next'
|
||||
[tags]
|
||||
other = 'Tags'
|
||||
[Posts]
|
||||
other = 'Posts'
|
||||
18
themes/gokarna/i18n/es.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Recientes entradas'
|
||||
[Popular]
|
||||
other = 'Entradas'
|
||||
[error404]
|
||||
other = 'Esta página no existe, prueba de nuevo desde el'
|
||||
[home]
|
||||
other = 'comienzo'
|
||||
[nothing]
|
||||
other = 'Aún no hay nada aquí 😉'
|
||||
[previous]
|
||||
other = 'Anterior'
|
||||
[next]
|
||||
other = 'Siguiente'
|
||||
[tags]
|
||||
other = 'Etiquetas'
|
||||
[Posts]
|
||||
other = 'Entradas'
|
||||
18
themes/gokarna/i18n/fr.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Posts récents'
|
||||
[Popular]
|
||||
other = 'Posts'
|
||||
[error404]
|
||||
other = "Cette page n'existe pas, retourner à la"
|
||||
[home]
|
||||
other = 'page principale'
|
||||
[nothing]
|
||||
other = 'Rien à voir ici pour le moment 😉'
|
||||
[previous]
|
||||
other = 'Précédent'
|
||||
[next]
|
||||
other = 'Suivant'
|
||||
[tags]
|
||||
other = 'Tags'
|
||||
[Posts]
|
||||
other = 'Posts'
|
||||
18
themes/gokarna/i18n/pl.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Ostatnie posty'
|
||||
[Popular]
|
||||
other = 'Posty'
|
||||
[error404]
|
||||
other = 'Ta strona nie istnieje, przejdź na '
|
||||
[home]
|
||||
other = 'start'
|
||||
[nothing]
|
||||
other = 'Na razie tu nic nie ma 😉'
|
||||
[previous]
|
||||
other = 'Poprzedni'
|
||||
[next]
|
||||
other = 'Następny'
|
||||
[tags]
|
||||
other = 'Tagi'
|
||||
[Posts]
|
||||
other = 'Posty'
|
||||
18
themes/gokarna/i18n/pt.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = 'Postagens Recentes'
|
||||
[Popular]
|
||||
other = 'Postagens'
|
||||
[error404]
|
||||
other = 'Esta página não existe, vá'
|
||||
[home]
|
||||
other = 'Início'
|
||||
[nothing]
|
||||
other = 'Nada para ver aqui, ainda 😉'
|
||||
[previous]
|
||||
other = 'Anterior'
|
||||
[next]
|
||||
other = 'Próximo'
|
||||
[tags]
|
||||
other = 'Marcadores'
|
||||
[Posts]
|
||||
other = 'Postagens'
|
||||
14
themes/gokarna/i18n/ru.toml
Normal file
@ -0,0 +1,14 @@
|
||||
[Recent]
|
||||
other = 'Новые'
|
||||
[error404]
|
||||
other = 'Данная страница не существует'
|
||||
[home]
|
||||
other = 'домой'
|
||||
[nothing]
|
||||
other = 'Здесь пока нечего смотреть 😉'
|
||||
[previous]
|
||||
other = 'Предыдущий'
|
||||
[next]
|
||||
other = 'Вперед'
|
||||
[tags]
|
||||
other = 'Теги'
|
||||
18
themes/gokarna/i18n/zh-tw.toml
Normal file
@ -0,0 +1,18 @@
|
||||
[Recent]
|
||||
other = '最近的文章'
|
||||
[Popular]
|
||||
other = '文章'
|
||||
[error404]
|
||||
other = '這個頁面並不存在'
|
||||
[home]
|
||||
other = '首頁'
|
||||
[nothing]
|
||||
other = '目前沒有東西存在 😉'
|
||||
[previous]
|
||||
other = '前一則'
|
||||
[next]
|
||||
other = '下一則'
|
||||
[tags]
|
||||
other = '標籤'
|
||||
[Posts]
|
||||
other = '文章'
|
||||
BIN
themes/gokarna/images/gokarna.jpg
Normal file
|
After Width: | Height: | Size: 5.9 MiB |
BIN
themes/gokarna/images/lighthouse.png
Normal file
|
After Width: | Height: | Size: 142 KiB |
BIN
themes/gokarna/images/screenshot-dark-home.png
Normal file
|
After Width: | Height: | Size: 117 KiB |
BIN
themes/gokarna/images/screenshot-dark-list.png
Normal file
|
After Width: | Height: | Size: 85 KiB |
BIN
themes/gokarna/images/screenshot-dark-post.png
Normal file
|
After Width: | Height: | Size: 162 KiB |
BIN
themes/gokarna/images/screenshot-light-home.png
Normal file
|
After Width: | Height: | Size: 111 KiB |
BIN
themes/gokarna/images/screenshot-light-list.png
Normal file
|
After Width: | Height: | Size: 77 KiB |
BIN
themes/gokarna/images/screenshot-light-post.png
Normal file
|
After Width: | Height: | Size: 142 KiB |
BIN
themes/gokarna/images/screenshot.png
Normal file
|
After Width: | Height: | Size: 82 KiB |
BIN
themes/gokarna/images/tn.png
Normal file
|
After Width: | Height: | Size: 82 KiB |
19
themes/gokarna/layouts/404.html
Normal file
@ -0,0 +1,19 @@
|
||||
{{ define "main"}}
|
||||
|
||||
<div class="text-404">
|
||||
<h1 class="error-emoji"></h1>
|
||||
<h2>
|
||||
404 ... {{ i18n "error404" . }} <a href="{{ .Site.BaseURL }}">{{ i18n "home" }}</a>
|
||||
</h2>
|
||||
</div>
|
||||
<script>
|
||||
const errorEmojiContainer = document.getElementsByClassName('error-emoji')[0];
|
||||
const emojiArray = [
|
||||
'\\(o_o)/', '(o^^)o', '(˚Δ˚)b', '(^-^*)', '(≥o≤)', '(^_^)b', '(·_·)',
|
||||
'(=\'X\'=)', '(>_<)', '(;-;)', '\\(^Д^)/',
|
||||
];
|
||||
const errorEmoji = emojiArray[Math.floor(Math.random() * emojiArray.length)];
|
||||
errorEmojiContainer.appendChild(document.createTextNode(errorEmoji));
|
||||
</script>
|
||||
|
||||
{{ end }}
|
||||
21
themes/gokarna/layouts/_default/baseof.html
Normal file
@ -0,0 +1,21 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
{{- $avatarImgSrc := .Site.Params.AvatarURL -}}
|
||||
{{- if and (isset .Site.Params "avatarURL") (not (hasPrefix $avatarImgSrc "http")) -}}
|
||||
{{- $avatarImgSrc = (urls.JoinPath $.Site.BaseURL ($.Site.Params.AvatarURL | default "")) -}}
|
||||
{{- end -}}
|
||||
{{- .Scratch.Set "avatarImgSrc" $avatarImgSrc -}}
|
||||
|
||||
{{- partial "head.html" . -}}
|
||||
<body>
|
||||
<script>
|
||||
// Immediately set theme on page load
|
||||
setThemeByUserPref();
|
||||
</script>
|
||||
{{- partial "header.html" . -}}
|
||||
<main id="content">
|
||||
{{- block "main" . }}{{- end }}
|
||||
</main>
|
||||
{{- partial "footer.html" . -}}
|
||||
</body>
|
||||
</html>
|
||||
7
themes/gokarna/layouts/_default/list.html
Normal file
@ -0,0 +1,7 @@
|
||||
{{ define "main" }}
|
||||
{{ if eq .Type "page" }}
|
||||
{{- partial "page.html" . -}}
|
||||
{{ else }}
|
||||
{{- partial "list.html" . -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
11
themes/gokarna/layouts/_default/single.html
Normal file
@ -0,0 +1,11 @@
|
||||
{{ define "main" }}
|
||||
{{ if eq .Type "post" }}
|
||||
{{- partial "post.html" . -}}
|
||||
{{- partial "toc.html" . -}}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq .Type "page" }}
|
||||
{{- partial "page.html" . -}}
|
||||
{{- partial "toc.html" . -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
21
themes/gokarna/layouts/_default/terms.html
Normal file
@ -0,0 +1,21 @@
|
||||
{{ define "main" }}
|
||||
<div class="container tags-list">
|
||||
|
||||
<h1 class="list-title">{{ i18n "tags" }}</h1>
|
||||
{{if eq (len $.Site.Taxonomies.tags) 0}}
|
||||
{{ i18n "nothing" }}
|
||||
{{else}}
|
||||
<ul class="post-tags">
|
||||
{{ range $.Site.Taxonomies.tags.ByCount }}
|
||||
<li class="post-tag">
|
||||
<a href="{{ .Page.RelPermalink }}">
|
||||
<div class="tag-name">{{ .Name }}</div>
|
||||
<div class="tag-posts-count">{{ .Count }}</div>
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
|
||||
</div>
|
||||
{{ end }}
|
||||
59
themes/gokarna/layouts/index.html
Normal file
@ -0,0 +1,59 @@
|
||||
{{ define "main" }}
|
||||
<section class="home-about">
|
||||
<div class="avatar">
|
||||
{{ if isset .Site.Params "avatarurl" }}
|
||||
<img class={{ .Site.Params.AvatarSize | default "size-m" }} src='{{ .Scratch.Get "avatarImgSrc" }}' alt="{{ .Site.Params.AvatarAltText|default "avatar" }}">
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<h1>{{ .Site.Title }}</h1>
|
||||
{{ if isset .Site.Params "description" }}
|
||||
<h2>{{ .Site.Params.Description }}</h2>
|
||||
{{ end }}
|
||||
|
||||
</section>
|
||||
|
||||
<div class="flex-break"></div>
|
||||
|
||||
{{ if isset .Site.Params "socialicons" }}
|
||||
<div class="gk-social-icons">
|
||||
<ul class="gk-social-icons-list">
|
||||
{{ range .Site.Params.SocialIcons }}
|
||||
<li class="gk-social-icon">
|
||||
<a href="{{ .url }}" target="_blank" rel="{{ if .rel }}{{ .rel }} {{ end }}noopener noreferrer" aria-label="Learn more on {{ .name }}">
|
||||
<img class="svg-inject" src="{{ relURL "svg/icons/" }}{{ .name | lower }}.svg" alt="">
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
{{ if (or
|
||||
(and (fileExists "content/_index.md") .Content)
|
||||
(fileExists "content/index-about.md")) }}
|
||||
<section class="home-content">
|
||||
{{ or .Content (readFile "index-about.md" | markdownify) }}
|
||||
</section>
|
||||
{{ end }}
|
||||
|
||||
{{ if isset .Site.Params "showpostsonhomepage" }}
|
||||
|
||||
<div class="home-posts list-posts">
|
||||
<h2>{{ i18n (.Site.Params.ShowPostsOnHomePage | humanize) }}</h2>
|
||||
|
||||
{{ $posts := where .Site.Pages "Params.type" "post" }}
|
||||
|
||||
{{ if eq .Site.Params.ShowPostsOnHomePage "popular" }}
|
||||
{{ range $posts.ByWeight | first (or .Site.Params.NumberPostsOnHomePage 4) }}
|
||||
{{- partial "list-posts.html" . -}}
|
||||
{{ end }}
|
||||
{{ else if eq .Site.Params.ShowPostsOnHomePage "recent" }}
|
||||
{{ range $posts.ByDate.Reverse | first (or .Site.Params.NumberPostsOnHomePage 4) }}
|
||||
{{- partial "list-posts.html" . -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
23
themes/gokarna/layouts/partials/back-to-top.html
Normal file
@ -0,0 +1,23 @@
|
||||
<svg id="btt-button" class="arrow-logo" xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 384 512" onclick="scrollToTop()" title="Go to top">
|
||||
<!-- Your arrow SVG path or elements go here -->
|
||||
<path d="M177 159.7l136 136c9.4 9.4 9.4 24.6 0 33.9l-22.6 22.6c-9.4 9.4-24.6 9.4-33.9 0L160 255.9l-96.4 96.4c-9.4 9.4-24.6 9.4-33.9 0L7 329.7c-9.4-9.4-9.4-24.6 0-33.9l136-136c9.4-9.5 24.6-9.5 34-.1z"/>
|
||||
</svg>
|
||||
<script>
|
||||
let backToTopButton = document.getElementById("btt-button");
|
||||
|
||||
window.onscroll = function() {
|
||||
scrollFunction()
|
||||
};
|
||||
|
||||
function scrollFunction() {
|
||||
if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) {
|
||||
backToTopButton.style.display = "block";
|
||||
} else {
|
||||
backToTopButton.style.display = "none";
|
||||
}
|
||||
}
|
||||
|
||||
function scrollToTop() {
|
||||
window.scrollTo(0, 0);
|
||||
}
|
||||
</script>
|
||||
|
After Width: | Height: | Size: 896 B |
39
themes/gokarna/layouts/partials/footer.html
Normal file
@ -0,0 +1,39 @@
|
||||
<footer class="footer">
|
||||
<!-- Option for user to inject custom html -->
|
||||
{{ if .Site.Params.CustomFooterHTML }}
|
||||
{{ .Site.Params.CustomFooterHTML | safeHTML }}
|
||||
{{ end }}
|
||||
|
||||
{{ .Scratch.Set "footerText" "" }}
|
||||
|
||||
{{ if (.Site.Params.Footer) }}
|
||||
|
||||
{{ if and (eq .Kind "page") (.Date) }}
|
||||
{{ .Scratch.Add "footerText" (.Date | time.Format "2006") }}
|
||||
{{ else }}
|
||||
{{ .Scratch.Add "footerText" (time.Now | time.Format "2006") }}
|
||||
{{ end }}
|
||||
|
||||
{{ if and (eq .Kind "page") (.Lastmod) (gt (time.Format "2006" .Lastmod) (time.Format "2006" .Date)) }}
|
||||
{{ .Scratch.Add "footerText" "-" }}
|
||||
{{ .Scratch.Add "footerText" (.Lastmod | time.Format "2006") }}
|
||||
{{ end }}
|
||||
|
||||
{{ .Scratch.Add "footerText" " " }}
|
||||
{{ .Scratch.Add "footerText" .Site.Params.Footer }}
|
||||
|
||||
{{ if and (eq .Kind "page") (.Site.Copyright) }}
|
||||
{{ .Scratch.Add "footerText" " " }}
|
||||
{{ .Scratch.Add "footerText" .Site.Copyright }}
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
{{ if (gt (.Scratch.Get "footerText" | len) 0) }}
|
||||
<span>© {{ .Scratch.Get "footerText" | markdownify }}</span>
|
||||
{{ end }}
|
||||
|
||||
<span>
|
||||
Made with ❤️ using <a target="_blank" href="https://github.com/gokarna-theme/gokarna-hugo">Gokarna</a>
|
||||
</span>
|
||||
</footer>
|
||||
60
themes/gokarna/layouts/partials/head.html
Normal file
@ -0,0 +1,60 @@
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<style>
|
||||
:root {
|
||||
--accent-color: {{ .Site.Params.AccentColor | default "#FF4D4D" }};
|
||||
--font-size: {{ .Site.Params.FontSize | default "1.1rem" }};
|
||||
}
|
||||
</style>
|
||||
|
||||
{{ $title := .Title | markdownify | default .Site.Title }}
|
||||
{{ $description := ((.Description | default (.Summary | default .Content) | default .Site.Params.Description) | plainify | truncate 160) }}
|
||||
{{ $image := .Params.image | default (.Scratch.Get "avatarImgSrc") }}
|
||||
{{ $siteKeywords := .Site.Params.MetaKeywords | default (slice) }}
|
||||
{{ $postKeywords := .Params.tags | default (slice) }}
|
||||
{{ $keywords := union $siteKeywords $postKeywords }}
|
||||
|
||||
<!-- SEO titles & descriptions -->
|
||||
<title>{{ $title }}</title>
|
||||
<meta name="description" content="{{ $description }}">
|
||||
<meta name="keywords" content='{{ delimit $keywords ", "}}'>
|
||||
|
||||
<meta property="og:url" content="{{ .Permalink }}">
|
||||
<meta property="og:type" content="website">
|
||||
<meta property="og:title" content="{{ $title }}">
|
||||
<meta property="og:description" content="{{ $description }}">
|
||||
<meta property="og:image" content="{{ absURL $image }}">
|
||||
<meta property="og:image:secure_url" content="{{ absURL $image }}">
|
||||
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:title" content="{{ $title }}">
|
||||
<meta name="twitter:description" content="{{ $description }}">
|
||||
<meta property="twitter:domain" content="{{ .Permalink }}">
|
||||
<meta property="twitter:url" content="{{ .Permalink }}">
|
||||
<meta name="twitter:image" content="{{ absURL $image }}">
|
||||
|
||||
<!-- SEO canonicals: helps Google understand your site better when using marketing campaign tagging etc -->
|
||||
<link rel="canonical" href="{{ .Permalink }}">
|
||||
|
||||
{{ $cssNormalize := resources.Get "css/normalize.min.css" }}
|
||||
<link rel="stylesheet" type="text/css" href="{{ $cssNormalize.RelPermalink }}" media="print">
|
||||
|
||||
{{ $cssMain := resources.Get "css/main.css" | minify }}
|
||||
<link rel="stylesheet" type="text/css" href="{{ $cssMain.RelPermalink }}">
|
||||
|
||||
{{ $cssSyntax := resources.Get "css/syntax.css" | minify }}
|
||||
<link rel="stylesheet" type="text/css" href="{{ $cssSyntax.RelPermalink }}">
|
||||
|
||||
{{ $cssDark := resources.Get "css/dark.css" | minify }}
|
||||
<link id="dark-theme" rel="stylesheet" href="{{ $cssDark.RelPermalink }}">
|
||||
|
||||
{{ $jsBundle := resources.Match "js/**.js" | resources.Concat "js/bundle.js" | minify | resources.Fingerprint "sha256" }}
|
||||
<script src="{{ $jsBundle.RelPermalink }}" integrity="{{ $jsBundle.Data.Integrity }}"></script>
|
||||
|
||||
<!-- Option for user to inject custom html -->
|
||||
{{ if .Site.Params.CustomHeadHTML }}
|
||||
{{ .Site.Params.CustomHeadHTML | safeHTML }}
|
||||
{{ end }}
|
||||
</head>
|
||||
59
themes/gokarna/layouts/partials/header.html
Normal file
@ -0,0 +1,59 @@
|
||||
<header class="header">
|
||||
<nav class="header-nav">
|
||||
|
||||
{{ if isset .Site.Params "avatarurl" }}
|
||||
<div class="avatar">
|
||||
<a href="{{ .Site.BaseURL }}">
|
||||
<img src='{{ .Scratch.Get "avatarImgSrc" }}' alt="{{ .Site.Params.AvatarAltText|default "avatar" }}">
|
||||
</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="nav-title">
|
||||
<a class="nav-brand" href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a>
|
||||
</div>
|
||||
|
||||
<div class="nav-links">
|
||||
{{ range .Site.Menus.main }}
|
||||
<div class="nav-link">
|
||||
<a href="{{ .URL | absURL }}" aria-label="{{ .Identifier }}" {{ if .Params.NewPage -}}target="_blank" {{- end -}}>
|
||||
{{- .Pre | safeHTML }} {{ .Name }} {{ .Post | safeHTML -}}
|
||||
</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<span class="nav-icons-divider"></span>
|
||||
<div class="nav-link dark-theme-toggle">
|
||||
<span class="sr-only dark-theme-toggle-screen-reader-target">theme</span>
|
||||
<a aria-hidden="true" role="switch">
|
||||
<span class="theme-toggle-icon" data-feather="moon"></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="nav-link" id="hamburger-menu-toggle">
|
||||
<span class="sr-only hamburger-menu-toggle-screen-reader-target">menu</span>
|
||||
<a aria-checked="false" aria-labelledby="hamburger-menu-toggle" id="hamburger-menu-toggle-target" role="switch">
|
||||
<span data-feather="menu"></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<!-- For mobile -->
|
||||
<ul class="nav-hamburger-list visibility-hidden">
|
||||
{{ range .Site.Menus.main }}
|
||||
<li class="nav-item">
|
||||
<a href="{{ .URL | absURL }}" {{ if .Params.NewPage -}} target="_blank"{{- end -}}>
|
||||
{{- .Pre | safeHTML }} {{ .Name }} {{ .Post | safeHTML -}}
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
<li class="nav-item dark-theme-toggle">
|
||||
<span class="sr-only dark-theme-toggle-screen-reader-target">theme</span>
|
||||
<a role="switch">
|
||||
<span class="theme-toggle-icon" data-feather="moon"></span>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</nav>
|
||||
</header>
|
||||
16
themes/gokarna/layouts/partials/list-posts.html
Normal file
@ -0,0 +1,16 @@
|
||||
<div class="post-title">
|
||||
<a href="{{ .Permalink }}" class="post-link">{{ .Title | markdownify }}</a>
|
||||
{{/* Decide to display the date based on the tags */}}
|
||||
{{ $displayDate := true }}
|
||||
{{ $tagsHidePostDate := or .Site.Params.Hidden.TagsPostDate slice }}
|
||||
{{ $postTags := or .Params.Tags slice }}
|
||||
|
||||
{{ if gt ($tagsHidePostDate | intersect $postTags | len) 0 }}
|
||||
{{ $displayDate = false }}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq $displayDate true }}
|
||||
<div class="flex-break"></div>
|
||||
<span class="post-date">{{ dateFormat (or .Site.Params.dateFormat "January 2, 2006") .Date}}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
14
themes/gokarna/layouts/partials/list.html
Normal file
@ -0,0 +1,14 @@
|
||||
<div class="container list-posts">
|
||||
|
||||
<h1 class="list-title">{{ i18n .Name }}</h1>
|
||||
|
||||
{{ range (where .Pages "Params.type" "post" ).GroupByDate "2006" }}
|
||||
|
||||
<h2 class="posts-year">{{ .Key }}</h2>
|
||||
|
||||
{{- range .Pages -}}
|
||||
{{- partial "list-posts.html" . -}}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
</div>
|
||||
15
themes/gokarna/layouts/partials/page.html
Normal file
@ -0,0 +1,15 @@
|
||||
<div class="post container">
|
||||
|
||||
<div class="post-header-section">
|
||||
<h1>{{ or (.Params.H1 | markdownify) (.Title | markdownify) }}</h1>
|
||||
</div>
|
||||
|
||||
<div class="post-content">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
<!-- Back to top button -->
|
||||
{{ if .Site.Params.ShowBackToTopButton }}
|
||||
{{ partial "back-to-top.html" . }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
75
themes/gokarna/layouts/partials/post.html
Normal file
@ -0,0 +1,75 @@
|
||||
<div class="post container">
|
||||
<div class="post-header-section">
|
||||
<h1>{{ or (.Params.H1 | markdownify) (.Title | markdownify) }}</h1>
|
||||
|
||||
{{/* Determine whether to display the date & description based on tags */}}
|
||||
|
||||
{{ $displayDate := true }}
|
||||
{{ $displayDescription := true }}
|
||||
{{ $postTags := or .Params.Tags slice }}
|
||||
{{ $hiddenTags := or .Site.Params.Hidden.Tags slice }}
|
||||
{{ $tagsHidePostDate := or .Site.Params.Hidden.TagsPostDate slice }}
|
||||
{{ $tagsHidePostDescription := or .Site.Params.Hidden.TagsPostDescription slice }}
|
||||
|
||||
{{ if gt ($tagsHidePostDate | intersect $postTags | len) 0 }}
|
||||
{{ $displayDate = false }}
|
||||
{{ end }}
|
||||
|
||||
{{ if gt ($tagsHidePostDescription | intersect $postTags | len) 0 }}
|
||||
{{ $displayDescription = false }}
|
||||
{{ end }}
|
||||
|
||||
{{ if $displayDescription }}
|
||||
<small role="doc-subtitle">{{ .Description }}</small>
|
||||
{{ end }}
|
||||
|
||||
{{ if $displayDate }}
|
||||
<p class="post-date">
|
||||
{{ if (eq .Site.Params.DisplayReadingTime true) }}
|
||||
{{ .ReadingTime }} min read |
|
||||
{{ end }}
|
||||
|
||||
{{ dateFormat (or .Site.Params.dateFormat "January 2, 2006") .Date }}
|
||||
|
||||
{{ if lt .Date .Lastmod }}
|
||||
| Updated {{ dateFormat (or .Site.Params.dateFormat "January 2, 2006") .Lastmod }}
|
||||
{{ end }}
|
||||
</p>
|
||||
{{ end }}
|
||||
|
||||
<ul class="post-tags">
|
||||
{{ range $tag := $postTags }}
|
||||
{{ if not (in $hiddenTags $tag) }}
|
||||
<li class="post-tag"><a href="{{ "tags/" | absLangURL }}{{ . | urlize }}">{{ . }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="post-content">
|
||||
{{ .Content }}
|
||||
{{ if .Site.Config.Services.Disqus.Shortname }}
|
||||
<div class="post-comments">
|
||||
{{ template "_internal/disqus.html" . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<div class="prev-next">
|
||||
{{ if (eq .Site.Params.TogglePreviousAndNextButtons true) }}
|
||||
{{ if or .PrevInSection .NextInSection }}
|
||||
{{ partial "prev-next.html" . }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<!-- Back to top button -->
|
||||
{{ if .Site.Params.ShowBackToTopButton }}
|
||||
{{ partial "back-to-top.html" . }}
|
||||
{{ end }}
|
||||
{{ if .Site.Params.CustomCommentHTML }}
|
||||
<div id="comments">
|
||||
{{ .Site.Params.CustomCommentHTML | safeHTML }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
31
themes/gokarna/layouts/partials/prev-next.html
Normal file
@ -0,0 +1,31 @@
|
||||
<nav aria-label="Post navigation" class="post-navigation">
|
||||
{{ with .PrevInSection }}
|
||||
<div class="prev-post">
|
||||
<p>
|
||||
<a href="{{ .RelPermalink }}">
|
||||
←
|
||||
{{ i18n "previous" }}:
|
||||
{{ .Title | markdownify }}
|
||||
</a>
|
||||
</p>
|
||||
<p class="prev-post-date">
|
||||
{{ dateFormat (or .Site.Params.dateFormat "January 2, 2006") .Date}}
|
||||
</p>
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
{{ with .NextInSection }}
|
||||
<div class="next-post">
|
||||
<p>
|
||||
<a href="{{ .RelPermalink }}">
|
||||
{{ i18n "next" }}:
|
||||
{{ .Title | markdownify }}
|
||||
→
|
||||
</a>
|
||||
</p>
|
||||
<p class="next-post-date">
|
||||
{{ dateFormat (or .Site.Params.dateFormat "January 2, 2006") .Date}}
|
||||
</p>
|
||||
</div>
|
||||
{{ end }}
|
||||
</nav>
|
||||
7
themes/gokarna/layouts/partials/toc.html
Normal file
@ -0,0 +1,7 @@
|
||||
{{ if .Params.ShowTableOfContents }}
|
||||
<aside class="post-toc">
|
||||
<nav id="toc">
|
||||
{{ .TableOfContents }}
|
||||
</nav>
|
||||
</aside>
|
||||
{{ end }}
|
||||
1
themes/gokarna/layouts/shortcodes/br.html
Normal file
@ -0,0 +1 @@
|
||||
<br>
|
||||
4
themes/gokarna/netlify.toml
Normal file
@ -0,0 +1,4 @@
|
||||
[build.environment]
|
||||
GO_VERSION = "1.24.2"
|
||||
HUGO_VERSION = "0.147.1"
|
||||
NODE_VERSION = "22"
|
||||
3
themes/gokarna/requirements.txt
Normal file
@ -0,0 +1,3 @@
|
||||
selenium==4.10.0
|
||||
pillow
|
||||
soldier
|
||||
104
themes/gokarna/screenshot.py
Normal file
@ -0,0 +1,104 @@
|
||||
"""
|
||||
Open firefox in headless mode and take screenshots of
|
||||
all the pages in both light and dark mode
|
||||
|
||||
Setup:
|
||||
pip install selenium==4.10.0 pillow soldier
|
||||
Add geckodriver to $PATH. Link: https://github.com/mozilla/geckodriver/releases
|
||||
"""
|
||||
|
||||
from selenium import webdriver
|
||||
from selenium.webdriver.firefox.service import Service
|
||||
from selenium.webdriver.firefox.options import Options
|
||||
from selenium.webdriver.common.by import By
|
||||
from PIL import Image
|
||||
import os
|
||||
import soldier
|
||||
|
||||
SCREENSHOT_OPTIONS = [
|
||||
{'path': '/', 'filename': 'images/screenshot-{color_pref}-home.png'},
|
||||
{'path': '/posts/', 'filename': 'images/screenshot-{color_pref}-list.png'},
|
||||
{'path': '/posts/theme-documentation-basics/', 'filename': 'images/screenshot-{color_pref}-post.png'},
|
||||
]
|
||||
|
||||
DARK_THEME = (34, 39, 45, 255)
|
||||
LIGHT_THEME = (255, 255, 255, 255)
|
||||
|
||||
def get_dominant_color(img_path):
|
||||
pil_img = Image.open(img_path)
|
||||
img = pil_img.copy()
|
||||
img.convert("RGB")
|
||||
img.resize((1, 1), resample=0)
|
||||
dominant_color = img.getpixel((0, 0))
|
||||
return dominant_color
|
||||
|
||||
def take_screenshots(driver, base_url, screenshot_options):
|
||||
for opt in screenshot_options:
|
||||
driver.get(base_url + opt['path'])
|
||||
color_a_filename = opt['filename'].format(color_pref='color-a')
|
||||
color_b_filename = opt['filename'].format(color_pref='color-b')
|
||||
|
||||
driver.save_screenshot(color_a_filename)
|
||||
|
||||
# Change theme by clicking the theme toggle button
|
||||
for elem in driver.find_elements(By.CLASS_NAME, 'dark-theme-toggle'):
|
||||
# Hidden hamburger menu for mobile raises Exception on clicking
|
||||
if elem.is_displayed():
|
||||
elem.click()
|
||||
|
||||
driver.save_screenshot(color_b_filename)
|
||||
|
||||
for f in (color_a_filename, color_b_filename):
|
||||
if get_dominant_color(f) == LIGHT_THEME:
|
||||
os.rename(f, opt['filename'].format(color_pref='light'))
|
||||
elif get_dominant_color(f) == DARK_THEME:
|
||||
os.rename(f, opt['filename'].format(color_pref='dark'))
|
||||
else:
|
||||
raise Exception('Image does not match theme')
|
||||
|
||||
print(f'Saved {opt["path"]}')
|
||||
|
||||
def merge_home_images():
|
||||
light_home = Image.open('images/screenshot-light-home.png')
|
||||
dark_home = Image.open('images/screenshot-dark-home.png')
|
||||
if light_home.size != dark_home.size:
|
||||
raise Exception('Image sizes should be same')
|
||||
|
||||
width, height = light_home.size
|
||||
|
||||
light_home_half = light_home.crop((0, 0, int(width/2), height))
|
||||
dark_home_half = dark_home.crop((int(width/2), 0, width, height))
|
||||
|
||||
merged_img = Image.new('RGB', (width, height))
|
||||
# Since we are merging horizontally, we will keep the offset of x-axis
|
||||
x_offset = 0
|
||||
for img in (light_home_half, dark_home_half):
|
||||
merged_img.paste(img, (x_offset, 0))
|
||||
x_offset += img.size[0]
|
||||
|
||||
merged_img.save('images/screenshot.png')
|
||||
merged_img.save('images/tn.png')
|
||||
print('Created merged image for hugo showcase')
|
||||
|
||||
def main():
|
||||
server_process = soldier.run('hugo --source="exampleSite/" server', background=True, shell=True)
|
||||
|
||||
service = Service()
|
||||
options = Options()
|
||||
options.add_argument('--headless')
|
||||
if os.getenv('FIREFOX_PATH'):
|
||||
options.binary_location = os.getenv('FIREFOX_PATH')
|
||||
|
||||
driver = webdriver.Firefox(service=service, options=options)
|
||||
# To offset screen size based on window size
|
||||
driver.set_window_size(1500, 1085)
|
||||
|
||||
base_url = 'http://127.0.0.1:1313'
|
||||
take_screenshots(driver, base_url, SCREENSHOT_OPTIONS)
|
||||
merge_home_images()
|
||||
|
||||
driver.quit()
|
||||
server_process.kill(with_honor=False)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
BIN
themes/gokarna/static/fonts/Lato-Bold.ttf
Normal file
BIN
themes/gokarna/static/fonts/Lato-Regular.ttf
Normal file
1
themes/gokarna/static/svg/icons/angellist.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>AngelList</title><path d="M16.467 9.956c.736-2 1.31-3.651 1.723-4.953.412-1.302.618-2.102.618-2.399 0-.318-.069-.565-.206-.741a.683.683 0 0 0-.569-.264c-.308 0-.62.255-.94.766-.318.511-.67 1.333-1.055 2.465L14.39 9.593zm-2.192 4.434c-.473-.022-.92-.071-1.344-.148a7.126 7.126 0 0 1-1.211-.33c.175.352.332.703.47 1.055.137.352.25.698.337 1.039.264-.33.542-.63.833-.899a6.93 6.93 0 0 1 .915-.717zm-1.863-4.994l-1.78-5.143C10.17 2.945 9.813 2.09 9.56 1.69c-.253-.402-.527-.602-.824-.602a.688.688 0 0 0-.56.264c-.143.175-.215.412-.215.708 0 .506.193 1.385.577 2.638.385 1.253.962 2.895 1.731 4.928a.55.55 0 0 1 .28-.255 1.33 1.33 0 0 1 .495-.074c.066 0 .198.005.396.016.197.011.521.039.972.083zm-1.615 7.961c.186 0 .357-.085.51-.255a.81.81 0 0 0 .231-.552c0-.209-.15-.695-.453-1.46a14.623 14.623 0 0 0-1.129-2.25c-.33-.549-.654-.963-.973-1.244-.318-.28-.62-.42-.906-.42-.23 0-.486.146-.767.437-.28.291-.42.563-.42.816 0 .263.137.66.412 1.187.275.527.643 1.087 1.105 1.68.483.65.94 1.155 1.368 1.517.428.363.769.544 1.022.544zm-4.945-.395c.153.187.368.461.642.824.726 1 1.396 1.5 2.011 1.5a.874.874 0 0 0 .56-.198c.166-.132.248-.27.248-.412 0-.165-.11-.44-.33-.824-.22-.385-.522-.819-.906-1.302-.44-.56-.805-.97-1.096-1.228-.291-.258-.525-.388-.7-.388-.386 0-.74.206-1.064.618-.324.412-.486.899-.486 1.46 0 .45.112.953.338 1.507.225.555.552 1.113.98 1.673a6.543 6.543 0 0 0 2.415 2.003c.962.467 2.025.7 3.19.7 2.143 0 3.937-.799 5.382-2.398 1.445-1.599 2.167-3.601 2.167-6.008 0-.736-.055-1.321-.165-1.755-.11-.434-.29-.75-.544-.948-.45-.374-1.326-.709-2.629-1.006a18.315 18.315 0 0 0-4.08-.445c-.395 0-.675.066-.84.198-.165.132-.247.357-.247.676 0 .747.417 1.288 1.253 1.623.834.336 2.186.503 4.055.503h.675c.154 0 .278.058.371.173.093.116.157.289.19.52-.187.175-.572.376-1.154.601-.583.225-1.028.448-1.335.668a5.92 5.92 0 0 0-1.59 1.722c-.402.665-.603 1.294-.603 1.888 0 .362.085.8.256 1.31.17.511.255.827.255.948v.115l-.033.149c-.483-.033-.865-.316-1.145-.85-.28-.532-.42-1.244-.42-2.134v-.148a.912.912 0 0 1-.256.165.726.726 0 0 1-.272.05c-.099 0-.192-.009-.28-.026a2.869 2.869 0 0 1-.297-.074 2.917 2.917 0 0 1 .099.627c0 .406-.16.755-.478 1.046a1.63 1.63 0 0 1-1.137.437c-.693 0-1.396-.338-2.11-1.014-.715-.675-1.072-1.337-1.072-1.986 0-.12.014-.228.041-.321a.552.552 0 0 1 .14-.24zm11.802-6.726c.989.187 1.687.605 2.093 1.253.407.649.61 1.67.61 3.066 0 2.77-.832 5.036-2.497 6.8C16.195 23.118 14.066 24 11.473 24a8.254 8.254 0 0 1-2.976-.552 7.368 7.368 0 0 1-2.48-1.541c-.792-.726-1.385-1.492-1.78-2.3a5.58 5.58 0 0 1-.594-2.48c0-.946.203-1.676.61-2.193.406-.516 1.049-.868 1.928-1.055a8.824 8.824 0 0 1-.362-.972c-.077-.264-.116-.467-.116-.61 0-.495.261-1 .783-1.517.522-.516 1.014-.774 1.475-.774.198 0 .407.035.627.107.22.071.472.19.758.354C8.5 8.071 7.885 6.223 7.5 4.92c-.385-1.302-.577-2.2-.577-2.695 0-.681.176-1.222.528-1.623C7.802.2 8.28 0 8.885 0c1.032 0 2.34 2.308 3.923 6.923.274.791.483 1.401.626 1.83l.511-1.45C15.527 2.73 16.89.444 18.033.444c.56 0 1.008.19 1.343.569.336.379.503.887.503 1.524 0 .484-.184 1.369-.552 2.654-.368 1.286-.926 2.967-1.673 5.044"/></svg>
|
||||
|
After Width: | Height: | Size: 3.1 KiB |
1
themes/gokarna/static/svg/icons/buymeacoffee.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Buy Me A Coffee</title><path d="M20.216 6.415l-.132-.666c-.119-.598-.388-1.163-1.001-1.379-.197-.069-.42-.098-.57-.241-.152-.143-.196-.366-.231-.572-.065-.378-.125-.756-.192-1.133-.057-.325-.102-.69-.25-.987-.195-.4-.597-.634-.996-.788a5.723 5.723 0 00-.626-.194c-1-.263-2.05-.36-3.077-.416a25.834 25.834 0 00-3.7.062c-.915.083-1.88.184-2.75.5-.318.116-.646.256-.888.501-.297.302-.393.77-.177 1.146.154.267.415.456.692.58.36.162.737.284 1.123.366 1.075.238 2.189.331 3.287.37 1.218.05 2.437.01 3.65-.118.299-.033.598-.073.896-.119.352-.054.578-.513.474-.834-.124-.383-.457-.531-.834-.473-.466.074-.96.108-1.382.146-1.177.08-2.358.082-3.536.006a22.228 22.228 0 01-1.157-.107c-.086-.01-.18-.025-.258-.036-.243-.036-.484-.08-.724-.13-.111-.027-.111-.185 0-.212h.005c.277-.06.557-.108.838-.147h.002c.131-.009.263-.032.394-.048a25.076 25.076 0 013.426-.12c.674.019 1.347.067 2.017.144l.228.031c.267.04.533.088.798.145.392.085.895.113 1.07.542.055.137.08.288.111.431l.319 1.484a.237.237 0 01-.199.284h-.003c-.037.006-.075.01-.112.015a36.704 36.704 0 01-4.743.295 37.059 37.059 0 01-4.699-.304c-.14-.017-.293-.042-.417-.06-.326-.048-.649-.108-.973-.161-.393-.065-.768-.032-1.123.161-.29.16-.527.404-.675.701-.154.316-.199.66-.267 1-.069.34-.176.707-.135 1.056.087.753.613 1.365 1.37 1.502a39.69 39.69 0 0011.343.376.483.483 0 01.535.53l-.071.697-1.018 9.907c-.041.41-.047.832-.125 1.237-.122.637-.553 1.028-1.182 1.171-.577.131-1.165.2-1.756.205-.656.004-1.31-.025-1.966-.022-.699.004-1.556-.06-2.095-.58-.475-.458-.54-1.174-.605-1.793l-.731-7.013-.322-3.094c-.037-.351-.286-.695-.678-.678-.336.015-.718.3-.678.679l.228 2.185.949 9.112c.147 1.344 1.174 2.068 2.446 2.272.742.12 1.503.144 2.257.156.966.016 1.942.053 2.892-.122 1.408-.258 2.465-1.198 2.616-2.657.34-3.332.683-6.663 1.024-9.995l.215-2.087a.484.484 0 01.39-.426c.402-.078.787-.212 1.074-.518.455-.488.546-1.124.385-1.766zm-1.478.772c-.145.137-.363.201-.578.233-2.416.359-4.866.54-7.308.46-1.748-.06-3.477-.254-5.207-.498-.17-.024-.353-.055-.47-.18-.22-.236-.111-.71-.054-.995.052-.26.152-.609.463-.646.484-.057 1.046.148 1.526.22.577.088 1.156.159 1.737.212 2.48.226 5.002.19 7.472-.14.45-.06.899-.13 1.345-.21.399-.072.84-.206 1.08.206.166.281.188.657.162.974a.544.544 0 01-.169.364zm-6.159 3.9c-.862.37-1.84.788-3.109.788a5.884 5.884 0 01-1.569-.217l.877 9.004c.065.78.717 1.38 1.5 1.38 0 0 1.243.065 1.658.065.447 0 1.786-.065 1.786-.065.783 0 1.434-.6 1.499-1.38l.94-9.95a3.996 3.996 0 00-1.322-.238c-.826 0-1.491.284-2.26.613z"/></svg>
|
||||
|
After Width: | Height: | Size: 2.5 KiB |
1
themes/gokarna/static/svg/icons/discord.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><title>Discord</title><path d="M13.545 2.907a13.227 13.227 0 0 0-3.257-1.011.05.05 0 0 0-.052.025c-.141.25-.297.577-.406.833a12.19 12.19 0 0 0-3.658 0 8.258 8.258 0 0 0-.412-.833.051.051 0 0 0-.052-.025c-1.125.194-2.22.534-3.257 1.011a.041.041 0 0 0-.021.018C.356 6.024-.213 9.047.066 12.032c.001.014.01.028.021.037a13.276 13.276 0 0 0 3.995 2.02.05.05 0 0 0 .056-.019c.308-.42.582-.863.818-1.329a.05.05 0 0 0-.01-.059.051.051 0 0 0-.018-.011 8.875 8.875 0 0 1-1.248-.595.05.05 0 0 1-.02-.066.051.051 0 0 1 .015-.019c.084-.063.168-.129.248-.195a.05.05 0 0 1 .051-.007c2.619 1.196 5.454 1.196 8.041 0a.052.052 0 0 1 .053.007c.08.066.164.132.248.195a.051.051 0 0 1-.004.085 8.254 8.254 0 0 1-1.249.594.05.05 0 0 0-.03.03.052.052 0 0 0 .003.041c.24.465.515.909.817 1.329a.05.05 0 0 0 .056.019 13.235 13.235 0 0 0 4.001-2.02.049.049 0 0 0 .021-.037c.334-3.451-.559-6.449-2.366-9.106a.034.034 0 0 0-.02-.019Zm-8.198 7.307c-.789 0-1.438-.724-1.438-1.612 0-.889.637-1.613 1.438-1.613.807 0 1.45.73 1.438 1.613 0 .888-.637 1.612-1.438 1.612Zm5.316 0c-.788 0-1.438-.724-1.438-1.612 0-.889.637-1.613 1.438-1.613.807 0 1.451.73 1.438 1.613 0 .888-.631 1.612-1.438 1.612Z"/></svg>
|
||||
|
After Width: | Height: | Size: 1.2 KiB |
1
themes/gokarna/static/svg/icons/dribbble.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Dribbble</title><path d="M12 24C5.385 24 0 18.615 0 12S5.385 0 12 0s12 5.385 12 12-5.385 12-12 12zm10.12-10.358c-.35-.11-3.17-.953-6.384-.438 1.34 3.684 1.887 6.684 1.992 7.308 2.3-1.555 3.936-4.02 4.395-6.87zm-6.115 7.808c-.153-.9-.75-4.032-2.19-7.77l-.066.02c-5.79 2.015-7.86 6.025-8.04 6.4 1.73 1.358 3.92 2.166 6.29 2.166 1.42 0 2.77-.29 4-.814zm-11.62-2.58c.232-.4 3.045-5.055 8.332-6.765.135-.045.27-.084.405-.12-.26-.585-.54-1.167-.832-1.74C7.17 11.775 2.206 11.71 1.756 11.7l-.004.312c0 2.633.998 5.037 2.634 6.855zm-2.42-8.955c.46.008 4.683.026 9.477-1.248-1.698-3.018-3.53-5.558-3.8-5.928-2.868 1.35-5.01 3.99-5.676 7.17zM9.6 2.052c.282.38 2.145 2.914 3.822 6 3.645-1.365 5.19-3.44 5.373-3.702-1.81-1.61-4.19-2.586-6.795-2.586-.825 0-1.63.1-2.4.285zm10.335 3.483c-.218.29-1.935 2.493-5.724 4.04.24.49.47.985.68 1.486.08.18.15.36.22.53 3.41-.43 6.8.26 7.14.33-.02-2.42-.88-4.64-2.31-6.38z"/></svg>
|
||||
|
After Width: | Height: | Size: 984 B |
1
themes/gokarna/static/svg/icons/email.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg viewBox="0 0 128 128" xmlns="http://www.w3.org/2000/svg"><path d="M 0,27.283 V 24 a 8,8 0 0 1 8,-8 h 112 a 8,8 0 0 1 8,8 v 3.283 l -64,40 z m 66.12,48.11 a 4.004,4.004 0 0 1 -4.24,0 L 0,36.717 V 104 a 8,8 0 0 0 8,8 h 112 a 8,8 0 0 0 8,-8 V 36.717 Z" data-name="Layer 2"/></svg>
|
||||
|
After Width: | Height: | Size: 282 B |
1
themes/gokarna/static/svg/icons/facebook.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Facebook</title><path d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/></svg>
|
||||
|
After Width: | Height: | Size: 398 B |
1
themes/gokarna/static/svg/icons/github.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg>
|
||||
|
After Width: | Height: | Size: 822 B |
1
themes/gokarna/static/svg/icons/gmail.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Gmail</title><path d="M24 5.457v13.909c0 .904-.732 1.636-1.636 1.636h-3.819V11.73L12 16.64l-6.545-4.91v9.273H1.636A1.636 1.636 0 0 1 0 19.366V5.457c0-2.023 2.309-3.178 3.927-1.964L5.455 4.64 12 9.548l6.545-4.91 1.528-1.145C21.69 2.28 24 3.434 24 5.457z"/></svg>
|
||||
|
After Width: | Height: | Size: 339 B |
1
themes/gokarna/static/svg/icons/google.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Google</title><path d="M12.48 10.92v3.28h7.84c-.24 1.84-.853 3.187-1.787 4.133-1.147 1.147-2.933 2.4-6.053 2.4-4.827 0-8.6-3.893-8.6-8.72s3.773-8.72 8.6-8.72c2.6 0 4.507 1.027 5.907 2.347l2.307-2.307C18.747 1.44 16.133 0 12.48 0 5.867 0 .307 5.387.307 12s5.56 12 12.173 12c3.573 0 6.267-1.173 8.373-3.36 2.16-2.16 2.84-5.213 2.84-7.667 0-.76-.053-1.467-.173-2.053H12.48z"/></svg>
|
||||
|
After Width: | Height: | Size: 457 B |
1
themes/gokarna/static/svg/icons/instagram.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Instagram</title><path d="M12 0C8.74 0 8.333.015 7.053.072 5.775.132 4.905.333 4.14.63c-.789.306-1.459.717-2.126 1.384S.935 3.35.63 4.14C.333 4.905.131 5.775.072 7.053.012 8.333 0 8.74 0 12s.015 3.667.072 4.947c.06 1.277.261 2.148.558 2.913.306.788.717 1.459 1.384 2.126.667.666 1.336 1.079 2.126 1.384.766.296 1.636.499 2.913.558C8.333 23.988 8.74 24 12 24s3.667-.015 4.947-.072c1.277-.06 2.148-.262 2.913-.558.788-.306 1.459-.718 2.126-1.384.666-.667 1.079-1.335 1.384-2.126.296-.765.499-1.636.558-2.913.06-1.28.072-1.687.072-4.947s-.015-3.667-.072-4.947c-.06-1.277-.262-2.149-.558-2.913-.306-.789-.718-1.459-1.384-2.126C21.319 1.347 20.651.935 19.86.63c-.765-.297-1.636-.499-2.913-.558C15.667.012 15.26 0 12 0zm0 2.16c3.203 0 3.585.016 4.85.071 1.17.055 1.805.249 2.227.415.562.217.96.477 1.382.896.419.42.679.819.896 1.381.164.422.36 1.057.413 2.227.057 1.266.07 1.646.07 4.85s-.015 3.585-.074 4.85c-.061 1.17-.256 1.805-.421 2.227-.224.562-.479.96-.899 1.382-.419.419-.824.679-1.38.896-.42.164-1.065.36-2.235.413-1.274.057-1.649.07-4.859.07-3.211 0-3.586-.015-4.859-.074-1.171-.061-1.816-.256-2.236-.421-.569-.224-.96-.479-1.379-.899-.421-.419-.69-.824-.9-1.38-.165-.42-.359-1.065-.42-2.235-.045-1.26-.061-1.649-.061-4.844 0-3.196.016-3.586.061-4.861.061-1.17.255-1.814.42-2.234.21-.57.479-.96.9-1.381.419-.419.81-.689 1.379-.898.42-.166 1.051-.361 2.221-.421 1.275-.045 1.65-.06 4.859-.06l.045.03zm0 3.678c-3.405 0-6.162 2.76-6.162 6.162 0 3.405 2.76 6.162 6.162 6.162 3.405 0 6.162-2.76 6.162-6.162 0-3.405-2.76-6.162-6.162-6.162zM12 16c-2.21 0-4-1.79-4-4s1.79-4 4-4 4 1.79 4 4-1.79 4-4 4zm7.846-10.405c0 .795-.646 1.44-1.44 1.44-.795 0-1.44-.646-1.44-1.44 0-.794.646-1.439 1.44-1.439.793-.001 1.44.645 1.44 1.439z"/></svg>
|
||||
|
After Width: | Height: | Size: 1.8 KiB |
1
themes/gokarna/static/svg/icons/iota.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 50 50" width="24px" height="24px"><path d="M28.5 19A1.5 1.5 0 1 0 28.5 22 1.5 1.5 0 1 0 28.5 19zM29.75 15.5A1.25 1.25 0 1 0 29.75 18 1.25 1.25 0 1 0 29.75 15.5zM24.5 18A1.5 1.5 0 1 0 24.5 21 1.5 1.5 0 1 0 24.5 18zM26.5 13.125A1.375 1.375 0 1 0 26.5 15.875 1.375 1.375 0 1 0 26.5 13.125zM22.5 12A1.5 1.5 0 1 0 22.5 15 1.5 1.5 0 1 0 22.5 12zM22 7A1.5 1.5 0 1 0 22 10 1.5 1.5 0 1 0 22 7zM26 8A1.5 1.5 0 1 0 26 11 1.5 1.5 0 1 0 26 8zM29 10A1 1 0 1 0 29 12 1 1 0 1 0 29 10zM31 12A1 1 0 1 0 31 14 1 1 0 1 0 31 12zM20 17.5A1.75 1.75 0 1 0 20 21 1.75 1.75 0 1 0 20 17.5zM18 11.5A1.75 1.75 0 1 0 18 15 1.75 1.75 0 1 0 18 11.5zM17.25 6.5A1.75 1.75 0 1 0 17.25 10 1.75 1.75 0 1 0 17.25 6.5zM15 18A2 2 0 1 0 15 22 2 2 0 1 0 15 18zM13 12A2 2 0 1 0 13 16 2 2 0 1 0 13 12zM12 7A2 2 0 1 0 12 11 2 2 0 1 0 12 7zM9.5 20A2.5 2.5 0 1 0 9.5 25 2.5 2.5 0 1 0 9.5 20zM7.5 14A2.5 2.5 0 1 0 7.5 19 2.5 2.5 0 1 0 7.5 14zM3 24c-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3S4.657 24 3 24L3 24zM21.12 23.813A1.5 1.5 0 1 0 21.12 26.813 1.5 1.5 0 1 0 21.12 23.813zM17.248 24.856A1.25 1.25 0 1 0 17.248 27.356 1.25 1.25 0 1 0 17.248 24.856zM22.254 27.777A1.5 1.5 0 1 0 22.254 30.777 1.5 1.5 0 1 0 22.254 27.777zM16.924 28.67A1.375 1.375 0 1 0 16.924 31.42 1.375 1.375 0 1 0 16.924 28.67zM18.058 32.509A1.5 1.5 0 1 0 18.058 35.509 1.5 1.5 0 1 0 18.058 32.509zM13.978 35.442A1.5 1.5 0 1 0 13.978 38.442 1.5 1.5 0 1 0 13.978 35.442zM12.844 31.478A1.5 1.5 0 1 0 12.844 34.478 1.5 1.5 0 1 0 12.844 31.478zM12.643 28.63A1 1 0 1 0 12.643 30.63 1 1 0 1 0 12.643 28.63zM13.375 25.898A1 1 0 1 0 13.375 27.898 1 1 0 1 0 13.375 25.898zM24.288 31.549A1.75 1.75 0 1 0 24.288 35.049 1.75 1.75 0 1 0 24.288 31.549zM20.092 36.281A1.75 1.75 0 1 0 20.092 39.781 1.75 1.75 0 1 0 20.092 36.281zM16.137 39.431A1.75 1.75 0 1 0 16.137 42.931 1.75 1.75 0 1 0 16.137 39.431zM27.437 35.254A2 2 0 1 0 27.437 39.254 2 2 0 1 0 27.437 35.254zM23.241 39.986A2 2 0 1 0 23.241 43.986 2 2 0 1 0 23.241 39.986zM19.411 43.352A2 2 0 1 0 19.411 47.352 2 2 0 1 0 19.411 43.352zM32.352 38.268A2.5 2.5 0 1 0 32.352 43.268 2.5 2.5 0 1 0 32.352 38.268zM28.156 43A2.5 2.5 0 1 0 28.156 48 2.5 2.5 0 1 0 28.156 43zM38.997 40.28c-.509 0-1.025.13-1.497.402-1.435.828-1.927 2.663-1.098 4.098.556.962 1.564 1.5 2.601 1.5.509 0 1.025-.13 1.497-.402 1.435-.828 1.927-2.663 1.098-4.098C41.042 40.818 40.034 40.28 38.997 40.28L38.997 40.28zM28.79 27.96A1.5 1.5 0 1 0 28.79 30.96 1.5 1.5 0 1 0 28.79 27.96zM31.413 31.167A1.25 1.25 0 1 0 31.413 33.667 1.25 1.25 0 1 0 31.413 31.167zM31.656 24.996A1.5 1.5 0 1 0 31.656 27.996 1.5 1.5 0 1 0 31.656 24.996zM34.987 29.353A1.375 1.375 0 1 0 34.987 32.103 1.375 1.375 0 1 0 34.987 29.353zM37.853 26.264A1.5 1.5 0 1 0 37.853 29.264 1.5 1.5 0 1 0 37.853 26.264zM42.433 28.331A1.5 1.5 0 1 0 42.433 31.331 1.5 1.5 0 1 0 42.433 28.331zM39.567 31.295A1.5 1.5 0 1 0 39.567 34.295 1.5 1.5 0 1 0 39.567 31.295zM36.768 33.643A1 1 0 1 0 36.768 35.643 1 1 0 1 0 36.768 33.643zM34.036 34.375A1 1 0 1 0 34.036 36.375 1 1 0 1 0 34.036 34.375zM34.123 20.974A1.75 1.75 0 1 0 34.123 24.474 1.75 1.75 0 1 0 34.123 20.974zM40.319 22.242A1.75 1.75 0 1 0 40.319 25.742 1.75 1.75 0 1 0 40.319 22.242zM45.024 24.092A1.75 1.75 0 1 0 45.024 27.592 1.75 1.75 0 1 0 45.024 24.092zM35.973 16.018A2 2 0 1 0 35.973 20.018 2 2 0 1 0 35.973 16.018zM42.17 17.286A2 2 0 1 0 42.17 21.286 2 2 0 1 0 42.17 17.286zM47 18.92A2 2 0 1 0 47 22.92 2 2 0 1 0 47 18.92zM36.558 9.505A2.5 2.5 0 1 0 36.558 14.505 2.5 2.5 0 1 0 36.558 9.505zM42.754 10.773A2.5 2.5 0 1 0 42.754 15.773 2.5 2.5 0 1 0 42.754 10.773zM34.414 1.992c-1.037 0-2.045.538-2.601 1.5-.828 1.435-.337 3.27 1.098 4.098.472.273.988.402 1.497.402 1.037 0 2.045-.538 2.601-1.5.828-1.435.337-3.27-1.098-4.098C35.439 2.121 34.923 1.992 34.414 1.992L34.414 1.992z"/></svg>
|
||||
|
After Width: | Height: | Size: 3.7 KiB |