mirror of
https://github.com/thomasjsn/hugo-theme-hello-friend.git
synced 2024-11-24 16:55:07 +01:00
Merge branch 'PR-rss' of https://github.com/aormsby/FORKED-hugo-theme-hello-friend into PR-rss
This commit is contained in:
commit
0aad509a70
38
README.md
38
README.md
@ -10,22 +10,24 @@ This theme is pretty basic and covers all of the essentials. All you have to do
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
- [Features](#features)
|
- [Hello Friend](#hello-friend)
|
||||||
- [Built-in shortcodes](#built-in-shortcodes)
|
- [DEMO - https://hugo-hello-friend.now.sh/](#demo---httpshugo-hello-friendnowsh)
|
||||||
- [Code highlighting](#code-highlighting)
|
- [Features](#features)
|
||||||
- [Improved RSS Feed](#improved-rss-feed)
|
- [Built-in shortcodes](#built-in-shortcodes)
|
||||||
- [How to start](#how-to-start)
|
- [Code highlighting](#code-highlighting)
|
||||||
- [How to configure](#how-to-configure)
|
- [Improved RSS Feed](#improved-rss-feed)
|
||||||
- [How to add a cover image to your posts](#how-to-add-a-cover-image-to-your-posts)
|
- [How to start](#how-to-start)
|
||||||
- [How to display the Last Modified Date in your posts](#how-to-display-the-last-modified-date-in-your-posts)
|
- [How to configure](#how-to-configure)
|
||||||
- [How to hide "Read more" button](#how-to-hide-read-more-button)
|
- [How to add a cover image to your posts](#how-to-add-a-cover-image-to-your-posts)
|
||||||
- [Add-ons](#add-ons)
|
- [How to display the Last Modified Date in your posts](#how-to-display-the-last-modified-date-in-your-posts)
|
||||||
- [How to run your site](#how-to-run-your-site)
|
- [How to hide "Read more" button](#how-to-hide-read-more-button)
|
||||||
- [How to edit the theme](#how-to-edit-the-theme)
|
- [Add-ons](#add-ons)
|
||||||
- [How to contribute](#how-to-contribute)
|
- [How to run your site](#how-to-run-your-site)
|
||||||
- [`Hello Friend` theme user?](#hello-friend-theme-user)
|
- [How to edit the theme](#how-to-edit-the-theme)
|
||||||
- [Sponsoring](#sponsoring)
|
- [How to contribute](#how-to-contribute)
|
||||||
- [License](#license)
|
- [`Hello Friend` theme user?](#hello-friend-theme-user)
|
||||||
|
- [Sponsoring](#sponsoring)
|
||||||
|
- [License](#license)
|
||||||
|
|
||||||
## Features
|
## Features
|
||||||
|
|
||||||
@ -40,7 +42,9 @@ This theme is pretty basic and covers all of the essentials. All you have to do
|
|||||||
- eg: `{{< image src="/img/hello.png" alt="Hello Friend" position="center" style="border-radius: 8px;" >}}`
|
- eg: `{{< image src="/img/hello.png" alt="Hello Friend" position="center" style="border-radius: 8px;" >}}`
|
||||||
- **`figure`** (same as `image`, plus few optional props: **`caption`**, **`captionPosition`** (left | **center** is default | right), **`captionStyle`**
|
- **`figure`** (same as `image`, plus few optional props: **`caption`**, **`captionPosition`** (left | **center** is default | right), **`captionStyle`**
|
||||||
- eg: `{{< figure src="/img/hello.png" alt="Hello Friend" position="center" style="border-radius: 8px;" caption="Hello Friend!" captionPosition="right" captionStyle="color: red;" >}}`
|
- eg: `{{< figure src="/img/hello.png" alt="Hello Friend" position="center" style="border-radius: 8px;" caption="Hello Friend!" captionPosition="right" captionStyle="color: red;" >}}`
|
||||||
- **`imgproc`** Hugo shortcode for image processing. More info at [https://gohugo.io/content-management/image-processing/](https://gohugo.io/content-management/image-processing/)
|
- **`imgproc`** Hugo shortcode for image processing, plus additional **`position`** param [ left | center | right ] (optional).
|
||||||
|
- eg: `{{< imgproc "img/hello.png" Resize "250x" center />}}`
|
||||||
|
- More detailed info on processing commands at [https://gohugo.io/content-management/image-processing/](https://gohugo.io/content-management/image-processing/)
|
||||||
|
|
||||||
#### Code highlighting
|
#### Code highlighting
|
||||||
|
|
||||||
|
1
USERS.md
1
USERS.md
@ -25,3 +25,4 @@ TEMPLATE:
|
|||||||
- https://mritd.com/ - **漠然** (Software Engineer and DevOps)
|
- https://mritd.com/ - **漠然** (Software Engineer and DevOps)
|
||||||
- https://ilya-lesikov.com - **Ilya Lesikov** (DevOps, SRE)
|
- https://ilya-lesikov.com - **Ilya Lesikov** (DevOps, SRE)
|
||||||
- https://www.adamormsby.com - **Adam Ormsby** (Generalist Programmer - Web, Mobile, Games)
|
- https://www.adamormsby.com - **Adam Ormsby** (Generalist Programmer - Web, Mobile, Games)
|
||||||
|
- https://kartiniteknologi.id/ - **Kartini Teknologi team** (Tech podcast)
|
||||||
|
19
layouts/404.html
Normal file
19
layouts/404.html
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
{{ define "main" }}
|
||||||
|
<div class="post">
|
||||||
|
<h1 class="post-title"><a href="{{ .Permalink }}">{{ .Title | markdownify }}</a></h1>
|
||||||
|
<div class="post-content">
|
||||||
|
<p>{{ "Hmm... Sorry, this page seems to be missing." | markdownify }}
|
||||||
|
{{ if .Site.Taxonomies.tags }}
|
||||||
|
{{ "Maybe these tags will help you find what you're looking for. :smile:" | markdownify | emojify }}</p>
|
||||||
|
<h2>Tags</h2>
|
||||||
|
<div class="terms">
|
||||||
|
<ul class="terms__list">
|
||||||
|
{{ range .Site.Taxonomies.tags }}
|
||||||
|
<li class="terms__term"><a href="{{ .Page.Permalink }}">#{{ .Page.Title }}</a><span class="terms__term-count">{{ .Count }}</span></li>
|
||||||
|
{{ end }}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
@ -1,6 +1,7 @@
|
|||||||
{{ $original := .Page.Resources.GetMatch (printf "*%s*" (.Get 0)) }}
|
{{ $original := .Page.Resources.GetMatch (printf "*%s*" (.Get 0)) }}
|
||||||
{{ $command := .Get 1 }}
|
{{ $command := .Get 1 }}
|
||||||
{{ $options := .Get 2 }}
|
{{ $options := .Get 2 }}
|
||||||
|
{{ $position := .Get 3}}
|
||||||
|
|
||||||
{{ if eq $command "Fit"}}
|
{{ if eq $command "Fit"}}
|
||||||
{{ .Scratch.Set "image" ($original.Fit $options) }}
|
{{ .Scratch.Set "image" ($original.Fit $options) }}
|
||||||
@ -14,7 +15,7 @@
|
|||||||
|
|
||||||
{{ $image := .Scratch.Get "image" }}
|
{{ $image := .Scratch.Get "image" }}
|
||||||
|
|
||||||
<figure>
|
<figure class="{{ with $position }}{{ . }}{{ else -}} left {{- end }}" >
|
||||||
<img style="max-width: 100%; width: auto; height: auto; border-radius: 8px;" src="{{ $image.RelPermalink }}" width="{{ $image.Width }}" height="{{ $image.Height }}">
|
<img style="max-width: 100%; width: auto; height: auto; border-radius: 8px;" src="{{ $image.RelPermalink }}" width="{{ $image.Width }}" height="{{ $image.Height }}">
|
||||||
{{ with .Inner }}
|
{{ with .Inner }}
|
||||||
<figcaption>
|
<figcaption>
|
||||||
|
@ -112,7 +112,6 @@
|
|||||||
li {
|
li {
|
||||||
.menu__inner & {
|
.menu__inner & {
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
padding: 10px;
|
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
@ -126,6 +125,12 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
li a {
|
||||||
|
width: 100%;
|
||||||
|
display: inline-block;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user