Add all
This commit is contained in:
parent
b9dec9b3c4
commit
c20e568242
113 changed files with 12662 additions and 3 deletions
|
@ -1,3 +0,0 @@
|
|||
# site
|
||||
|
||||
https://sadium.cyou
|
12
archetypes/default.md
Executable file
12
archetypes/default.md
Executable file
|
@ -0,0 +1,12 @@
|
|||
+++
|
||||
title = "{{ replace .Name "-" " " | title }}"
|
||||
date = ""
|
||||
author = ""
|
||||
cover = ""
|
||||
tags = ["обои", ""]
|
||||
description = "
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
170
config.toml
Executable file
170
config.toml
Executable file
|
@ -0,0 +1,170 @@
|
|||
baseurl = ""
|
||||
# languageCode = "ru-ru"
|
||||
theme = "hugo-theme-terminal"
|
||||
# paginate = 5
|
||||
DefaultContentLanguage = "ru"
|
||||
# defaultContentLanguageInSubdir = true
|
||||
# enableGitInfo = true
|
||||
|
||||
# [frontmatter]
|
||||
# lastmod = ['lastmod', ':git', 'date', 'publishDate']
|
||||
|
||||
|
||||
[params]
|
||||
# dir name of your main content (default is `content/posts`).
|
||||
# the list of set content will show up on your index page (baseurl).
|
||||
contentTypeName = "about"
|
||||
|
||||
# ["orange", "blue", "red", "green", "pink"]
|
||||
themeColor = "red"
|
||||
|
||||
# if you set this to 0, only submenu trigger will be visible
|
||||
showMenuItems = 10
|
||||
|
||||
# show selector to switch language
|
||||
showLanguageSelector = true
|
||||
|
||||
# set theme to full screen width
|
||||
fullWidthTheme = false
|
||||
|
||||
# center theme with default width
|
||||
centerTheme = true
|
||||
|
||||
# if your resource directory contains an image called `cover.(jpg|png|webp)`,
|
||||
# then the file will be used as a cover automatically.
|
||||
# With this option you don't have to put the `cover` param in a front-matter.
|
||||
autoCover = false
|
||||
|
||||
# set post to show the last updated
|
||||
# If you use git, you can set `enableGitInfo` to `true` and then post will automatically get the last updated
|
||||
# showLastUpdated = true
|
||||
|
||||
# set a custom favicon (default is a `themeColor` square)
|
||||
favicon = "/img/favicon/favicon.svg"
|
||||
|
||||
# Provide a string as a prefix for the last update date. By default, it looks like this: 2020-xx-xx [Updated: 2020-xx-xx] :: Author
|
||||
# updatedDatePrefix = "Обновлено/updated"
|
||||
|
||||
# set all headings to their default size (depending on browser settings)
|
||||
# oneHeadingSize = true # default
|
||||
|
||||
# whether to show a page's estimated reading time
|
||||
# readingTime = false # default
|
||||
|
||||
# whether to show a table of contents
|
||||
# can be overridden in a page's front-matter
|
||||
Toc = true # default
|
||||
|
||||
# set title for the table of contents
|
||||
# can be overridden in a page's front-matter
|
||||
# TocTitle = "Table of Contents" # default
|
||||
|
||||
[languages]
|
||||
[languages.en]
|
||||
# weight = 2
|
||||
languageCode= 'en'
|
||||
languageName = 'EN'
|
||||
languageFlag = "🇺🇸"
|
||||
title = "Sadium"
|
||||
# subtitle = "A simple, retro theme for Hugo"
|
||||
[languages.en.params]
|
||||
owner = "Sysadmin Link"
|
||||
keywords = ""
|
||||
copyright = ""
|
||||
menuMore = "Show more"
|
||||
readMore = "Read more"
|
||||
readOtherPosts = "Read other posts"
|
||||
newerPosts = "Newer posts"
|
||||
olderPosts = "Older posts"
|
||||
missingContentMessage = "Page not found..."
|
||||
missingBackButtonLabel = "Back to home page"
|
||||
|
||||
[languages.en.params.logo]
|
||||
logoText = "Sadium"
|
||||
logoHomeLink = "/en"
|
||||
|
||||
[languages.en.menu]
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "about"
|
||||
name = "About"
|
||||
url = "/en/about"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "services"
|
||||
name = "Services"
|
||||
url = "/en/services"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "posts"
|
||||
name = "Posts"
|
||||
url = "/en/posts"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "contacts"
|
||||
name = "Contacts"
|
||||
url = "/en/contacts"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "stream"
|
||||
name = "Live"
|
||||
url = "https://live.sadium.cyou"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "status"
|
||||
name = "Status"
|
||||
url = "https://up.sadium.cyou"
|
||||
# [[languages.en.menu.main]]
|
||||
# identifier = "donate"
|
||||
# name = "🪙"
|
||||
# url = "/en/donate"
|
||||
|
||||
|
||||
[languages.ru]
|
||||
# weight = 1
|
||||
languageCode = 'ru'
|
||||
languageName = 'RU'
|
||||
languageFlag = "🇷🇺"
|
||||
title = "Sadium"
|
||||
[languages.ru.params]
|
||||
# subtitle = "A simple, retro theme for Hugo"
|
||||
writtenby = "Сисадмин Линк"
|
||||
keywords = ""
|
||||
copyright = ""
|
||||
menuMore = "Меню"
|
||||
readMore = "Читать далее"
|
||||
readOtherPosts = "Читать другие статьи"
|
||||
newerPosts = "Новые посты"
|
||||
olderPosts = "Старые посты"
|
||||
missingContentMessage = "Страница не найдена..."
|
||||
missingBackButtonLabel = "Вернуться на домашнюю страницу"
|
||||
# url = "/"
|
||||
|
||||
[languages.ru.params.logo]
|
||||
logoText = "Sadium"
|
||||
# logoHomeLink = "/"
|
||||
|
||||
[languages.ru.menu]
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "services"
|
||||
name = "Сервисы"
|
||||
url = "/services"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "posts"
|
||||
name = "Статьи"
|
||||
url = "/posts"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "about"
|
||||
name = "Обо мне"
|
||||
url = "/about"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "contacts"
|
||||
name = "Контакты"
|
||||
url = "/contacts"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "donate"
|
||||
name = "💴"
|
||||
url = "/donate"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "stream"
|
||||
name = "Трансляции"
|
||||
url = "https://live.sadium.cyou"
|
||||
[[languages.ru.menu.main]]
|
||||
identifier = "status"
|
||||
name = "Статус"
|
||||
url = "https://up.sadium.cyou"
|
||||
|
3
content/about/_index.en.md
Executable file
3
content/about/_index.en.md
Executable file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
title: "About"
|
||||
---
|
3
content/about/_index.ru.md
Executable file
3
content/about/_index.ru.md
Executable file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
title: "Обо мне"
|
||||
---
|
17
content/about/about.en.md
Executable file
17
content/about/about.en.md
Executable file
|
@ -0,0 +1,17 @@
|
|||
---
|
||||
title: ""
|
||||
showFullContent: true
|
||||
description: ""
|
||||
---
|
||||
|
||||
{{< avatar >}}
|
||||
|
||||
# Sup!
|
||||
|
||||
Name is **Sysadmin Link**, man, 23 y.o., I am the creator of this site and hoster of some **open source** [services](/en/services).
|
||||
|
||||
I work as sysadmin in some college unit.
|
||||
|
||||
Thats all... for now
|
||||
{{< mastodon-owner >}}
|
||||
<!-- date: "2023-02-12" -->
|
19
content/about/about.ru.md
Executable file
19
content/about/about.ru.md
Executable file
|
@ -0,0 +1,19 @@
|
|||
---
|
||||
title: ""
|
||||
showFullContent: true
|
||||
description: ""
|
||||
---
|
||||
|
||||
{{< avatar >}}
|
||||
|
||||
# Приветствую!
|
||||
|
||||
Меня звать **Сисадмин Линк**, парень, 23 годика, я создатель данного сайта и хостер некоторых [сервисов](/services) с **открытым исходным кодом**.
|
||||
|
||||
Работаю сисадмином в подразделении одного колледжа.
|
||||
|
||||
Это всё... пока что.
|
||||
{{< mastodon-owner >}}
|
||||
|
||||
<!-- author: "Сисадмин Линк" -->
|
||||
<!-- date: "2023-10-30" -->
|
3
content/contacts/_index.en.md
Normal file
3
content/contacts/_index.en.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
+++
|
||||
title = "Contacts"
|
||||
+++
|
3
content/contacts/_index.ru.md
Normal file
3
content/contacts/_index.ru.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
+++
|
||||
title = "Контакты"
|
||||
+++
|
13
content/contacts/contacts.en.md
Executable file
13
content/contacts/contacts.en.md
Executable file
|
@ -0,0 +1,13 @@
|
|||
+++
|
||||
showFullContent = true
|
||||
+++
|
||||
|
||||
**`Email`**\
|
||||
[sadml[at]disroot.org](mailto:sadml@disroot.org)\
|
||||
[sadml[at]sadium.cyou](mailto:sadml@sadium.cyou)
|
||||
|
||||
**`Fediverse`**\
|
||||
[@sl@social.exo.icu](https://social.exo.icu/@sl)
|
||||
|
||||
**`Matrix`**\
|
||||
[@sl:sadium.cyou](https://matrix.to/#/@sl:sadium.cyou)
|
13
content/contacts/contacts.ru.md
Executable file
13
content/contacts/contacts.ru.md
Executable file
|
@ -0,0 +1,13 @@
|
|||
+++
|
||||
showFullContent = true
|
||||
+++
|
||||
|
||||
**`Email`**\
|
||||
[sadml[at]disroot.org](mailto:sadml@disroot.org)\
|
||||
[sadml[at]sadium.cyou](mailto:sadml@sadium.cyou)
|
||||
|
||||
**`Fediverse`**\
|
||||
[@sl@social.exo.icu](https://social.exo.icu/@sl)
|
||||
|
||||
**`Matrix`**\
|
||||
[@sl:sadium.cyou](https://matrix.to/#/@sl:sadium.cyou)
|
5
content/donate.ru.md
Normal file
5
content/donate.ru.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
|Никого не принуждаю, но если можете, отсыпьте копеечку: | [Свобода добра](https://habr.com/ru/articles/648857) |
|
||||
| --- | --- |
|
||||
| 5536 9139 9438 8268 | Тинькофф |
|
||||
Пожалуйста, напишите в сообщении к переводу, что вы осознанно отправили его, а не сделали это по ошибке, чтобы никто не переживал потом 😅 | |
|
||||
| [OVERXWISE](https://qiwi.com/n/OVERXWISE) | [Qiwi](https://qiwi.com/n/OVERXWISE) |
|
3
content/posts/_index.en.md
Executable file
3
content/posts/_index.en.md
Executable file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
title: "Posts"
|
||||
---
|
4
content/posts/_index.ru.md
Executable file
4
content/posts/_index.ru.md
Executable file
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
title: "Статьи"
|
||||
---
|
||||
|
39
content/posts/codeberg_x_nextcloud.en.md
Normal file
39
content/posts/codeberg_x_nextcloud.en.md
Normal file
|
@ -0,0 +1,39 @@
|
|||
+++
|
||||
title = "Setup Codeberg as custom Oauth2 provider in Nexcloud"
|
||||
date = "2023-12-10"
|
||||
author = "Sysadmin Link"
|
||||
cover = ""
|
||||
tags = ["codeberg", "nextcloud"]
|
||||
description = "via Nextcloud Social Login"
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
||||
I couldn't find any info about it via search engines, so I decided to put information here. \
|
||||
What is helped - https://forgejo.codeberg.page/docs/latest/user/oauth2-provider/
|
||||
|
||||
`1.` [Create app in Codeberg](https://codeberg.org/user/settings/applications) and copy Client ID and Client secret somewhere. \
|
||||
`2.` Go to your Nextcloud Admin settings,`Social Login` section, and create Custom Oauth2 provider.
|
||||
|
||||
| Section | What to enter |
|
||||
| --- | --- |
|
||||
| Local/inner name | Codeberg |
|
||||
| Name | Codeberg |
|
||||
| API Base URL | https://codeberg.org |
|
||||
| Authorize url | https://codeberg.org/login/oauth/authorize |
|
||||
| Token url | https://codeberg.org/login/oauth/access_token |
|
||||
| Profile url | https://codeberg.org/login/oauth/userinfo |
|
||||
| Logout url | leave empty |
|
||||
| Client ID and Client secret | paste from step 1 |
|
||||
| Scope | read:user |
|
||||
| Other after | leave empty if not sure |
|
||||
|
||||
`3.` Tick `Allow users to attach/connect their social logins` box and click `Save` in the bottom of page. \
|
||||
`4.` Go in Incognito/Private window of your browser, go to your Nextcloud login page and copy path of Codeberg provider - Right click, copy link, save somewhere. \
|
||||
Must look like this - `https://cloud.example.org(/index.php)/apps/sociallogin/custom_oauth2/Codeberg` \
|
||||
`5.` Go back to your created earlier [Codeberg application](https://codeberg.org/user/settings/applications), click `Edit` button and paste link from step 4 into `Redirection URI` section, click `Save`.
|
||||
|
||||
And you done! Try connect your Codeberg account to Nextcloud account from user settings `Social Login` section, it must work. In theory, it's also appliable to `Gitea`, because [Forgejo](https://forgejo.org) is [Gitea's](https://gitea.com) fork.
|
||||
|
||||
I've created related Github issue: https://github.com/zorn-v/nextcloud-social-login/issues/440
|
39
content/posts/codeberg_x_nextcloud.ru.md
Normal file
39
content/posts/codeberg_x_nextcloud.ru.md
Normal file
|
@ -0,0 +1,39 @@
|
|||
+++
|
||||
title = "Как настроить Codeberg как провайдер входа Oauth2 для Nexcloud"
|
||||
date = "2023-12-10"
|
||||
author = "Sysadmin Link"
|
||||
cover = ""
|
||||
tags = ["codeberg", "nextcloud"]
|
||||
description = "при помощи плагина Social Login для Nextcloud"
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
||||
Я не смог найти никакой информации об этом через поисковые системы, поэтому решил написать об этом здесь. \
|
||||
Пригодилось - https://forgejo.codeberg.page/docs/latest/user/oauth2-provider/
|
||||
|
||||
`1.` [Создаём приложение в Codeberg](https://codeberg.org/user/settings/applications) и копируем куда-нибудь Client ID и Client secret. \
|
||||
`2.` Идём в параметры сервера Nextcloud, пункт `Social Login`, и создаём Custom Oauth2 на `+`.
|
||||
|
||||
| Пункт | Что вводить |
|
||||
| --- | --- |
|
||||
| Внутреннее имя | Codeberg |
|
||||
| Название | Codeberg |
|
||||
| API Base URL | https://codeberg.org |
|
||||
| Authorize url | https://codeberg.org/login/oauth/authorize |
|
||||
| Token url | https://codeberg.org/login/oauth/access_token |
|
||||
| Profile url | https://codeberg.org/login/oauth/userinfo |
|
||||
| Logout url | Оставить пустым |
|
||||
| Client ID и Client secret | вставить из 1 пункта |
|
||||
| Scope | read:user |
|
||||
| Остальные после | Не трогайте, если не уверены |
|
||||
|
||||
`3.` Ставим галку напротив пункта `Позволять пользователям подключать социальные логины к своим аккаунтам` и нажимаем `Сохранить` внизу страницы. \
|
||||
`4.` Идём в режим Инкогнито вашего браузера, затем на страничку входа в ваше облако и копируем путь провайдера Codeberg - правая кнопка мыши, копируем ссылку, сохраняем куда-нибудь. \
|
||||
Должно выглядеть примерно так - `https://cloud.example.org(/index.php)/apps/sociallogin/custom_oauth2/Codeberg` \
|
||||
`5.` Возвращаемся к ранее созданному [приложению Codeberg](https://codeberg.org/user/settings/applications), Нажимаем `Изменить` и вставляем ссылку из прошлого пункта в поле `URI для перенаправления`, нажимаем `Сохранить`.
|
||||
|
||||
Теперь попробуйте связать ваш аккаунт Codeberg и Nextcloud из пункта `Social Login` в настройках пользователя Nextcloud, должно работать. В теории, это также применимо к `Gitea`, потому что [Forgejo](https://forgejo.org) это форк [Gitea](https://gitea.com).
|
||||
|
||||
Давеча сделал по этому поводу Issue на Github: https://github.com/zorn-v/nextcloud-social-login/issues/440
|
34
content/posts/ricoh_config.ru.md
Normal file
34
content/posts/ricoh_config.ru.md
Normal file
|
@ -0,0 +1,34 @@
|
|||
+++
|
||||
title = "Мучения с принтером"
|
||||
date = "2023-09-09"
|
||||
author = "Сисадмин Линк"
|
||||
cover = ""
|
||||
tags = ["софт", "принтер"]
|
||||
description = "Настройка Ricoh SP100 SU в Arch-based дистрибутивах"
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
||||
Я всё думал, как завести свой принтер под Linux. \
|
||||
И однажды наткнулся на [пакет](https://aur.archlinux.org/packages/ricoh-sp100-git) в AUR, который, правда, оказался нерабочим, поскольку source репозиторий был удалён.
|
||||
|
||||
Но недавно в очередных поисках я наткнулся на [раздел на форуме Ubuntu](https://forum.ubuntu.ru/index.php?PHPSESSID=b541bb569cce4b86e0a21bf1f69ca5ec&topic=203120.msg2481757#msg2481757). \
|
||||
Там добрый человек поделился репозиторием - [туть](https://git.kernel.org/pub/scm/linux/kernel/git/jejb/ricoh-sp100.git/).
|
||||
|
||||
Однако я поступил по другому, не так, как написал человек на форуме. \
|
||||
Последовательность
|
||||
|
||||
`git clone https://git.kernel.org/pub/scm/linux/kernel/git/jejb/ricoh-sp100.git/` \
|
||||
`cd ricoh-sp100` \
|
||||
`sudo cp pstoricohddst-gdi /usr/lib/cups/filter` \
|
||||
`sudo cp *.ppd /usr/share/cups/model`
|
||||
|
||||
Если есть yay: \
|
||||
`yay -S jbigkit inotify-tools`
|
||||
|
||||
Если нет:\
|
||||
`sudo pacman -S jbigkit inotify-tools`
|
||||
|
||||
Как то так. Теперь идём и настраиваем наш принтер в своём рабочем окружении и радуемся жизни. \
|
||||
{{< mastodon-owner >}}
|
16
content/posts/rpi-rip-nvme.ru.md
Normal file
16
content/posts/rpi-rip-nvme.ru.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
---
|
||||
title: "Не берите дешёвые M2 NMVE"
|
||||
date: "2023-10-07"
|
||||
author: "Сисадмин Линк"
|
||||
showFullContent: false
|
||||
tags: ["nvme", "сервер"]
|
||||
description: "Из-за этого у меня пропало всё"
|
||||
---
|
||||
|
||||
Да, знаю, сам дурак, не сделал бэкапы. Хотя, с другой стороны, самое важное не пострадало - файлы в Nextcloud. Они-то, как раз-таки, лежали на отдельном рейде. И не только они, этот сайт, например, тоже. Так или иначе, я не собирался делать из Малинки серьёзный сервер. Мощи у неё не те, хотя тянула она NC неплохо, однако, когда дело доходило до мобильного клиента, это был тихий ад.
|
||||
|
||||
Ну, поскольку смысла было покупать новый диск для Малинки я не видел, я просто решил собрать сервер на своём страком компутерном железе, а именно на проце Intel Pentium G4560 aka Гиперпень, и материнка Asus H110M-R. Ну и какая-то там планка оперативки на 8ГБ частотой 2133МГц. Диск тоже, по факту, был со старого компа, просто на момент работы сервера на Малинке он у меня был чисто под виртуалки всякие. Это SSD SanDisk на 120Гб.
|
||||
|
||||
В ближайшее время я планирую проапгрейдить сервер новым процом, в неближайшее - диском, и хочу докинуть ещё плашку оперативы на 8ГБ, дабы был двухканал. Процессор этот будет Intel Core i5 7600. Брал его [тут](https://aliexpress.ru/item/1005003651636041.html). Хотел взять Xeon-E3 1245 v5, однако без плясок с бубнами и программатора, мне бы его не получилось завести на этой материнке, менять которую мне вообще ни разу не хочется, да и с бубном плясать тоже неохота. После хотелось бы взять SSD Samsung EVO, скорее всего [этот](https://www.dns-shop.ru/product/184d257ee33aed20/500-gb-25-sata-nakopitel-samsung-870-evo-mz-77e500bkr). Ну а плашку оперативы возьму [эту](https://www.citilink.ru/product/modul-pamyati-kingmax-ddr4-8gb-2133-dimm-ret-400808). В идеале бы ещё ИБПшник взять, но я не знаю, какой...
|
||||
|
||||
Может допишу ещё чего...
|
23
content/posts/walls.en.md
Normal file
23
content/posts/walls.en.md
Normal file
|
@ -0,0 +1,23 @@
|
|||
+++
|
||||
title = "Wallpapers Collection"
|
||||
date = "2023-07-01"
|
||||
author = "Sysadmin Link"
|
||||
cover = ""
|
||||
tags = ["wallpapers"]
|
||||
description = "My collection of wallpapers"
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
||||
I bring to your attention my collection of wallpapers, which has already reached more than 1500 wallpapers.
|
||||
|
||||
You can view them and pick it up [here](https://cloud.sadium.cyou/s/walls).
|
||||
|
||||
About collection:
|
||||
- Most of the wallpapers are taken from [wallhaven.cc](https://wallhaven.cc)
|
||||
- Have some NSFW (~3-10%)
|
||||
- Expanded and supplemented at least weekly.
|
||||
|
||||
Some wallpapers may have a quality lower than FullHD (1920x1080), coz I couldn't find them in a better quality. If anyone can find it, I would appreciate it if you send me a link
|
||||
{{< mastodon-owner >}}
|
23
content/posts/walls.ru.md
Normal file
23
content/posts/walls.ru.md
Normal file
|
@ -0,0 +1,23 @@
|
|||
+++
|
||||
title = "Подборка обоев"
|
||||
date = "2023-07-01"
|
||||
author = "Сисадмин Линк"
|
||||
cover = ""
|
||||
tags = ["обои", "wallpapers"]
|
||||
description = "Моя подборка обоев"
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
+++
|
||||
|
||||
Предлагаю вашему вниманию свою подборку обоев, которая уже достигла более 1500 обоев.
|
||||
|
||||
Посмотреть их и забрать её можно [тут](https://cloud.sadium.cyou/s/walls).
|
||||
|
||||
О подборке:
|
||||
- Большая часть обоев взято с [wallhaven.cc](https://wallhaven.cc)
|
||||
- Содержит NSFW (около ~3-10%)
|
||||
- Дополняется и обновляется как минимум еженедельно.
|
||||
|
||||
У некоторых обоев может быть качество ниже FullHD (1920x1080), поскольку я не смог их найти в более лучшем качестве. Если кто сможет найти, буду признателен, если кинете ссылку.
|
||||
{{< mastodon-owner >}}
|
3
content/services/_index.en.md
Executable file
3
content/services/_index.en.md
Executable file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
title: "Services"
|
||||
---
|
3
content/services/_index.ru.md
Executable file
3
content/services/_index.ru.md
Executable file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
title: "Сервисы"
|
||||
---
|
77
content/services/services.en.md
Executable file
77
content/services/services.en.md
Executable file
|
@ -0,0 +1,77 @@
|
|||
+++
|
||||
showFullContent = true
|
||||
+++
|
||||
|
||||
# Public
|
||||
---
|
||||
### Forgejo
|
||||
[My instance](https://git.sadium.cyou/) | [Website](https://forgejo.org) | [Source code](https://codeberg.org/forgejo/forgejo) | `Registration open` | `Nextcloud OIDC`
|
||||
|
||||
>**Forgejo**, **[Gitea](https://gitea.io)** fork - Self-hosted lightweight software forge.
|
||||
|
||||
### Matrix Admin UI
|
||||
[My instance](https://ma.sadium.cyou/) | [Source code](https://github.com/Awesome-Technologies/synapse-admin)
|
||||
|
||||
> **Matrix Admin UI** - Matrix Admin UI. `¯\_(ツ)_/¯`
|
||||
|
||||
### Matrix Web-client UI
|
||||
[My instance](https://mw.sadium.cyou/) | [Website](https://element.io/) | [Source code](https://github.com/vector-im/element-web/)
|
||||
|
||||
> **Element-web** - A glossy Matrix collaboration client for the web.
|
||||
|
||||
### Matrix Synapse
|
||||
`sadium.cyou` | [Website](https://matrix.org) | [Source code](https://github.com/matrix-org/synapse) | `Registration closed` | `Nextcloud OIDC`
|
||||
|
||||
> **Synapse** - open-source Matrix homeserver written and maintained by the Matrix.org Foundation. Briefly, Matrix is an open standard for communications on the internet, supporting federation, encryption and VoIP.
|
||||
|
||||
### Nextcloud
|
||||
[My instance](https://cloud.sadium.cyou) | [Website](https://nextcloud.com) | [Source code](https://github.com/nextcloud/server) | `Registration by premoderation` | `OIDC`
|
||||
|
||||
>**Nextcloud** - suite of client-server software for creating and using file hosting services.
|
||||
>Alternative for Google Suite, Dropbox, OneDrive, etc.
|
||||
|
||||
### Owncast
|
||||
[My instance](https://live.sadium.cyou/) | [Website](https://owncast.online) | [Source code](https://github.com/owncast/owncast)
|
||||
|
||||
>**Owncast** - self-hosted live video and web chat server for use with existing popular broadcasting software.
|
||||
|
||||
### RSS-Bridge
|
||||
[My instance](https://rss.sadium.cyou/) | [Website](https://rss-bridge.github.io/rss-bridge) | [Source code](https://github.com/rss-bridge/rss-bridge)
|
||||
|
||||
>**RSS-Bridge** - free and open source software for generating Atom or RSS feeds from websites which don't have one.
|
||||
|
||||
### Shlink
|
||||
[My webUI instance](https://shlink.sadium.cyou/) | [Website](https://shlink.io) | [Server source code](https://github.com/shlinkio/shlink) | [WebUI source code](https://github.com/shlinkio/shlink-web-client)
|
||||
|
||||
>**Shlink** - PHP-based self-hosted URL shortener that can be used to serve shortened URLs under your own domain.
|
||||
|
||||
### Vaultwarden
|
||||
[My instance](https://vault.sadium.cyou/) | [Source code сервера](https://github.com/dani-garcia/vaultwarden) | [WebUI source code](https://github.com/dani-garcia/bw_web_builds) | `Registration open`
|
||||
|
||||
>**Vaultwarden**, **[Bitwarden](https://bitwarden.com)** fork - free and open-source password management service that stores sensitive information such as website credentials in an encrypted vault.
|
||||
|
||||
### Uptime Kuma
|
||||
[My instance](https://up.sadium.cyou) | [Source code](https://github.com/louislam/uptime-kuma)
|
||||
|
||||
>**Uptime Kuma** - A fancy self-hosted monitoring tool.
|
||||
---
|
||||
# Personal/Private
|
||||
|
||||
### Adguard Home
|
||||
[Source code](https://github.com/AdguardTeam/AdGuardHome/)
|
||||
|
||||
>**Adguard Home** - Network-wide ads & trackers blocking DNS server.
|
||||
|
||||
### Maddy Email
|
||||
[Website](https://maddy.email) | [Source code](https://github.com/foxcpp/maddy)
|
||||
|
||||
>**Maddy** - Composable all-in-one mail server.
|
||||
|
||||
### qBittorrent
|
||||
[Source code](https://github.com/qbittorrent/qBittorrent)
|
||||
|
||||
>**qBittorrent** - Open source torrent client.
|
||||
|
||||
---
|
||||
|
||||
The source code of the services listed in this article (and not only them) is stored on my [Forgejo](https://git.sadium.cyou/mirrors) instance.
|
83
content/services/services.ru.md
Executable file
83
content/services/services.ru.md
Executable file
|
@ -0,0 +1,83 @@
|
|||
+++
|
||||
showFullContent = true
|
||||
+++
|
||||
|
||||
# Публичные
|
||||
---
|
||||
### Forgejo
|
||||
[Мой инстанс](https://git.sadium.cyou/) | [Сайт](https://forgejo.org) | [Исходный код](https://codeberg.org/forgejo/forgejo) | `Регистрация открыта` | `Nextcloud OIDC`
|
||||
|
||||
>**Forgejo**, форк **[Gitea](https://gitea.io)** - Открытая легковесная "кузница" для создания ПО.
|
||||
|
||||
Однажды я сделаю PoW капчу...
|
||||
|
||||
### Matrix Admin UI
|
||||
[Мой инстанс](https://ma.sadium.cyou/) | [Исходный код](https://github.com/Awesome-Technologies/synapse-admin)
|
||||
|
||||
> **Matrix Admin UI** - Matrix Admin UI. `¯\_(ツ)_/¯`
|
||||
|
||||
### Matrix Element WebUI
|
||||
[Мой инстанс](https://mw.sadium.cyou/) | [Сайт](https://element.io/) | [Исходный код](https://github.com/vector-im/element-web/)
|
||||
|
||||
> **Element-web** - Глянцевый клиент Matrix для совместной работы в Интернете.
|
||||
|
||||
### Matrix Synapse
|
||||
`sadium.cyou` | [Сайт](https://matrix.org) | [Исходный код](https://github.com/matrix-org/synapse) | `Регистрация закрыта` | `Nextcloud OIDC`
|
||||
|
||||
> **Synapse** — домашний сервер Matrix с открытым исходным кодом, написанный и поддерживаемый Matrix.org Foundation. Вкратце, Matrix — это открытый стандарт связи в Интернете, поддерживающий федерацию, шифрование и VoIP.
|
||||
|
||||
### Nextcloud
|
||||
[Мой инстанс](https://cloud.sadium.cyou) | [Сайт](https://nextcloud.com) | [Исходный код](https://github.com/nextcloud/server) | `Регистрация по премодерации` | `OIDC`
|
||||
|
||||
>**Nextcloud** - набор клиент-серверных программ для создания и использования хранилища данных. \
|
||||
>Является свободным аналогом облаков от Google, Яндекс, Mail.ru (нынешний VK Group), и т.д.
|
||||
|
||||
### Owncast
|
||||
[Мой инстанс](https://live.sadium.cyou/) | [Сайт](https://owncast.online) | [Исходный код](https://github.com/owncast/owncast)
|
||||
|
||||
>**Owncast** - автономный сервер видеотрансляций и веб-чатов для использования с существующим популярным программным обеспечением для вещания.
|
||||
|
||||
### RSS-Bridge
|
||||
[Мой инстанс](https://rss.sadium.cyou/) | [Сайт](https://rss-bridge.github.io/rss-bridge) | [Исходный код](https://github.com/rss-bridge/rss-bridge)
|
||||
|
||||
>**RSS-Bridge** - программное обеспечение для создания Atom или RSS-каналов с веб-сайтов, у которых их нет.
|
||||
|
||||
Мостов [куча](https://github.com/RSS-Bridge/rss-bridge/tree/master/bridges), могу по просьбе добавить в список активных ещё какие-нибудь.
|
||||
|
||||
### Shlink
|
||||
[Мой инстанс веб-интерфейса](https://shlink.sadium.cyou/) | [Сайт](https://shlink.io) | [Исходный код сервера](https://github.com/shlinkio/shlink) | [Исходный код WebUI](https://github.com/shlinkio/shlink-web-client)
|
||||
|
||||
>**Shlink** - Автономный сокращатель URL-адресов на основе PHP, который можно использовать для обслуживания сокращенных URL-адресов в вашем собственном домене.
|
||||
|
||||
### Vaultwarden
|
||||
[Мой инстанс](https://vault.sadium.cyou/) | [Исходный код сервера](https://github.com/dani-garcia/vaultwarden) | [Исходный код WebUI](https://github.com/dani-garcia/bw_web_builds) | `Регистрация открыта`
|
||||
|
||||
>**Vaultwarden**, форк **[Bitwarden](https://bitwarden.com)** - менеджера паролей с открытым кодом. Имеет приложения нескольких форматов, включая веб-интерфейс, настольные приложения, расширение браузера, мобильные приложения и CLI
|
||||
|
||||
### Uptime Kuma
|
||||
[Мой инстанс](https://up.sadium.cyou) | [Исходный код](https://github.com/louislam/uptime-kuma)
|
||||
|
||||
>**Uptime Kuma** - Инструмент для мониторинга с возможностью самохостинга.
|
||||
---
|
||||
# Личные/приватные
|
||||
|
||||
### Adguard Home
|
||||
[Исходный код](https://github.com/AdguardTeam/AdGuardHome)
|
||||
|
||||
>**Adguard Home** - Межсетевой DNS сервер блокировщика рекламы и трекеров.
|
||||
|
||||
### Maddy Email
|
||||
[Сайт](https://maddy.email) | [Исходный код](https://github.com/foxcpp/maddy)
|
||||
|
||||
>**Maddy** - Составной почтовый сервер "все в одном".
|
||||
|
||||
### qBittorrent
|
||||
[Исходный код](https://github.com/qbittorrent/qBittorrent)
|
||||
|
||||
>**qBittorrent** - Открытый торрент-клиент.
|
||||
|
||||
---
|
||||
|
||||
Исходный код указанных в этой статье сервисов (и не только) отзеркален на моём инстансе **[Forgejo](https://git.sadium.cyou/mirrors)**.
|
||||
|
||||
|
67
content/tos.md
Executable file
67
content/tos.md
Executable file
|
@ -0,0 +1,67 @@
|
|||
---
|
||||
title: "Условия использования"
|
||||
showFullContent: false
|
||||
description: ""
|
||||
---
|
||||
|
||||
## Общее положение
|
||||
|
||||
Данный документ - свод правил поведения. При использовании любых сервисов, размещённых в рамках проекта `Sadium`, администрация и, мы надеемся, сообщество, должны соблюдать данный свод правил.
|
||||
|
||||
Данный документ относится ко всем сервисам, размещенным в рамках проекта `Sadium`. Это означает, что данный свод правил нужно соблюдать при использовании сервисов, размещенных на домене и под-доменах `*.sadium.cyou`.
|
||||
|
||||
## Сервис предоставляется "как есть"
|
||||
|
||||
**`Сервис`** - онлайн-ресурсы и ПО, размещенные в рамках проекта `Sadium` на домене и под-доменах `*.sadium.cyou`.
|
||||
|
||||
Вы понимаете и соглашаетесь с тем, что **`Сервис`** предоставляется «как есть» без каких-либо гарантий, что сервис не содержит ошибок или дефектов. Администрация **`Сервиса`** не несёт никакой ответственности за какую-либо неверную и/или несвоевременную доставку информации, правильность обработки предоставленных и/или копируемых данных, а равно за прямой или косвенный ущерб, вызванный использованием данного **`Сервиса`**.
|
||||
|
||||
## Отказ от ответственности
|
||||
|
||||
Дополнительно сообщаем, что администрация проекта `Sadium` несёт ответственность только за контент, размещенный на "своих" сервисах. Администрация `Sadium` отказывается от ответвенности за размещение контента через "проксирующие" сервисы, ибо не имеет технической и правовой возможности его контроллировать.
|
||||
|
||||
Проект `Sadium` просит обратить внимание, что администрация не занимается модерированием каждого действия пользователей, в то же время контент может модерироваться/удаляться по обращению правообладателей, но только в том случае, если правообладатель сможет доказать авторство опубликованного на домене `*.sadium.cyou` контента.
|
||||
|
||||
Жалобы на контент принимаются только в письменном виде и в специальной для этого форме: - <ссылка на форму>
|
||||
|
||||
- **`Сервис`** считается "своим", если веб-приложение, находящееся на домене `*.sadium.cyou`, либо его контент может контролироваться администрацией (изменение, создание, удаление), а так же если администраторы проекта `Sadium` имеют техническую возможность контролировать пользователей как сущность базы данных (удалять, создавать, изменять).
|
||||
- **`Сервис`** считается "проксирующим", если веб-приложение, находящееся на домене `*.sadium.cyou`, по сути своей, является лишь альтернативным путём для получения контента, и контент никак не может быть изменен администрацией проекта `Sadium`.
|
||||
|
||||
## Персональные данные
|
||||
|
||||
Предоставляя свои персональные данные при использовании **`Сервиса`**, вы даёте своё согласие на обработку и использование своих персональных данных для работы **`Сервиса`**. Администрация проекта `Sadium` не принуждает вас указывать свои "настоящие" персональные данные.
|
||||
Администрация проекта `Sadium` не использует персональные данные пользователей в иных целях, если пользователь не изъявил обратного.
|
||||
|
||||
## Воспрещается
|
||||
|
||||
- Обсуждать/распространять/хранить порнографические материалы с участием несовершеннолетних.
|
||||
- Назойливо-агрессивное поведение (преследования, необоснованное хамство на постоянной основе и т.п.)
|
||||
- Создавать аккаунт для компании/ИП/самозанятого пользователя, если цель создания аккаунта - извлечение прибыли.
|
||||
- Разглашать личные данные[1] пользователя без его согласия. Если пользователь (в не зависимости от его инстанса) потребует удаления своих личных данных со страницы пользователя, относящегося к проекту `*.sadium.cyou` - пользователь sadium.cyou обязан это сделать, в ином случае это сделает администрация.
|
||||
- Призывать к травле[2]. Одно дело - высказать своё мнение о пользователе. Совсем другое - мешать пользователю жить.
|
||||
- Рассылать спам.
|
||||
|
||||
## Обращаем Ваше внимание:
|
||||
- Несовпадение взглядов (политических, сексуальных, религиозных...) пользователя со взглядами администрации не является основанием для санкций.
|
||||
---
|
||||
|
||||
[1] - Персональные данные или личные данные (ЛД) — любая информация, относящаяся прямо или косвенно к определенному пользователю. Любая информация, не опубликованная пользователем в открытый доступ будет считаться как ЛД пользователя.
|
||||
|
||||
В независимости от того, опубликованы или нет, ЛД всегда будут считаться:
|
||||
|
||||
- Паспортные данные, а именно совокупность таких данных, как ФИО, дата рождения, семейное положение.
|
||||
- Социальное и имущественное положение.
|
||||
- Информация о банковской карте, включая номер, PIN-код и CVV2/CVC2-коды.
|
||||
- Телефонный номер.
|
||||
|
||||
[2] - Призывом к травле может являться:
|
||||
|
||||
- Вмешательство в личную жизнь пользователя с целью негативного влияния на его ментальное и физическое состояние
|
||||
- Прямые и непосредственные призывы к насилию.
|
||||
- Призывы к насилию с использованием общих лозунгов.
|
||||
- Прямые и непосредственные призывы к дискриминации.
|
||||
- Призывы к дискриминации в виде общих лозунгов.
|
||||
|
||||
---
|
||||
Некоторые фрагменты текста были взяты и адаптированы [отсюда](https://git.thedroth.rocks/TheDroth/ToS/src/branch/main/README.md)\
|
||||
Данный текст ещё будет дорабатываться.
|
13
layouts/_default/single.html
Normal file
13
layouts/_default/single.html
Normal file
|
@ -0,0 +1,13 @@
|
|||
{{ define "main" }}
|
||||
<main>
|
||||
<article>
|
||||
<header>
|
||||
<h1>{{ .Title }}</h1>
|
||||
</header>
|
||||
{{ .Content }}
|
||||
</article>
|
||||
<aside>
|
||||
{{ .TableOfContents }}
|
||||
</aside>
|
||||
</main>
|
||||
{{ end }}
|
2
layouts/shortcodes/avatar.html
Normal file
2
layouts/shortcodes/avatar.html
Normal file
|
@ -0,0 +1,2 @@
|
|||
<img class="center" src="/img/avatar.jpg" width="300" style="border:3px; border-style:dashed; border-color:#ffffff; padding: 0px;">
|
||||
|
1
layouts/shortcodes/mastodon-owner.html
Normal file
1
layouts/shortcodes/mastodon-owner.html
Normal file
|
@ -0,0 +1 @@
|
|||
<a rel="me" href="https://social.exo.icu/@sl"></a>
|
8
layouts/shortcodes/owncast-chat.html
Normal file
8
layouts/shortcodes/owncast-chat.html
Normal file
|
@ -0,0 +1,8 @@
|
|||
<iframe
|
||||
src="https://live.sadium.ml/embed/chat/readonly"
|
||||
title="Chat"
|
||||
height="350px" width="800px"
|
||||
referrerpolicy="origin"
|
||||
scrolling="no"
|
||||
allowfullscreen>
|
||||
</iframe>
|
8
layouts/shortcodes/owncast-player.html
Normal file
8
layouts/shortcodes/owncast-player.html
Normal file
|
@ -0,0 +1,8 @@
|
|||
<iframe
|
||||
src="https://live.sadium.ml/embed/video"
|
||||
title="Owncast"
|
||||
height="400px" width="800px"
|
||||
referrerpolicy="origin"
|
||||
scrolling="no"
|
||||
allowfullscreen>
|
||||
</iframe>
|
BIN
static/img/avatar.jpg
Normal file
BIN
static/img/avatar.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 90 KiB |
39
static/img/favicon.svg
Normal file
39
static/img/favicon.svg
Normal file
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 51 KiB |
7
themes/hugo-theme-terminal/.babelrc
Normal file
7
themes/hugo-theme-terminal/.babelrc
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"presets": [
|
||||
["@babel/preset-env", {
|
||||
"targets": "last 2 versions, >1%, not dead"
|
||||
}],
|
||||
],
|
||||
}
|
60
themes/hugo-theme-terminal/.eslintrc.yml
Normal file
60
themes/hugo-theme-terminal/.eslintrc.yml
Normal file
|
@ -0,0 +1,60 @@
|
|||
---
|
||||
|
||||
env:
|
||||
es6: true
|
||||
|
||||
extends:
|
||||
# https://github.com/airbnb/javascript
|
||||
- airbnb
|
||||
- eslint:recommended
|
||||
- prettier
|
||||
|
||||
parser: babel-eslint
|
||||
|
||||
rules:
|
||||
# best practices
|
||||
arrow-parens:
|
||||
- 2
|
||||
- as-needed
|
||||
semi:
|
||||
- 2
|
||||
- always
|
||||
class-methods-use-this: 0
|
||||
comma-dangle:
|
||||
- 2
|
||||
- always-multiline
|
||||
no-console:
|
||||
- 2
|
||||
no-unused-expressions: 0
|
||||
no-param-reassign:
|
||||
- 2
|
||||
- props: false
|
||||
no-useless-escape: 0
|
||||
func-names: 0
|
||||
quotes:
|
||||
- 2
|
||||
- double
|
||||
- allowTemplateLiterals: true
|
||||
no-underscore-dangle: 0
|
||||
object-curly-newline: 0
|
||||
function-paren-newline: 0
|
||||
operator-linebreak:
|
||||
- 2
|
||||
- after
|
||||
no-unused-vars:
|
||||
- 2
|
||||
- argsIgnorePattern: "^_"
|
||||
# jsx a11y
|
||||
jsx-a11y/no-static-element-interactions: 0
|
||||
jsx-a11y/anchor-is-valid:
|
||||
- 2
|
||||
- specialLink:
|
||||
- to
|
||||
|
||||
globals:
|
||||
document: true
|
||||
requestAnimationFrame: true
|
||||
window: true
|
||||
self: true
|
||||
fetch: true
|
||||
Headers: true
|
1
themes/hugo-theme-terminal/.husky/.gitignore
vendored
Normal file
1
themes/hugo-theme-terminal/.husky/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
_
|
4
themes/hugo-theme-terminal/.husky/pre-push
Executable file
4
themes/hugo-theme-terminal/.husky/pre-push
Executable file
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
. "$(dirname "$0")/_/husky.sh"
|
||||
|
||||
yarn build && git add . && git commit --amend --no-edit
|
12
themes/hugo-theme-terminal/.prettierrc
Normal file
12
themes/hugo-theme-terminal/.prettierrc
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
"parser": "babel",
|
||||
"printWidth": 100,
|
||||
"trailingComma": "all",
|
||||
"arrowParens": "avoid",
|
||||
"overrides": [{
|
||||
"files": ".html",
|
||||
"options": {
|
||||
"parser": "html"
|
||||
}
|
||||
}]
|
||||
}
|
10
themes/hugo-theme-terminal/.stylelintrc.json
Normal file
10
themes/hugo-theme-terminal/.stylelintrc.json
Normal file
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"extends": [
|
||||
"stylelint-config-standard-scss",
|
||||
"stylelint-config-prettier-scss"
|
||||
],
|
||||
"rules": {
|
||||
"max-empty-lines": 1
|
||||
}
|
||||
}
|
||||
|
25
themes/hugo-theme-terminal/COMMUNITY-FEATURES.md
Normal file
25
themes/hugo-theme-terminal/COMMUNITY-FEATURES.md
Normal file
|
@ -0,0 +1,25 @@
|
|||
# Community features
|
||||
|
||||
<!--
|
||||
Did a cool thing with the theme and want to share it with rest of the Hello Friend theme users? Jump in!
|
||||
|
||||
Please follow the template:
|
||||
|
||||
- **NAME_OF_THE_FEATURE** (LINK TO YOUR FORK)
|
||||
- SHORT DESCRIPTION
|
||||
- SOMETHING ABOUT YOU (name and who you are / what you do / etc.)
|
||||
|
||||
eg:
|
||||
|
||||
- **Social media icons** (https://github.com/...)
|
||||
- This was a big missing feature of the theme. It will help your audience reach you over the internet.
|
||||
- John, a javascript developer.
|
||||
-->
|
||||
|
||||
- **Portfolio** (https://github.com/Louisload/hugo-theme-terminal-portfolio)
|
||||
- Allows you to create a portfolio page (or several). Supports icons and subsections.
|
||||
- Luís Rodrigues Alves (Louisload), a game dev and musician.
|
||||
|
||||
- **Single Page Website** (https://github.com/justinnuwin/hugo-theme-terminal)
|
||||
- A layout where the homepage can render lists of pages and the navigation menu can link to sections on the homepage.
|
||||
- Justin Nguyen, software and hardware developer.
|
20
themes/hugo-theme-terminal/LICENSE.md
Normal file
20
themes/hugo-theme-terminal/LICENSE.md
Normal file
|
@ -0,0 +1,20 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2019 panr
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
66
themes/hugo-theme-terminal/USERS.md
Normal file
66
themes/hugo-theme-terminal/USERS.md
Normal file
|
@ -0,0 +1,66 @@
|
|||
# Meet the users of Terminal theme!
|
||||
|
||||
- https://xicode.se **magistern** (Teacher)
|
||||
- https://devmaster64.com **devmaster64** (Software Developer)
|
||||
- https://calloc.net **Vaibhav Yenamandra** (Software Engineer)
|
||||
- https://potatofrom.space **Kevin Liu** (Software)
|
||||
- https://horochx.org **horochx** (Software Developer)
|
||||
- https://feng.si **Si Feng** (Software Engineer)
|
||||
- https://ben-on-vms.com **Benedikt Frenzel** (Technical Support Engineer)
|
||||
- https://johngazzini.com **John Gazzini** (Software Engineer)
|
||||
- https://tears.io/ **Alex** (SRE)
|
||||
- https://ayushkarn.me/ **Ayush Karn** (Student Developer)
|
||||
- https://zaine.me **Amine Zaine** (Cloud Engineer)
|
||||
- https://notes.dmaitre.phyip3.dur.ac.uk/computing-club/ **Ryan Moodie** (Physics PhD student)
|
||||
- https://lunar.computer **Lunar Computer** (DevOps Engineer)
|
||||
- https://naxxfish.net **Chris Roberts** (Broadcast Systems Engineer)
|
||||
- https://andreacaravano.net **Andrea Caravano** (Student)
|
||||
- https://qbunt.com **Jeremy Bunting** (Software Engineer)
|
||||
- https://smeik.org **Smeik** (Embedded Developer)
|
||||
- https://code.willstocks.co.uk **Will Stocks** (Blogger & Developer)
|
||||
- https://blog.vnandag.me **Nanda Gopal** (Student Developer)
|
||||
- https://m47r1x.github.io **Neo** (Citizen of Zion)
|
||||
- https://bgameiro.me/ **Bernardo Gameiro** (Engineer Physicist student)
|
||||
- https://return-to-libc.com/ **elraro** (Cyber Security Specialist)
|
||||
- https://pablart.com/ **Pablo Diaz-Gutierrez** (Software Engineer, General Tinkerer)
|
||||
- https://monocle.rpod.club/ **classx** (DevOps Engineer)
|
||||
- https://erisianrite.com/ **ErisianRite** (Coding, Engineering, Tools for Thought)
|
||||
- https://isaes.com.tr/ **Isa Es** (Software Engineer)
|
||||
- https://blog.m5e.de/ **Christoph Miksche** (Software Developer)
|
||||
- https://mpostument.com/ **Maksym Postument** (DevOps Engineer)
|
||||
- https://mathiejosh.xyz **Josh Mathie** (Electrical Engineering Technology Student/Sales and Engineering Tech)
|
||||
- https://yuji.ne.jp/ **YUJI** (Student & Software Developer)
|
||||
- https://blog.puvvadi.me **KD Puvvadi** (Software Dev & Cloud Orchestrator)
|
||||
- https://hidden.land/ **Louisload** (Game Developer & Musician)
|
||||
- https://linuxbase.nl **Michael Trip** (DevOps Engineer)
|
||||
- https://blog.sethforprivacy.com **Seth For Privacy** (Security, privacy, and cryptocurrency writer, podcaster)
|
||||
- https://thesprawl.city **crish** (Software and stuff)
|
||||
- https://justinnuwin.com **Justin Nguyen** (Software & Hardware Developer)
|
||||
- https://blog.woosal.com/ **Vusal Ismayilov** (Computer Engineering Student)
|
||||
- https://itsembedded.com/ **Norbert Kremeris** (digital logic design and verification engineer)
|
||||
- https://nereuxofficial.github.io **Nereuxofficial** (Software Developer & Student)
|
||||
- https://biplav.xyz **Biplav's Blog** (Student)
|
||||
- https://santiago.wtf **Nicholas Santiago** (DevOps Engineer)
|
||||
- https://2200g.github.io/ **2200g** (Blogger/Student)
|
||||
- https://they.mint.lgbt **Joey Aliaga** (Software Developer & Student)
|
||||
- https://tatewilhelm.me **Tate Wilhelm** (Student, Programmer & Tinkerer)
|
||||
- https://mikefoden.com **Mike Foden** (Software Developer)
|
||||
- https://undemalum.github.io/portfolio/ **Mateusz Konat** (Student)
|
||||
- https://ku0hn.radio **Ben Kuhn** (Ham Radio Operator, InfoSec Engineer, Tinkerer)
|
||||
- https://www.grumpymetalguy.com **GrumpyMetalGuy** (General Grumper and Developer)
|
||||
- https://blog.jontes.page **Jonte** (general tech geek)
|
||||
- https://nazdarthegame.com/ **Michal Skoula** (Software Developer)
|
||||
- https://1mup.myorange.house **Antonio Garosi** (Street art gallery)
|
||||
- https://kitchvx.github.io **Nathan Kitching** (IT Student)
|
||||
- https://dgood.win **Dom Goodwin** (Platform Engineer)
|
||||
- https://sir-photch.xyz **Sir-Photch** (ComSci-student. German Blog)
|
||||
- https://drewmorris.info **Drew Morris** (Mathematician && Computer Scientist)
|
||||
- https://blog.darkiiiiiice.com **MarioMang** (Software Developer)
|
||||
|
||||
<!--
|
||||
TEMPLATE:
|
||||
|
||||
- https://radoslawkoziel.pl **Radek Kozieł** (Software Designer and Developer)
|
||||
|
||||
-->
|
||||
|
14
themes/hugo-theme-terminal/archetypes/posts.md
Normal file
14
themes/hugo-theme-terminal/archetypes/posts.md
Normal file
|
@ -0,0 +1,14 @@
|
|||
+++
|
||||
title = "{{ replace .TranslationBaseName "-" " " | title }}"
|
||||
date = "{{ .Date }}"
|
||||
author = ""
|
||||
authorTwitter = "" #do not include @
|
||||
cover = ""
|
||||
tags = ["", ""]
|
||||
keywords = ["", ""]
|
||||
description = ""
|
||||
showFullContent = false
|
||||
readingTime = false
|
||||
hideComments = false
|
||||
color = "" #color from the theme settings
|
||||
+++
|
95
themes/hugo-theme-terminal/assets/css/buttons.scss
Normal file
95
themes/hugo-theme-terminal/assets/css/buttons.scss
Normal file
|
@ -0,0 +1,95 @@
|
|||
.button-container {
|
||||
display: table;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
button,
|
||||
.button,
|
||||
a.button {
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 8px 18px;
|
||||
margin: 5px 0;
|
||||
text-decoration: none;
|
||||
text-align: center;
|
||||
border-radius: 8;
|
||||
border: 1px solid $accent;
|
||||
background: $accent;
|
||||
color: $background;
|
||||
font: inherit;
|
||||
font-weight: bold;
|
||||
appearance: none;
|
||||
cursor: pointer;
|
||||
outline: none;
|
||||
|
||||
&:hover {
|
||||
background: transparentize($accent, .1);
|
||||
}
|
||||
|
||||
/* variants */
|
||||
|
||||
&.outline {
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
padding: 8px 18px;
|
||||
|
||||
:hover {
|
||||
transform: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
&.link {
|
||||
background: none;
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
/* sizes */
|
||||
|
||||
&.small {
|
||||
font-size: .8rem;
|
||||
}
|
||||
|
||||
&.wide {
|
||||
min-width: 200px;
|
||||
padding: 14px 24px;
|
||||
}
|
||||
}
|
||||
|
||||
a.read-more,
|
||||
a.read-more:hover,
|
||||
a.read-more:active {
|
||||
display: inline-flex;
|
||||
border: none;
|
||||
color: $accent;
|
||||
background: none;
|
||||
box-shadow: none;
|
||||
padding: 0;
|
||||
margin: 20px 0;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.code-toolbar {
|
||||
margin-bottom: 20px;
|
||||
|
||||
.toolbar-item a {
|
||||
position: relative;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 3px 8px;
|
||||
margin-bottom: 5px;
|
||||
text-decoration: none;
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
border-radius: 8px;
|
||||
border: 1px solid transparent;
|
||||
appearance: none;
|
||||
cursor: pointer;
|
||||
outline: none;
|
||||
}
|
||||
}
|
84
themes/hugo-theme-terminal/assets/css/code.scss
Normal file
84
themes/hugo-theme-terminal/assets/css/code.scss
Normal file
|
@ -0,0 +1,84 @@
|
|||
.collapsable-code {
|
||||
$border-color: mix($accent, #999, 90%);
|
||||
|
||||
position: relative;
|
||||
width: 100%;
|
||||
margin: 40px 0;
|
||||
|
||||
input[type="checkbox"] {
|
||||
position: absolute;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
input[type="checkbox"]:checked {
|
||||
~ pre,
|
||||
~ .code-toolbar pre {
|
||||
height: 0;
|
||||
padding: 0;
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
~ .code-toolbar {
|
||||
padding: 0;
|
||||
border-top: none;
|
||||
|
||||
.toolbar {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
~ label .collapsable-code__toggle:after {
|
||||
content: attr(data-label-expand);
|
||||
}
|
||||
}
|
||||
|
||||
label {
|
||||
position: relative;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
min-width: 30px;
|
||||
min-height: 30px;
|
||||
margin: 0;
|
||||
border-bottom: 1px solid $border-color;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
&__title {
|
||||
flex: 1;
|
||||
color: $accent;
|
||||
padding: 3px 10px;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
&__language {
|
||||
color: $accent;
|
||||
border: 1px solid $border-color;
|
||||
border-bottom: none;
|
||||
text-transform: uppercase;
|
||||
padding: 3px 10px;
|
||||
}
|
||||
|
||||
&__toggle {
|
||||
color: $accent;
|
||||
font-size: 16px;
|
||||
padding: 3px 10px;
|
||||
|
||||
&:after {
|
||||
content: attr(data-label-collapse);
|
||||
}
|
||||
}
|
||||
|
||||
pre {
|
||||
margin-top: 0;
|
||||
|
||||
&::first-line {
|
||||
line-height: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.code-toolbar {
|
||||
margin: 0;
|
||||
}
|
||||
}
|
1
themes/hugo-theme-terminal/assets/css/color/blue.scss
Normal file
1
themes/hugo-theme-terminal/assets/css/color/blue.scss
Normal file
|
@ -0,0 +1 @@
|
|||
$accent: #23B0FF;
|
1
themes/hugo-theme-terminal/assets/css/color/green.scss
Normal file
1
themes/hugo-theme-terminal/assets/css/color/green.scss
Normal file
|
@ -0,0 +1 @@
|
|||
$accent: #78E2A0;
|
1
themes/hugo-theme-terminal/assets/css/color/orange.scss
Normal file
1
themes/hugo-theme-terminal/assets/css/color/orange.scss
Normal file
|
@ -0,0 +1 @@
|
|||
$accent: #FFA86A;
|
1
themes/hugo-theme-terminal/assets/css/color/pink.scss
Normal file
1
themes/hugo-theme-terminal/assets/css/color/pink.scss
Normal file
|
@ -0,0 +1 @@
|
|||
$accent: #EE72F1;
|
1
themes/hugo-theme-terminal/assets/css/color/red.scss
Normal file
1
themes/hugo-theme-terminal/assets/css/color/red.scss
Normal file
|
@ -0,0 +1 @@
|
|||
$accent: #FF6266;
|
15
themes/hugo-theme-terminal/assets/css/font.scss
Normal file
15
themes/hugo-theme-terminal/assets/css/font.scss
Normal file
|
@ -0,0 +1,15 @@
|
|||
@font-face {
|
||||
font-display: swap;
|
||||
font-family: 'Fira Code';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: url("../fonts/FiraCode-Regular.woff") format("woff");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-display: swap;
|
||||
font-family: 'Fira Code';
|
||||
font-style: normal;
|
||||
font-weight: 800;
|
||||
src: url("../fonts/FiraCode-Bold.woff") format("woff");
|
||||
}
|
44
themes/hugo-theme-terminal/assets/css/footer.scss
Normal file
44
themes/hugo-theme-terminal/assets/css/footer.scss
Normal file
|
@ -0,0 +1,44 @@
|
|||
.footer {
|
||||
padding: 40px 0;
|
||||
flex-grow: 0;
|
||||
opacity: .5;
|
||||
|
||||
&__inner {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin: 0;
|
||||
width: 760px;
|
||||
max-width: 100%;
|
||||
|
||||
@media ($tablet) {
|
||||
flex-direction: column;
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.copyright {
|
||||
display: flex;
|
||||
flex-flow: row wrap;
|
||||
flex: 1;
|
||||
align-items: center;
|
||||
font-size: 1rem;
|
||||
justify-content: center;
|
||||
|
||||
&--user {
|
||||
margin: auto;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
& > *:first-child:not(:only-child) {
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
span {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
}
|
43
themes/hugo-theme-terminal/assets/css/form.scss
Normal file
43
themes/hugo-theme-terminal/assets/css/form.scss
Normal file
|
@ -0,0 +1,43 @@
|
|||
input, textarea, select {
|
||||
background: transparent;
|
||||
color: $accent;
|
||||
border: 1px solid $accent;
|
||||
border-radius: 0;
|
||||
padding: 10px;
|
||||
margin: 5px 0;
|
||||
font: inherit;
|
||||
appearance: none;
|
||||
|
||||
&:focus, :active {
|
||||
border-color: $color;
|
||||
outline: 1px solid $color;
|
||||
}
|
||||
|
||||
&:active {
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
select {
|
||||
background: $background;
|
||||
|
||||
option {
|
||||
background: $background;
|
||||
}
|
||||
}
|
||||
|
||||
::placeholder {
|
||||
color: transparentize($accent, .5);
|
||||
}
|
||||
|
||||
input {
|
||||
&[type="checkbox"] {
|
||||
vertical-align: middle;
|
||||
padding: 10px;
|
||||
box-shadow: inset 0 0 0 3px $background;
|
||||
|
||||
&:checked {
|
||||
background: $accent;
|
||||
}
|
||||
}
|
||||
}
|
6
themes/hugo-theme-terminal/assets/css/gist.scss
Normal file
6
themes/hugo-theme-terminal/assets/css/gist.scss
Normal file
|
@ -0,0 +1,6 @@
|
|||
body .gist .blob-num /* line numbers */,
|
||||
body .gist .blob-code-inner
|
||||
{
|
||||
border: none;
|
||||
}
|
||||
|
34
themes/hugo-theme-terminal/assets/css/header.scss
Normal file
34
themes/hugo-theme-terminal/assets/css/header.scss
Normal file
|
@ -0,0 +1,34 @@
|
|||
.header {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
position: relative;
|
||||
|
||||
@media print {
|
||||
display: none;
|
||||
}
|
||||
|
||||
&__inner {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
&__logo {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
|
||||
&:after {
|
||||
content: '';
|
||||
background: repeating-linear-gradient(90deg, $accent, $accent 2px, transparent 0, transparent 10px);
|
||||
display: block;
|
||||
width: 100%;
|
||||
right: 10px;
|
||||
}
|
||||
|
||||
a {
|
||||
flex: 0 0 auto;
|
||||
max-width: 100%;
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
8
themes/hugo-theme-terminal/assets/css/logo.scss
Normal file
8
themes/hugo-theme-terminal/assets/css/logo.scss
Normal file
|
@ -0,0 +1,8 @@
|
|||
.logo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
text-decoration: none;
|
||||
background: $accent;
|
||||
color: black;
|
||||
padding: 5px 10px;
|
||||
}
|
346
themes/hugo-theme-terminal/assets/css/main.scss
Normal file
346
themes/hugo-theme-terminal/assets/css/main.scss
Normal file
|
@ -0,0 +1,346 @@
|
|||
html {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
*,
|
||||
*:before,
|
||||
*:after {
|
||||
box-sizing: inherit;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-family: 'Fira Code', Monaco, Consolas, Ubuntu Mono, monospace;
|
||||
font-size: 1rem;
|
||||
line-height: 1.54;
|
||||
letter-spacing: -0.02em;
|
||||
background-color: $background;
|
||||
color: $color;
|
||||
text-rendering: optimizeLegibility;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
font-feature-settings: "liga", "tnum", "zero", "ss01", "locl";
|
||||
font-variant-ligatures: contextual;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
-webkit-text-size-adjust: 100%;
|
||||
|
||||
@media ($phone) {
|
||||
font-size: 1rem;
|
||||
}
|
||||
}
|
||||
|
||||
.headings--one-size {
|
||||
h1,
|
||||
h2,
|
||||
h3,
|
||||
h4,
|
||||
h5,
|
||||
h6 {
|
||||
line-height: 1.3;
|
||||
|
||||
&:not(first-child) {
|
||||
margin-top: 40px;
|
||||
}
|
||||
}
|
||||
|
||||
h1,
|
||||
h2,
|
||||
h3 {
|
||||
font-size: 1.4rem;
|
||||
}
|
||||
|
||||
h4,
|
||||
h5,
|
||||
h6 {
|
||||
font-size: 1.2rem;
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: inherit;
|
||||
|
||||
/* Waiting for a better times... */
|
||||
/* &:has(code) {
|
||||
text-decoration-color: $accent;
|
||||
} */
|
||||
}
|
||||
|
||||
img {
|
||||
display: block;
|
||||
max-width: 100%;
|
||||
|
||||
&.left {
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
&.center {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
&.right {
|
||||
margin-left: auto;
|
||||
}
|
||||
}
|
||||
|
||||
p {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
figure {
|
||||
display: table;
|
||||
max-width: 100%;
|
||||
margin: 25px 0;
|
||||
|
||||
&.left {
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
&.center {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
&.right {
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
figcaption {
|
||||
font-size: 14px;
|
||||
padding: 5px 10px;
|
||||
margin-top: 5px;
|
||||
background: $accent;
|
||||
color: $background;
|
||||
/* opacity: .8; */
|
||||
|
||||
&.left {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
&.center {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
&.right {
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
code, kbd {
|
||||
font-family: 'Fira Code', Monaco, Consolas, Ubuntu Mono, monospace !important;
|
||||
font-feature-settings: normal;
|
||||
background: transparentize($accent, .8);
|
||||
color: $accent;
|
||||
padding: 1px 6px;
|
||||
margin: 0 2px;
|
||||
font-size: .95rem;
|
||||
|
||||
code, kbd {
|
||||
background: transparent;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
|
||||
pre {
|
||||
background: transparent !important;
|
||||
padding: 20px 10px;
|
||||
margin: 40px 0;
|
||||
font-size: .95rem !important;
|
||||
overflow: auto;
|
||||
border-top: 1px solid rgba(255, 255, 255, .1);
|
||||
border-bottom: 1px solid rgba(255, 255, 255, .1);
|
||||
|
||||
+ pre {
|
||||
border-top: 0;
|
||||
margin-top: -40px;
|
||||
}
|
||||
|
||||
@media ($phone) {
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
code {
|
||||
background: none !important;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-size: inherit;
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
blockquote {
|
||||
border-top: 1px solid $accent;
|
||||
border-bottom: 1px solid $accent;
|
||||
margin: 40px 0;
|
||||
padding: 25px;
|
||||
|
||||
@media ($phone) {
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
p:first-of-type {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
p:last-of-type {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
p {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
p:first-of-type:before {
|
||||
content: '>';
|
||||
display: block;
|
||||
position: absolute;
|
||||
left: -25px;
|
||||
color: $accent;
|
||||
}
|
||||
|
||||
&.twitter-tweet {
|
||||
position: relative;
|
||||
background: transparentize($accent, .9);
|
||||
font: inherit;
|
||||
color: inherit;
|
||||
border: 1px solid $accent;
|
||||
padding-top: 60px;
|
||||
|
||||
p:before {
|
||||
content: '';
|
||||
}
|
||||
|
||||
&:before {
|
||||
content: '> From Twitter:';
|
||||
position: absolute;
|
||||
top: 20px;
|
||||
color: $accent;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
a {
|
||||
color: $accent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
table {
|
||||
table-layout: auto;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
margin: 40px 0;
|
||||
}
|
||||
|
||||
table,
|
||||
th,
|
||||
td {
|
||||
border: 1px dashed $accent;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
th {
|
||||
color: $accent;
|
||||
}
|
||||
|
||||
ul,
|
||||
ol {
|
||||
margin-left: 22px;
|
||||
padding: 0;
|
||||
|
||||
li {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
@media ($phone) {
|
||||
margin-left: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
ol {
|
||||
list-style: none;
|
||||
counter-reset: li;
|
||||
|
||||
> li {
|
||||
counter-increment: li;
|
||||
|
||||
&:before {
|
||||
content: counter(li);
|
||||
position: absolute;
|
||||
right: calc(100% + 10px);
|
||||
color: $accent;
|
||||
display: inline-block;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
> ol {
|
||||
margin-left: 38px;
|
||||
|
||||
> li {
|
||||
counter-increment: li;
|
||||
|
||||
&:before {
|
||||
content: counters(li, ".") " ";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mark {
|
||||
background: $accent;
|
||||
color: $background;
|
||||
}
|
||||
|
||||
.container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 40px;
|
||||
max-width: 864px;
|
||||
min-height: 100vh;
|
||||
border-right: 1px solid rgba(255, 255, 255, 0.1);
|
||||
|
||||
&.full,
|
||||
&.center {
|
||||
border: none;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
&.full {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
@media ($phone) {
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
@media print {
|
||||
display: initial;
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
@media print {
|
||||
display: initial;
|
||||
}
|
||||
}
|
||||
|
||||
hr {
|
||||
width: 100%;
|
||||
border: none;
|
||||
background: $border-color;
|
||||
height: 1px;
|
||||
}
|
||||
|
||||
.hidden {
|
||||
display: none;
|
||||
}
|
||||
|
||||
sup {
|
||||
line-height: 0;
|
||||
}
|
157
themes/hugo-theme-terminal/assets/css/menu.scss
Normal file
157
themes/hugo-theme-terminal/assets/css/menu.scss
Normal file
|
@ -0,0 +1,157 @@
|
|||
@mixin menu {
|
||||
display: none;
|
||||
flex-direction: column;
|
||||
$shadow-color: transparentize($background, .2);
|
||||
$shadow: 0 10px $shadow-color, -10px 10px $shadow-color, 10px 10px $shadow-color;
|
||||
position: absolute;
|
||||
background: $background;
|
||||
box-shadow: $shadow;
|
||||
color: white;
|
||||
border: 2px solid;
|
||||
margin: 0;
|
||||
padding: 10px;
|
||||
top: 10px;
|
||||
left: 0;
|
||||
list-style: none;
|
||||
z-index: 99;
|
||||
}
|
||||
|
||||
@mixin header-menu-trigger {
|
||||
color: $accent;
|
||||
border: 2px solid;
|
||||
margin-left: 10px;
|
||||
height: 100%;
|
||||
padding: 3px 8px;
|
||||
margin-bottom: 0 !important;
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.navigation-menu {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
justify-content: space-between;
|
||||
margin: 20px 1px;
|
||||
|
||||
@media ($phone) {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
&__inner {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-wrap: wrap;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
> li {
|
||||
flex: 0 0 auto;
|
||||
margin-bottom: 10px;
|
||||
white-space: nowrap;
|
||||
|
||||
&:not(:last-of-type) {
|
||||
margin-right: 20px;
|
||||
}
|
||||
}
|
||||
|
||||
@media ($phone) {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
padding: 0;
|
||||
|
||||
li {
|
||||
margin: 0;
|
||||
padding: 5px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.spacer {
|
||||
flex-grow: 1 !important;
|
||||
}
|
||||
}
|
||||
|
||||
.menu {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
position: relative;
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
|
||||
&__trigger {
|
||||
margin-right: 0 !important;
|
||||
color: $accent;
|
||||
user-select: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
&__dropdown {
|
||||
@include menu;
|
||||
|
||||
.open & {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
> li {
|
||||
flex: 0 0 auto;
|
||||
|
||||
&:not(:last-of-type) {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
a {
|
||||
display: flex;
|
||||
padding: 5px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&--desktop {
|
||||
@media ($phone) {
|
||||
display: none
|
||||
}
|
||||
}
|
||||
|
||||
&--mobile {
|
||||
.menu__trigger {
|
||||
@include header-menu-trigger;
|
||||
display: none;
|
||||
|
||||
@media ($phone) {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
.menu__dropdown {
|
||||
@media ($phone) {
|
||||
left: auto;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
|
||||
li {
|
||||
flex: 0 0 auto;
|
||||
|
||||
&:not(:last-of-type) {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&--language-selector {
|
||||
.menu__trigger {
|
||||
@include header-menu-trigger;
|
||||
|
||||
@media ($phone) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.menu__dropdown {
|
||||
left: auto;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
}
|
87
themes/hugo-theme-terminal/assets/css/pagination.scss
Normal file
87
themes/hugo-theme-terminal/assets/css/pagination.scss
Normal file
|
@ -0,0 +1,87 @@
|
|||
.pagination {
|
||||
margin-top: 50px;
|
||||
|
||||
@media print {
|
||||
display: none;
|
||||
}
|
||||
|
||||
&__title {
|
||||
display: flex;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
margin: 100px 0 20px;
|
||||
|
||||
&-h {
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
padding: 5px 10px;
|
||||
background: $background;
|
||||
color: transparentize($color, .7);
|
||||
font-size: .8rem;
|
||||
text-transform: uppercase;
|
||||
text-decoration: none;
|
||||
letter-spacing: .1em;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
hr {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
margin-top: 15px;
|
||||
z-index: 0;
|
||||
}
|
||||
}
|
||||
|
||||
&__buttons {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex-flow: row wrap;
|
||||
gap: 10px;
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.button {
|
||||
position: relative;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 1rem;
|
||||
padding: 0;
|
||||
appearance: none;
|
||||
|
||||
@media($phone) {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
a {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
padding: 8px 16px;
|
||||
text-decoration: none;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
&__text {
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
&.next .button__icon {
|
||||
margin-left: 8px;
|
||||
}
|
||||
|
||||
&.previous .button__icon {
|
||||
margin-right: 8px;
|
||||
}
|
||||
}
|
136
themes/hugo-theme-terminal/assets/css/post.scss
Normal file
136
themes/hugo-theme-terminal/assets/css/post.scss
Normal file
|
@ -0,0 +1,136 @@
|
|||
.index-content {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.framed {
|
||||
border: 1px solid $accent;
|
||||
padding: 20px;
|
||||
|
||||
*:first-child {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
*:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.posts {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.post {
|
||||
width: 100%;
|
||||
text-align: left;
|
||||
margin: 20px auto;
|
||||
padding: 20px 0;
|
||||
|
||||
&:not(:last-of-type) {
|
||||
border-bottom: 1px solid $border-color;
|
||||
}
|
||||
|
||||
&-meta {
|
||||
font-size: 1rem;
|
||||
margin-bottom: 10px;
|
||||
color: transparentize($accent, .3);
|
||||
|
||||
& > *:not(:first-child) {
|
||||
&::before {
|
||||
content: "::";
|
||||
display: inline-block;
|
||||
margin: 0 8px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&-title {
|
||||
$border: 3px dotted $accent;
|
||||
position: relative;
|
||||
color: $accent;
|
||||
margin: 0 0 15px;
|
||||
padding-bottom: 15px;
|
||||
border-bottom: $border;
|
||||
|
||||
&:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: 2px;
|
||||
display: block;
|
||||
width: 100%;
|
||||
border-bottom: $border;
|
||||
}
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
|
||||
&-tags {
|
||||
display: block;
|
||||
margin-bottom: 20px;
|
||||
font-size: 1rem;
|
||||
opacity: .5;
|
||||
|
||||
a {
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
|
||||
&-content {
|
||||
margin-top: 30px;
|
||||
}
|
||||
|
||||
&-cover {
|
||||
border: 20px solid $accent;
|
||||
background: transparent;
|
||||
margin: 40px 0;
|
||||
padding: 20px;
|
||||
|
||||
@media ($phone) {
|
||||
padding: 10px;
|
||||
border-width: 10px;
|
||||
}
|
||||
}
|
||||
|
||||
ul {
|
||||
list-style: none;
|
||||
|
||||
li:not(:empty):before {
|
||||
content: '-';
|
||||
position: absolute;
|
||||
left: -20px;
|
||||
color: $accent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.post--regulation {
|
||||
h1 {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
h2 {
|
||||
justify-content: center;
|
||||
margin-bottom: 10px;
|
||||
|
||||
& + h2 {
|
||||
margin-top: -10px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.hanchor {
|
||||
color: transparentize($accent, .1);
|
||||
text-decoration: none;
|
||||
margin-left: 10px;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
h1:hover a, h2:hover a, h3:hover a, h4:hover a {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.footnotes {
|
||||
color: transparentize($color, .5);
|
||||
}
|
336
themes/hugo-theme-terminal/assets/css/prism.scss
Normal file
336
themes/hugo-theme-terminal/assets/css/prism.scss
Normal file
|
@ -0,0 +1,336 @@
|
|||
/* PrismJS 1.24.1
|
||||
https://prismjs.com/download.html#themes=prism-tomorrow&languages=markup+css+clike+javascript+actionscript+apacheconf+applescript+bash+c+csharp+cpp+cmake+coffeescript+csp+css-extras+diff+django+docker+elixir+elm+erlang+fsharp+flow+git+go+graphql+haml+handlebars+haskell+http+java+json+kotlin+latex+less+llvm+makefile+markdown+markup-templating+nasm+objectivec+ocaml+perl+php+php-extras+powershell+processing+pug+python+r+jsx+tsx+reason+ruby+rust+sass+scss+scala+scheme+sql+stylus+swift+textile+toml+twig+typescript+vim+visual-basic+wasm+yaml&plugins=line-highlight+line-numbers+jsonp-highlight+highlight-keywords+command-line+toolbar+copy-to-clipboard */
|
||||
/**
|
||||
* prism.js tomorrow night eighties for JavaScript, CoffeeScript, CSS and HTML
|
||||
* Based on https://github.com/chriskempson/tomorrow-theme
|
||||
* @author Rose Pritchard
|
||||
*/
|
||||
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
color: #ccc;
|
||||
background: none;
|
||||
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
||||
font-size: 1em;
|
||||
text-align: left;
|
||||
white-space: pre;
|
||||
word-spacing: normal;
|
||||
word-break: normal;
|
||||
word-wrap: normal;
|
||||
line-height: 1.5;
|
||||
|
||||
-moz-tab-size: 4;
|
||||
-o-tab-size: 4;
|
||||
tab-size: 4;
|
||||
|
||||
-webkit-hyphens: none;
|
||||
-moz-hyphens: none;
|
||||
-ms-hyphens: none;
|
||||
hyphens: none;
|
||||
|
||||
}
|
||||
|
||||
/* Code blocks */
|
||||
pre[class*="language-"] {
|
||||
padding: 1em;
|
||||
margin: .5em 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
:not(pre) > code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
background: #2d2d2d;
|
||||
}
|
||||
|
||||
/* Inline code */
|
||||
:not(pre) > code[class*="language-"] {
|
||||
padding: .1em;
|
||||
border-radius: .3em;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.block-comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.token.punctuation {
|
||||
color: #ccc;
|
||||
}
|
||||
|
||||
.token.tag,
|
||||
.token.attr-name,
|
||||
.token.namespace,
|
||||
.token.deleted {
|
||||
color: #e2777a;
|
||||
}
|
||||
|
||||
.token.function-name {
|
||||
color: #6196cc;
|
||||
}
|
||||
|
||||
.token.boolean,
|
||||
.token.number,
|
||||
.token.function {
|
||||
color: #f08d49;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.class-name,
|
||||
.token.constant,
|
||||
.token.symbol {
|
||||
color: #f8c555;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.important,
|
||||
.token.atrule,
|
||||
.token.keyword,
|
||||
.token.builtin {
|
||||
color: #cc99cd;
|
||||
}
|
||||
|
||||
.token.string,
|
||||
.token.char,
|
||||
.token.attr-value,
|
||||
.token.regex,
|
||||
.token.variable {
|
||||
color: #7ec699;
|
||||
}
|
||||
|
||||
.token.operator,
|
||||
.token.entity,
|
||||
.token.url {
|
||||
color: #67cdcc;
|
||||
}
|
||||
|
||||
.token.important,
|
||||
.token.bold {
|
||||
font-weight: bold;
|
||||
}
|
||||
.token.italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.token.entity {
|
||||
cursor: help;
|
||||
}
|
||||
|
||||
.token.inserted {
|
||||
color: green;
|
||||
}
|
||||
|
||||
pre[data-line] {
|
||||
position: relative;
|
||||
padding: 1em 0 1em 3em;
|
||||
}
|
||||
|
||||
.line-highlight {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
padding: inherit 0;
|
||||
margin-top: 1em; /* Same as .prism’s padding-top */
|
||||
|
||||
background: hsla(24, 20%, 50%,.08);
|
||||
background: linear-gradient(to right, hsla(24, 20%, 50%,.1) 70%, hsla(24, 20%, 50%,0));
|
||||
|
||||
pointer-events: none;
|
||||
|
||||
line-height: inherit;
|
||||
white-space: pre;
|
||||
}
|
||||
|
||||
@media print {
|
||||
.line-highlight {
|
||||
/*
|
||||
* This will prevent browsers from replacing the background color with white.
|
||||
* It's necessary because the element is layered on top of the displayed code.
|
||||
*/
|
||||
-webkit-print-color-adjust: exact;
|
||||
color-adjust: exact;
|
||||
}
|
||||
}
|
||||
|
||||
.line-highlight:before,
|
||||
.line-highlight[data-end]:after {
|
||||
content: attr(data-start);
|
||||
position: absolute;
|
||||
top: .4em;
|
||||
left: .6em;
|
||||
min-width: 1em;
|
||||
padding: 0 .5em;
|
||||
background-color: hsla(24, 20%, 50%,.4);
|
||||
color: hsl(24, 20%, 95%);
|
||||
font: bold 65%/1.5 sans-serif;
|
||||
text-align: center;
|
||||
vertical-align: .3em;
|
||||
border-radius: 999px;
|
||||
text-shadow: none;
|
||||
box-shadow: 0 1px white;
|
||||
}
|
||||
|
||||
.line-highlight[data-end]:after {
|
||||
content: attr(data-end);
|
||||
top: auto;
|
||||
bottom: .4em;
|
||||
}
|
||||
|
||||
.line-numbers .line-highlight:before,
|
||||
.line-numbers .line-highlight:after {
|
||||
content: none;
|
||||
}
|
||||
|
||||
pre[id].linkable-line-numbers span.line-numbers-rows {
|
||||
pointer-events: all;
|
||||
}
|
||||
pre[id].linkable-line-numbers span.line-numbers-rows > span:before {
|
||||
cursor: pointer;
|
||||
}
|
||||
pre[id].linkable-line-numbers span.line-numbers-rows > span:hover:before {
|
||||
background-color: rgba(128, 128, 128, .2);
|
||||
}
|
||||
|
||||
pre[class*="language-"].line-numbers {
|
||||
position: relative;
|
||||
padding-left: 3.8em;
|
||||
counter-reset: linenumber;
|
||||
}
|
||||
|
||||
pre[class*="language-"].line-numbers > code {
|
||||
position: relative;
|
||||
white-space: inherit;
|
||||
}
|
||||
|
||||
.line-numbers .line-numbers-rows {
|
||||
position: absolute;
|
||||
pointer-events: none;
|
||||
top: 0;
|
||||
font-size: 100%;
|
||||
left: -3.8em;
|
||||
width: 3em; /* works for line-numbers below 1000 lines */
|
||||
letter-spacing: -1px;
|
||||
border-right: 1px solid #999;
|
||||
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
|
||||
}
|
||||
|
||||
.line-numbers-rows > span {
|
||||
display: block;
|
||||
counter-increment: linenumber;
|
||||
}
|
||||
|
||||
.line-numbers-rows > span:before {
|
||||
content: counter(linenumber);
|
||||
color: #999;
|
||||
display: block;
|
||||
padding-right: 0.8em;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.command-line-prompt {
|
||||
border-right: 1px solid #999;
|
||||
display: block;
|
||||
float: left;
|
||||
font-size: 100%;
|
||||
letter-spacing: -1px;
|
||||
margin-right: 1em;
|
||||
pointer-events: none;
|
||||
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.command-line-prompt > span:before {
|
||||
color: #999;
|
||||
content: ' ';
|
||||
display: block;
|
||||
padding-right: 0.8em;
|
||||
}
|
||||
|
||||
.command-line-prompt > span[data-user]:before {
|
||||
content: "[" attr(data-user) "@" attr(data-host) "] $";
|
||||
}
|
||||
|
||||
.command-line-prompt > span[data-user="root"]:before {
|
||||
content: "[" attr(data-user) "@" attr(data-host) "] #";
|
||||
}
|
||||
|
||||
.command-line-prompt > span[data-prompt]:before {
|
||||
content: attr(data-prompt);
|
||||
}
|
||||
|
||||
div.code-toolbar {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar {
|
||||
position: absolute;
|
||||
top: .3em;
|
||||
right: .2em;
|
||||
transition: opacity 0.3s ease-in-out;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
div.code-toolbar:hover > .toolbar {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
/* Separate line b/c rules are thrown out if selector is invalid.
|
||||
IE11 and old Edge versions don't support :focus-within. */
|
||||
div.code-toolbar:focus-within > .toolbar {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar > .toolbar-item {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar > .toolbar-item > a {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar > .toolbar-item > button {
|
||||
background: none;
|
||||
border: 0;
|
||||
color: inherit;
|
||||
font: inherit;
|
||||
line-height: normal;
|
||||
overflow: visible;
|
||||
padding: 0;
|
||||
-webkit-user-select: none; /* for button */
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar > .toolbar-item > a,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > button,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > span {
|
||||
color: #bbb;
|
||||
font-size: .8em;
|
||||
padding: 0 .5em;
|
||||
background: #f5f2f0;
|
||||
background: rgba(224, 224, 224, 0.2);
|
||||
box-shadow: 0 2px 0 0 rgba(0,0,0,0.2);
|
||||
border-radius: .5em;
|
||||
}
|
||||
|
||||
div.code-toolbar > .toolbar > .toolbar-item > a:hover,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > a:focus,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > button:hover,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > button:focus,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > span:hover,
|
||||
div.code-toolbar > .toolbar > .toolbar-item > span:focus {
|
||||
color: inherit;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
19
themes/hugo-theme-terminal/assets/css/style.scss
Normal file
19
themes/hugo-theme-terminal/assets/css/style.scss
Normal file
|
@ -0,0 +1,19 @@
|
|||
@import "variables";
|
||||
|
||||
@import "font";
|
||||
@import "buttons";
|
||||
@import "form";
|
||||
|
||||
@import "header";
|
||||
@import "menu";
|
||||
@import "logo";
|
||||
@import "main";
|
||||
@import "post";
|
||||
@import "pagination";
|
||||
@import "footer";
|
||||
|
||||
@import "prism";
|
||||
@import "syntax";
|
||||
@import "code";
|
||||
@import "terms";
|
||||
@import "gist";
|
153
themes/hugo-theme-terminal/assets/css/syntax.scss
Normal file
153
themes/hugo-theme-terminal/assets/css/syntax.scss
Normal file
|
@ -0,0 +1,153 @@
|
|||
code.language-css,
|
||||
code.language-scss,
|
||||
.token.boolean,
|
||||
.token.string,
|
||||
.token.entity,
|
||||
.token.url,
|
||||
.language-css .token.string,
|
||||
.language-scss .token.string,
|
||||
.style .token.string,
|
||||
.token.attr-value,
|
||||
.token.keyword,
|
||||
.token.control,
|
||||
.token.directive,
|
||||
.token.statement,
|
||||
.token.regex,
|
||||
.token.atrule,
|
||||
.token.number,
|
||||
.token.inserted,
|
||||
.token.important {
|
||||
color: $accent !important;
|
||||
}
|
||||
|
||||
.token.tag-id,
|
||||
.token.atrule-id,
|
||||
.token.operator,
|
||||
.token.unit,
|
||||
.token.placeholder,
|
||||
.token.variable,
|
||||
.token.tag,
|
||||
.token.attr-name,
|
||||
.token.namespace,
|
||||
.token.deleted,
|
||||
.token.property,
|
||||
.token.class-name,
|
||||
.token.constant,
|
||||
.token.symbol {
|
||||
color: transparentize($accent, .3) !important;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.function,
|
||||
.token.function-name,
|
||||
.token.deleted,
|
||||
code.language-javascript,
|
||||
code.language-html,
|
||||
.command-line-prompt > span:before {
|
||||
color: mix($accent, #999, .9) !important;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.tag,
|
||||
.token.punctuation {
|
||||
color: white;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: rgba(255, 255, 255, .3) !important;
|
||||
}
|
||||
|
||||
.token.namespace {
|
||||
opacity: .7 !important;
|
||||
}
|
||||
|
||||
pre[data-line] {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
pre[class*="language-"] {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.line-highlight {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
background: transparentize(mix($accent, #999, 90%), .92);
|
||||
pointer-events: none;
|
||||
line-height: inherit;
|
||||
white-space: pre;
|
||||
}
|
||||
|
||||
.line-highlight:before,
|
||||
.line-highlight[data-end]:after {
|
||||
content: attr(data-start);
|
||||
position: absolute;
|
||||
/* top: .4em; */
|
||||
left: .6em;
|
||||
min-width: 1em;
|
||||
padding: 0 .5em;
|
||||
background-color: hsla(24, 20%, 50%, .4);
|
||||
color: hsl(24, 20%, 95%);
|
||||
font: bold 65%/1.5 sans-serif;
|
||||
text-align: center;
|
||||
vertical-align: .3em;
|
||||
border-radius: 999px;
|
||||
text-shadow: none;
|
||||
box-shadow: 0 1px white;
|
||||
}
|
||||
|
||||
.line-highlight[data-end]:after {
|
||||
content: attr(data-end);
|
||||
top: auto;
|
||||
bottom: .4em;
|
||||
}
|
||||
|
||||
.line-numbers .line-highlight:before,
|
||||
.line-numbers .line-highlight:after {
|
||||
content: none;
|
||||
}
|
||||
|
||||
.code-toolbar {
|
||||
$code-margin: 40px;
|
||||
position: relative;
|
||||
margin: $code-margin 0;
|
||||
padding: 20px;
|
||||
border: 1px solid rgba(255, 255, 255, .1);
|
||||
|
||||
+ .code-toolbar,
|
||||
+ .highlight,
|
||||
+ .highlight .code-toolbar {
|
||||
border-top: 0;
|
||||
margin-top: calc(-1 * $code-margin);
|
||||
}
|
||||
|
||||
pre, code {
|
||||
border: none;
|
||||
}
|
||||
|
||||
code {
|
||||
display: block;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
> .toolbar {
|
||||
button {
|
||||
font-size: .8em !important;
|
||||
background: hsla(0,0%,87.8%,.2) !important;
|
||||
color: #bbb !important;
|
||||
box-shadow: 0 2px 0 0 rgba(0,0,0,.2) !important;
|
||||
border-radius: 0 !important;
|
||||
margin: 6px !important;
|
||||
padding: 10px !important;
|
||||
user-select:none
|
||||
}
|
||||
}
|
||||
}
|
22
themes/hugo-theme-terminal/assets/css/terms.scss
Normal file
22
themes/hugo-theme-terminal/assets/css/terms.scss
Normal file
|
@ -0,0 +1,22 @@
|
|||
.terms {
|
||||
h3 {
|
||||
font-size: initial;
|
||||
}
|
||||
|
||||
ul {
|
||||
list-style: none;
|
||||
|
||||
li {
|
||||
a {
|
||||
color: $accent;
|
||||
}
|
||||
}
|
||||
|
||||
li:not(:empty):before {
|
||||
content: '-';
|
||||
position: absolute;
|
||||
left: -20px;
|
||||
color: $accent;
|
||||
}
|
||||
}
|
||||
}
|
8
themes/hugo-theme-terminal/assets/css/variables.scss
Normal file
8
themes/hugo-theme-terminal/assets/css/variables.scss
Normal file
|
@ -0,0 +1,8 @@
|
|||
/* COLOR VARIABLES */
|
||||
$background: mix($accent, #1D1E28, 2%);
|
||||
$color: white;
|
||||
$border-color: rgba(255, 255, 255, .1);
|
||||
|
||||
/* MEDIA QUERIES */
|
||||
$phone: "max-width: 684px";
|
||||
$tablet: "max-width: 900px";
|
44
themes/hugo-theme-terminal/assets/js/menu.js
Normal file
44
themes/hugo-theme-terminal/assets/js/menu.js
Normal file
|
@ -0,0 +1,44 @@
|
|||
const container = document.querySelector(".container");
|
||||
const allMenus = document.querySelectorAll(".menu");
|
||||
|
||||
// Hide menus on body click
|
||||
document.body.addEventListener("click", () => {
|
||||
allMenus.forEach(menu => {
|
||||
if (menu.classList.contains("open")) {
|
||||
menu.classList.remove("open");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
// Reset menus on resize
|
||||
window.addEventListener("resize", () => {
|
||||
allMenus.forEach(menu => {
|
||||
menu.classList.remove("open");
|
||||
});
|
||||
});
|
||||
|
||||
// Handle desktop menu
|
||||
allMenus.forEach(menu => {
|
||||
const trigger = menu.querySelector(".menu__trigger");
|
||||
const dropdown = menu.querySelector(".menu__dropdown");
|
||||
|
||||
trigger.addEventListener("click", e => {
|
||||
e.stopPropagation();
|
||||
|
||||
if (menu.classList.contains("open")) {
|
||||
menu.classList.remove("open");
|
||||
} else {
|
||||
// Close all menus...
|
||||
allMenus.forEach(m => m.classList.remove("open"));
|
||||
// ...before opening the current one
|
||||
menu.classList.add("open");
|
||||
}
|
||||
|
||||
if (dropdown.getBoundingClientRect().right > container.getBoundingClientRect().right) {
|
||||
dropdown.style.left = "auto";
|
||||
dropdown.style.right = 0;
|
||||
}
|
||||
});
|
||||
|
||||
dropdown.addEventListener("click", e => e.stopPropagation());
|
||||
});
|
80
themes/hugo-theme-terminal/assets/js/prism.js
Normal file
80
themes/hugo-theme-terminal/assets/js/prism.js
Normal file
File diff suppressed because one or more lines are too long
18
themes/hugo-theme-terminal/babel.config.js
Normal file
18
themes/hugo-theme-terminal/babel.config.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
module.exports = function(api) {
|
||||
api.cache(true);
|
||||
|
||||
const presets = [
|
||||
[
|
||||
"@babel/preset-env",
|
||||
{
|
||||
targets: "last 2 versions, >1%, not dead",
|
||||
},
|
||||
],
|
||||
];
|
||||
const plugins = [];
|
||||
|
||||
return {
|
||||
presets,
|
||||
plugins,
|
||||
};
|
||||
};
|
4
themes/hugo-theme-terminal/config.toml
Normal file
4
themes/hugo-theme-terminal/config.toml
Normal file
|
@ -0,0 +1,4 @@
|
|||
[module]
|
||||
[module.hugoVersion]
|
||||
extended = true
|
||||
min = '0.90.0'
|
35
themes/hugo-theme-terminal/exampleSite/config.toml
Normal file
35
themes/hugo-theme-terminal/exampleSite/config.toml
Normal file
|
@ -0,0 +1,35 @@
|
|||
baseurl = "https://example.com/"
|
||||
languageCode = "en-us"
|
||||
theme = "hugo-theme-terminal"
|
||||
paginate = 5
|
||||
|
||||
[params]
|
||||
contentTypeName = "posts"
|
||||
themeColor = "orange"
|
||||
showMenuItems = 2
|
||||
fullWidthTheme = false
|
||||
centerTheme = false
|
||||
|
||||
[languages]
|
||||
[languages.en]
|
||||
title = "Terminal"
|
||||
subtitle = "A simple, retro theme for Hugo"
|
||||
keywords = ""
|
||||
copyright = ""
|
||||
menuMore = "Show more"
|
||||
readMore = "Read more"
|
||||
readOtherPosts = "Read other posts"
|
||||
|
||||
[languages.en.params.logo]
|
||||
logoText = "Terminal"
|
||||
logoHomeLink = "/"
|
||||
|
||||
[languages.en.menu]
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "about"
|
||||
name = "About"
|
||||
url = "/about"
|
||||
[[languages.en.menu.main]]
|
||||
identifier = "showcase"
|
||||
name = "Showcase"
|
||||
url = "/showcase"
|
22
themes/hugo-theme-terminal/exampleSite/content/about.md
Normal file
22
themes/hugo-theme-terminal/exampleSite/content/about.md
Normal file
|
@ -0,0 +1,22 @@
|
|||
+++
|
||||
title = "About"
|
||||
date = "2019-01-25"
|
||||
author = "Radek"
|
||||
+++
|
||||
|
||||
# Hi there
|
||||
|
||||
My name is Radek and I'm the author of this theme. I made it to help you present your ideas easier.
|
||||
|
||||
We all know how hard is to start something on the web, especially these days. You need to prepare a bunch of stuff, configure them and when that’s done — create the content.
|
||||
|
||||
This theme is pretty basic and covers all of the essentials. All you have to do is start typing!
|
||||
|
||||
The theme includes:
|
||||
|
||||
- **5 duotone themes**, depending on your preferences (orange, red, blue, green, pink)
|
||||
- [**Fira Code**](https://github.com/tonsky/FiraCode) as default monospaced font. It's gorgeous!
|
||||
- **really nice, custom duotone** syntax highlighting based on [**PrismJS**](https://prismjs.com)
|
||||
- mobile friendly layout
|
||||
|
||||
So, there you have it... enjoy!
|
|
@ -0,0 +1,18 @@
|
|||
+++
|
||||
title = "Hello Friend"
|
||||
date = "2019-01-25"
|
||||
author = "Lorem Ipsum"
|
||||
cover = "hello.jpg"
|
||||
description = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec interdum metus. Aenean rutrum ligula sodales ex auctor, sed tempus dui mollis. Curabitur ipsum dui, aliquet nec commodo at, tristique eget ante."
|
||||
+++
|
||||
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec interdum metus. Aenean rutrum ligula sodales ex auctor, sed tempus dui mollis. Curabitur ipsum dui, aliquet nec commodo at, tristique eget ante. **Donec quis dolor nec nunc mollis interdum vel in purus**. Sed vitae leo scelerisque, sollicitudin elit sed, congue ante. In augue nisl, vestibulum commodo est a, tristique porttitor est. Proin laoreet iaculis ornare. Nullam ut neque quam.
|
||||
|
||||
> Fusce pharetra suscipit orci nec tempor. Quisque vitae sem sit amet sem mollis consequat. Sed at imperdiet lorem. Vestibulum pharetra faucibus odio, ac feugiat tellus sollicitudin at. Pellentesque varius tristique mi imperdiet dapibus. Duis orci odio, sodales lacinia venenatis sit amet, feugiat et diam.
|
||||
|
||||
Sed a leo id risus venenatis vulputate non quis nulla. Aenean nisl quam, lacinia pulvinar orci sit amet, eleifend eleifend dui. Nulla tempor ligula leo, eu vehicula quam condimentum a. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla gravida tristique nunc sed semper. Morbi nec felis odio.
|
||||
|
||||
- Sed efficitur, lacus ac scelerisque pellentesque, lectus risus dignissim nisl, fermentum semper lectus diam eget lacus.
|
||||
- Nunc ornare purus enim, id eleifend mauris vestibulum volutpat.
|
||||
- Aenean facilisis ut ipsum condimentum ultrices.
|
||||
- Fusce sed metus vulputate, lobortis purus et, finibus purus. Suspendisse quis posuere lorem. Vivamus vulputate nec risus in pulvinar.
|
84
themes/hugo-theme-terminal/exampleSite/content/showcase.md
Normal file
84
themes/hugo-theme-terminal/exampleSite/content/showcase.md
Normal file
|
@ -0,0 +1,84 @@
|
|||
---
|
||||
title: "Showcase"
|
||||
date: "2018-07-18"
|
||||
author: "Hello Robot"
|
||||
---
|
||||
|
||||
## Header 2
|
||||
|
||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec interdum metus. Aenean rutrum ligula sodales ex auctor, sed tempus dui mollis. Curabitur ipsum dui, aliquet nec commodo at, tristique eget ante. **Donec quis dolor nec nunc mollis interdum vel in purus**. Sed vitae leo scelerisque, sollicitudin elit sed, congue ante. In augue nisl, vestibulum commodo est a, tristique porttitor est. Proin laoreet iaculis ornare. Nullam ut neque quam.
|
||||
|
||||
> Fusce pharetra suscipit orci nec tempor. Quisque vitae sem sit amet sem mollis consequat. Sed at imperdiet lorem. Vestibulum pharetra faucibus odio, ac feugiat tellus sollicitudin at. Pellentesque varius tristique mi imperdiet dapibus. Duis orci odio, sodales lacinia venenatis sit amet, feugiat et diam.
|
||||
|
||||
### Header 3
|
||||
|
||||
Nulla libero turpis, lacinia vitae cursus ut, auctor dictum nisl. Fusce varius felis nec sem ullamcorper, at convallis nisi vestibulum. Duis risus odio, porta sit amet placerat mollis, tincidunt non mauris. Suspendisse fringilla, `odio a dignissim pharetra`, est urna sollicitudin urna, eu scelerisque magna ex vitae tellus.
|
||||
|
||||
```css
|
||||
/* PostCSS code */
|
||||
|
||||
pre {
|
||||
background: #1a1a1d;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
font-size: 1rem;
|
||||
overflow: auto;
|
||||
|
||||
@media (--phone) {
|
||||
white-space: pre-wrap;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
code {
|
||||
background: none !important;
|
||||
color: #ccc;
|
||||
padding: 0;
|
||||
font-size: inherit;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
```js
|
||||
// JS code
|
||||
|
||||
const menuTrigger = document.querySelector('.menu-trigger')
|
||||
const menu = document.querySelector('.menu')
|
||||
const mobileQuery = getComputedStyle(document.body).getPropertyValue('--phoneWidth')
|
||||
const isMobile = () => window.matchMedia(mobileQuery).matches
|
||||
const isMobileMenu = () => {
|
||||
menuTrigger.classList.toggle('hidden', !isMobile())
|
||||
menu.classList.toggle('hidden', isMobile())
|
||||
}
|
||||
|
||||
isMobileMenu()
|
||||
|
||||
menuTrigger.addEventListener('click', () => menu.classList.toggle('hidden'))
|
||||
|
||||
window.addEventListener('resize', isMobileMenu)
|
||||
```
|
||||
|
||||
```html
|
||||
<!-- HTML code -->
|
||||
|
||||
<section id="main">
|
||||
<div>
|
||||
<h1 id="title">{{ .Title }}</h1>
|
||||
{{ range .Pages }}
|
||||
{{ .Render "summary"}}
|
||||
{{ end }}
|
||||
</div>
|
||||
</section>
|
||||
```
|
||||
|
||||
#### Header 4
|
||||
|
||||
Curabitur scelerisque felis viverra varius scelerisque. Ut enim libero, molestie gravida blandit at, mollis ornare tellus. Cras arcu mi, ultrices vel pulvinar vel, volutpat eu tortor. Nullam nec eros quis massa ultrices iaculis sed in metus. Praesent sollicitudin sem sit amet orci tempor gravida.
|
||||
|
||||
- Maecenas elementum vitae nibh vitae porttitor.
|
||||
- Aenean consequat, risus ut cursus placerat, arcu nulla sodales risus, ut molestie tellus tellus et dui.
|
||||
- Integer imperdiet turpis vitae lacus imperdiet, ut ornare ligula auctor. Integer in mi eu velit vehicula suscipit eget vulputate nulla.
|
||||
- Etiam vitae enim quis velit lobortis placerat a ut sem.
|
||||
- Curabitur lobortis ante sit amet orci pulvinar, sollicitudin viverra nunc accumsan.
|
||||
- Praesent fermentum orci quis leo facilisis posuere.
|
||||
|
||||
Aliquam erat volutpat. In hac habitasse platea dictumst. Nunc ut tincidunt mauris. Sed at gravida risus, id semper magna. Nullam vitae enim mattis, sodales neque non, pharetra elit. Cras sit amet sagittis augue, et finibus turpis. Ut tempus tincidunt diam vel pharetra. Nulla porttitor odio sit amet nulla scelerisque, quis aliquam mi imperdiet. Sed tincidunt dui vel tellus vestibulum rhoncus. Donec tempus ultrices velit.
|
BIN
themes/hugo-theme-terminal/exampleSite/static/img/hello.jpg
Normal file
BIN
themes/hugo-theme-terminal/exampleSite/static/img/hello.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 76 KiB |
3
themes/hugo-theme-terminal/go.mod
Normal file
3
themes/hugo-theme-terminal/go.mod
Normal file
|
@ -0,0 +1,3 @@
|
|||
module github.com/panr/hugo-theme-terminal/v3
|
||||
|
||||
go 1.19
|
BIN
themes/hugo-theme-terminal/images/screenshot.png
Normal file
BIN
themes/hugo-theme-terminal/images/screenshot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 438 KiB |
BIN
themes/hugo-theme-terminal/images/tn.png
Normal file
BIN
themes/hugo-theme-terminal/images/tn.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 168 KiB |
10
themes/hugo-theme-terminal/layouts/404.html
Normal file
10
themes/hugo-theme-terminal/layouts/404.html
Normal file
|
@ -0,0 +1,10 @@
|
|||
{{ define "main" }}
|
||||
<div class="post">
|
||||
<h1 class="post-title">404 — {{ $.Site.Params.missingContentMessage | default "Page not found..." }}</h1>
|
||||
|
||||
<div class="post-content">
|
||||
<a href="{{ "/" | absURL }}">{{ $.Site.Params.missingBackButtonLabel | default "Back to home page" }} →</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{{ end }}
|
27
themes/hugo-theme-terminal/layouts/_default/baseof.html
Normal file
27
themes/hugo-theme-terminal/layouts/_default/baseof.html
Normal file
|
@ -0,0 +1,27 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="{{ $.Site.Language }}">
|
||||
<head>
|
||||
{{ block "title" . }}
|
||||
<title>{{ if .IsHome }}{{ $.Site.Title }}{{ else }}{{ .Title }} :: {{ $.Site.Title }}{{ end }}</title>
|
||||
{{ end }}
|
||||
{{ partial "head.html" . }}
|
||||
</head>
|
||||
<body class="{{- ( or .Params.color $.Site.Params.ThemeColor ) -}}">
|
||||
{{ $container := cond ($.Site.Params.FullWidthTheme | default false) "container full" (cond ($.Site.Params.CenterTheme | default false) "container center" "container") }}
|
||||
|
||||
<div class="{{- $container -}}{{- cond ($.Site.Params.oneHeadingSize | default true) " headings--one-size" "" }}">
|
||||
|
||||
{{ partial "header.html" . }}
|
||||
|
||||
<div class="content">
|
||||
{{ block "main" . }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ block "footer" . }}
|
||||
{{ partial "footer.html" . }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
66
themes/hugo-theme-terminal/layouts/_default/index.html
Normal file
66
themes/hugo-theme-terminal/layouts/_default/index.html
Normal file
|
@ -0,0 +1,66 @@
|
|||
{{ define "main" }}
|
||||
{{ if .Content }}
|
||||
<div class="index-content {{ if .Params.framed -}}framed{{- end -}}">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<div class="posts">
|
||||
{{ $isntDefault := not (or (eq (trim $.Site.Params.contentTypeName " ") "posts") (eq (trim $.Site.Params.contentTypeName " ") "")) }}
|
||||
{{ $contentTypeName := cond $isntDefault (string $.Site.Params.contentTypeName) "posts" }}
|
||||
|
||||
{{ $PageContext := . }}
|
||||
{{ if .IsHome }}
|
||||
{{ $PageContext = .Site }}
|
||||
{{ end }}
|
||||
{{ $paginator := .Paginate (where $PageContext.RegularPages "Type" $contentTypeName) }}
|
||||
|
||||
{{ range $paginator.Pages }}
|
||||
<article class="post on-list">
|
||||
<h1 class="post-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
</h1>
|
||||
|
||||
<div class="post-meta">
|
||||
{{- if .Date -}}
|
||||
<time class="post-date">
|
||||
{{ .Date | time.Format ":date_medium" }}
|
||||
</time>
|
||||
{{- end -}}
|
||||
{{- with .Params.Author -}}
|
||||
<span class="post-author">{{ . }}</span>
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<span class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
#<a href="{{ (urlize (printf "tags/%s/" . )) | absLangURL }}">
|
||||
{{- . -}}
|
||||
</a>
|
||||
{{ end }}
|
||||
</span>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "cover.html" . }}
|
||||
|
||||
<div class="post-content">
|
||||
{{ if .Params.showFullContent }}
|
||||
{{ .Content }}
|
||||
{{ else if .Description }}
|
||||
{{ .Description | markdownify }}
|
||||
{{ else }}
|
||||
{{ .Summary }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ if not .Params.showFullContent }}
|
||||
<div>
|
||||
<a class="read-more button" href="{{.RelPermalink}}">{{ $.Site.Params.ReadMore }} →</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "pagination.html" . }}
|
||||
</div>
|
||||
{{ end }}
|
56
themes/hugo-theme-terminal/layouts/_default/list.html
Normal file
56
themes/hugo-theme-terminal/layouts/_default/list.html
Normal file
|
@ -0,0 +1,56 @@
|
|||
{{ define "main" }}
|
||||
{{ with .Content }}
|
||||
<div class="index-content">
|
||||
{{ . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<div class="posts">
|
||||
{{ range .Paginator.Pages }}
|
||||
<article class="post on-list">
|
||||
<h1 class="post-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
</h1>
|
||||
<div class="post-meta">
|
||||
{{- if .Date -}}
|
||||
<time class="post-date">
|
||||
{{ .Date | time.Format ":date_medium" }}
|
||||
</time>
|
||||
{{- end -}}
|
||||
{{- with .Params.Author -}}
|
||||
<span class="post-author">{{- . -}}</span>
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<span class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
#<a href="{{ (urlize (printf "tags/%s/" . )) | absLangURL }}">
|
||||
{{- . -}}
|
||||
</a>
|
||||
{{ end }}
|
||||
</span>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "cover.html" . }}
|
||||
|
||||
<div class="post-content">
|
||||
{{ if .Params.showFullContent }}
|
||||
{{ .Content }}
|
||||
{{ else if .Description }}
|
||||
{{ .Description | markdownify }}
|
||||
{{ else }}
|
||||
{{ .Summary }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ if not .Params.showFullContent }}
|
||||
<div>
|
||||
<a class="read-more button" href="{{.RelPermalink}}">{{ $.Site.Params.ReadMore }} →</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "pagination.html" . }}
|
||||
</div>
|
||||
{{ end }}
|
40
themes/hugo-theme-terminal/layouts/_default/rss.xml
Normal file
40
themes/hugo-theme-terminal/layouts/_default/rss.xml
Normal file
|
@ -0,0 +1,40 @@
|
|||
{{- $pctx := . -}}
|
||||
{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}}
|
||||
{{- $pages := slice -}}
|
||||
{{- if or $.IsHome $.IsSection -}}
|
||||
{{- $pages = $pctx.RegularPages -}}
|
||||
{{- else -}}
|
||||
{{- $pages = $pctx.Pages -}}
|
||||
{{- end -}}
|
||||
{{- $limit := .Site.Config.Services.RSS.Limit -}}
|
||||
{{- if ge $limit 1 -}}
|
||||
{{- $pages = $pages | first $limit -}}
|
||||
{{- end -}}
|
||||
{{- printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?>" | safeHTML }}
|
||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
||||
<channel>
|
||||
<title>{{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ .Site.Title }}{{ end }}</title>
|
||||
<link>{{ .Permalink }}</link>
|
||||
<description>Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ .Site.Title }}</description>
|
||||
<generator>Hugo -- gohugo.io</generator>{{ with .Site.LanguageCode }}
|
||||
<language>{{.}}</language>{{end}}{{ with .Site.Author.email }}
|
||||
<managingEditor>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</managingEditor>{{end}}{{ with .Site.Author.email }}
|
||||
<webMaster>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</webMaster>{{end}}{{ with .Site.Copyright }}
|
||||
<copyright>{{.}}</copyright>{{end}}{{ if not .Date.IsZero }}
|
||||
<lastBuildDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
|
||||
{{- with .OutputFormats.Get "RSS" -}}
|
||||
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
|
||||
{{- end -}}
|
||||
{{ range $pages }}
|
||||
<item>
|
||||
<title>{{ .Title }}</title>
|
||||
<link>{{ .Permalink }}</link>
|
||||
<pubDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</pubDate>
|
||||
{{ with .Site.Author.email }}<author>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</author>{{end}}
|
||||
<guid>{{ .Permalink }}</guid>
|
||||
<description>{{ .Summary | html }}</description>
|
||||
<content>{{ .Content | html }}</content>
|
||||
</item>
|
||||
{{ end }}
|
||||
</channel>
|
||||
</rss>
|
57
themes/hugo-theme-terminal/layouts/_default/single.html
Normal file
57
themes/hugo-theme-terminal/layouts/_default/single.html
Normal file
|
@ -0,0 +1,57 @@
|
|||
{{ define "main" }}
|
||||
<article class="post">
|
||||
<h1 class="post-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
</h1>
|
||||
<div class="post-meta">
|
||||
{{- if .Date -}}
|
||||
<time class="post-date">
|
||||
{{ .Date | time.Format ":date_medium" }}
|
||||
{{- if $.Site.Params.showLastUpdated -}}
|
||||
[{{- or $.Site.Params.updatedDatePrefix "Updated" -}} :: {{- .Lastmod.Format ":date_medium" -}}]
|
||||
{{- end -}}
|
||||
</time>
|
||||
{{- end -}}
|
||||
{{- with .Params.Author -}}
|
||||
<span class="post-author">{{ . }}</span>
|
||||
{{- end -}}
|
||||
{{- if and (.Param "readingTime") (eq (.Param "readingTime") true) -}}
|
||||
<span class="post-reading-time">{{ .ReadingTime }} {{ $.Site.Params.minuteReadingTime | default "min read" }} ({{ .WordCount }} {{ $.Site.Params.words | default "words" }})</span>
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<span class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
#<a href="{{ (urlize (printf "tags/%s/" .)) | absLangURL }}">{{ . }}</a>
|
||||
{{ end }}
|
||||
</span>
|
||||
{{ end }}
|
||||
{{ partial "cover.html" . }}
|
||||
|
||||
{{ if (.Params.Toc | default .Site.Params.Toc) }}
|
||||
<div class="table-of-contents">
|
||||
<h2>
|
||||
{{ (.Params.TocTitle | default .Site.Params.TocTitle) | default "Table of Contents" }}
|
||||
</h2>
|
||||
{{ .TableOfContents }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<div class="post-content">
|
||||
{{- with .Content -}}
|
||||
<div>
|
||||
{{ . | replaceRE "(<h[1-9] id=\"([^\"]+)\".+)(</h[1-9]+>)" `${1}<a href="#${2}" class="hanchor" ariaLabel="Anchor">⌗</a> ${3}` | safeHTML }}
|
||||
</div>
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{ if eq .Type $.Site.Params.contentTypeName }}
|
||||
{{ partial "posts_pagination.html" . }}
|
||||
{{ end }}
|
||||
|
||||
{{ if not (.Params.hideComments | default false) }}
|
||||
{{ partial "comments.html" . }}
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
57
themes/hugo-theme-terminal/layouts/_default/term.html
Normal file
57
themes/hugo-theme-terminal/layouts/_default/term.html
Normal file
|
@ -0,0 +1,57 @@
|
|||
{{ define "main" }}
|
||||
<h1>Posts for: #{{ .Title }}</h1>
|
||||
{{ with .Content }}
|
||||
<div class="index-content">
|
||||
{{ . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<div class="posts">
|
||||
{{ range .Paginator.Pages }}
|
||||
<article class="post on-list">
|
||||
<h1 class="post-title">
|
||||
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
|
||||
</h1>
|
||||
<div class="post-meta">
|
||||
{{- if .Date -}}
|
||||
<time class="post-date">
|
||||
{{- dateFormat "02 Oct 2006" .Date -}}
|
||||
</time>
|
||||
{{- end -}}
|
||||
{{- with .Params.Author -}}
|
||||
<span class="post-author">{{- . -}}</span>
|
||||
{{- end -}}
|
||||
</div>
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<span class="post-tags">
|
||||
{{ range .Params.tags }}
|
||||
#<a href="{{ (urlize (printf "tags/%s/" . )) | absLangURL }}">
|
||||
{{- . -}}
|
||||
</a>
|
||||
{{ end }}
|
||||
</span>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "cover.html" . }}
|
||||
|
||||
<div class="post-content">
|
||||
{{ if .Params.showFullContent }}
|
||||
{{ .Content }}
|
||||
{{ else if .Description }}
|
||||
{{ .Description | markdownify }}
|
||||
{{ else }}
|
||||
{{ .Summary }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ if not .Params.showFullContent }}
|
||||
<div>
|
||||
<a class="read-more button" href="{{.RelPermalink}}">{{ $.Site.Params.ReadMore }} →</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "pagination.html" . }}
|
||||
</div>
|
||||
{{ end }}
|
22
themes/hugo-theme-terminal/layouts/_default/terms.html
Normal file
22
themes/hugo-theme-terminal/layouts/_default/terms.html
Normal file
|
@ -0,0 +1,22 @@
|
|||
{{ define "main" }}
|
||||
<div class="terms">
|
||||
<h1>{{ .Title }}</h1>
|
||||
{{ with .Content }}
|
||||
<div class="index-content">
|
||||
{{ . }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<ul>
|
||||
{{ $type := .Type }}
|
||||
{{ range $key, $value := .Data.Terms.Alphabetical }}
|
||||
{{ $name := .Name }}
|
||||
{{ $count := .Count }}
|
||||
{{ with $.Site.GetPage (printf "/%s/%s" $type $name) }}
|
||||
<li>
|
||||
<a class="terms-title" href="{{ .Permalink }}">{{ .Name }} [{{ $count }}]</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
{{ end }}
|
|
@ -0,0 +1,8 @@
|
|||
<!--
|
||||
To add comments section, please create `layouts/partials/comments.html` in your
|
||||
Hugo directory and insert:
|
||||
|
||||
{{ template "_internal/disqus.html" . }}
|
||||
|
||||
or whatever comment engine you want -> https://gohugo.io/content-management/comments/#readout
|
||||
-->
|
24
themes/hugo-theme-terminal/layouts/partials/cover.html
Normal file
24
themes/hugo-theme-terminal/layouts/partials/cover.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
{{- $cover := false -}}
|
||||
{{- $autoCover := default $.Site.Params.autoCover false }}
|
||||
|
||||
{{- if index .Params "cover" -}}
|
||||
{{- if .Resources.GetMatch .Params.Cover }}
|
||||
{{- $cover = (.Resources.GetMatch .Params.Cover).RelPermalink -}}
|
||||
{{- else -}}
|
||||
{{- $cover = absURL .Params.Cover -}}
|
||||
{{- end -}}
|
||||
{{- else if $.Site.Params.AutoCover -}}
|
||||
{{- if (not .Params.Cover) -}}
|
||||
{{- if .Resources.GetMatch "cover.*" -}}
|
||||
{{- $cover = (.Resources.GetMatch "cover.*").RelPermalink -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{if $cover -}}
|
||||
<!-- Cover image found -->
|
||||
<img src="{{ $cover }}"
|
||||
class="post-cover"
|
||||
alt="{{ .Title | plainify | default " " }}"
|
||||
title="{{ .Params.CoverCredit |plainify|default "Cover Image" }}" />
|
||||
{{- end }}
|
|
@ -0,0 +1,4 @@
|
|||
<!--
|
||||
To add an extended footer section, please create
|
||||
`layouts/partials/extended_footer.html` in your Hugo directory.
|
||||
-->
|
|
@ -0,0 +1,4 @@
|
|||
<!--
|
||||
To add an extended head section, please create
|
||||
`layouts/partials/extended_head.html` in your Hugo directory.
|
||||
-->
|
26
themes/hugo-theme-terminal/layouts/partials/footer.html
Normal file
26
themes/hugo-theme-terminal/layouts/partials/footer.html
Normal file
|
@ -0,0 +1,26 @@
|
|||
<footer class="footer">
|
||||
<div class="footer__inner">
|
||||
{{ if $.Site.Copyright }}
|
||||
<div class="copyright copyright--user">
|
||||
<span>{{ $.Site.Copyright | safeHTML }}</span>
|
||||
{{ else }}
|
||||
<div class="copyright">
|
||||
<span>Powered by <a href="https://gohugo.io">Hugo</a></span>
|
||||
{{ end }}
|
||||
<span>:: <a href="https://github.com/panr/hugo-theme-terminal" target="_blank"> Theme</a> by <a href="https://github.com/panr" target="_blank">panr</a></span>
|
||||
<span>:: Mod. by <a href="https://git.sadium.cyou/SadmL"> SL</a> </span>
|
||||
<span>:: <a href="/tos"> ToS</a> :: {{ now.Year }}</span>
|
||||
<span>:: © <a href="https://choosealicense.com/licenses/cc-by-4.0/"> CC-BY-4.0</a></span>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
{{ $menu := resources.Get "js/menu.js" | js.Build }}
|
||||
{{ $prism := resources.Get "js/prism.js" | js.Build }}
|
||||
|
||||
{{ $bundle := slice $menu $prism | resources.Concat "bundle.js" | resources.Minify }}
|
||||
|
||||
<script type="text/javascript" src="{{ $bundle.RelPermalink }}"></script>
|
||||
|
||||
<!-- Extended footer section-->
|
||||
{{ partial "extended_footer.html" . }}
|
94
themes/hugo-theme-terminal/layouts/partials/head.html
Normal file
94
themes/hugo-theme-terminal/layouts/partials/head.html
Normal file
|
@ -0,0 +1,94 @@
|
|||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="{{ if .IsHome }}{{ $.Site.Params.Subtitle }}{{ else if .Description}}{{ .Description | plainify }}{{ else }}{{ .Summary | plainify }}{{ end }}" />
|
||||
<meta name="keywords" content="{{ with .Params.Keywords }}{{ delimit . ", " }}{{ else }}{{ $.Site.Params.Keywords }}{{ end }}" />
|
||||
{{ if .Params.noindex }}
|
||||
{{ if or (eq (.Param "noindex") true) (eq (.Param "noindex") "true") }}
|
||||
<meta name="robots" content="noindex" />
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
<meta name="robots" content="noodp" />
|
||||
{{ end }}
|
||||
<link rel="canonical" href="{{ .Permalink }}" />
|
||||
|
||||
{{ template "_internal/google_analytics.html" . }}
|
||||
|
||||
{{ $defaultStyles := resources.Get "css/style.scss" }}
|
||||
<!-- Local Theme Variables -->
|
||||
{{ if and (isset .Params "color") (not (eq .Params.color "")) }}
|
||||
{{ $localColorCss := resources.Get (printf "css/color/%s.scss" .Params.color) }}
|
||||
{{ $localCss := slice $localColorCss $defaultStyles | resources.Concat (printf "css/%s-local.scss" .Params.color) }}
|
||||
{{ $localColorStyles := $localCss | resources.ToCSS }}
|
||||
<link rel="stylesheet" href="{{ $localColorStyles.Permalink }}">
|
||||
{{ else }}
|
||||
<!-- Theme Variables -->
|
||||
{{ $colorCss := resources.Get (printf "css/color/%s.scss" ($.Site.Params.ThemeColor | default "orange")) }}
|
||||
{{ $css := slice $colorCss $defaultStyles | resources.Concat "css/base.scss" }}
|
||||
{{ $options := (dict "targetPath" "styles.css" "outputStyle" "compressed" "enableSourceMap" true "precision" 6 "includePaths" (slice "node_modules")) }}
|
||||
{{ $styles := $css | resources.ToCSS $options }}
|
||||
<link rel="stylesheet" href="{{ $styles.Permalink }}">
|
||||
{{ end }}
|
||||
|
||||
<!-- Custom CSS to override theme properties (/static/style.css) -->
|
||||
{{ if (fileExists "static/style.css") -}}
|
||||
<link rel="stylesheet" href="{{ "style.css" | absURL }}">
|
||||
{{- end }}
|
||||
|
||||
<!-- Icons -->
|
||||
{{ if isset $.Site.Params "favicon" }}
|
||||
<link rel="shortcut icon" href="{{ $.Site.Params.favicon | absURL }}">
|
||||
{{ else }}
|
||||
<link rel="shortcut icon" href="{{ printf "img/theme-colors/%s.png" (or .Params.color $.Site.Params.ThemeColor | default "orange") | absURL }}">
|
||||
<link rel="apple-touch-icon" href="{{ printf "img/theme-colors/%s.png" (or .Params.color $.Site.Params.ThemeColor | default "orange") | absURL }}">
|
||||
{{ end }}
|
||||
|
||||
<!-- Twitter Card -->
|
||||
<meta name="twitter:card" content="summary" />
|
||||
{{ if (isset $.Site.Params "twitter") }}
|
||||
{{ if (isset $.Site.Params.Twitter "site") }}
|
||||
<meta name="twitter:site" content="{{ $.Site.Params.Twitter.site }}" />
|
||||
{{ end }}
|
||||
<meta name="twitter:creator" content="{{ if .IsHome }}{{ $.Site.Params.Twitter.creator }}{{ else if isset .Params "authortwitter" }}{{ .Params.authorTwitter }}{{ else }}{{ .Params.Author }}{{ end }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- OG data -->
|
||||
<meta property="og:locale" content="{{ $.Site.Language.Lang }}" />
|
||||
<meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" />
|
||||
<meta property="og:title" content="{{ if .IsHome }}{{ $.Site.Title }}{{ else }}{{ .Title }}{{ end }}">
|
||||
<meta property="og:description" content="{{ if .IsHome }}{{ $.Site.Params.Subtitle }}{{ else if .Description}}{{ .Description | plainify }}{{ else }}{{ .Summary | plainify }}{{ end }}" />
|
||||
<meta property="og:url" content="{{ .Permalink }}" />
|
||||
<meta property="og:site_name" content="{{ $.Site.Title }}" />
|
||||
{{ if (isset .Params "cover") }}
|
||||
{{ $pageCover := .Param "cover" }}
|
||||
{{ with (.Resources.GetMatch (.Param "cover")) }}
|
||||
{{ $pageCover = .RelPermalink }}
|
||||
{{ end }}
|
||||
<meta property="og:image" content="{{ $pageCover | absURL }}">
|
||||
{{ else }}
|
||||
{{ if isset $.Site.Params "favicon" }}
|
||||
<meta property="og:image" content="{{ $.Site.Params.favicon | absURL }}">
|
||||
{{ else }}
|
||||
<meta property="og:image" content="{{ printf "img/favicon/%s.png" $.Site.Params.ThemeColor | absURL }}">
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
<meta property="og:image:width" content="1200">
|
||||
<meta property="og:image:height" content="627">
|
||||
{{ range .Params.categories }}
|
||||
<meta property="article:section" content="{{ . }}" />
|
||||
{{ end }}
|
||||
{{ if isset .Params "date" }}
|
||||
<meta property="article:published_time" content="{{ time .Date }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- RSS -->
|
||||
{{ with .OutputFormats.Get "RSS" }}
|
||||
<link href="{{ .RelPermalink }}" rel="alternate" type="application/rss+xml" title="{{ $.Site.Title }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- JSON Feed -->
|
||||
{{ with .OutputFormats.Get "json" }}
|
||||
<link href="{{ .RelPermalink }}" rel="alternate" type="application/json" title="{{ $.Site.Title }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- Extended head section-->
|
||||
{{ partial "extended_head.html" . }}
|
16
themes/hugo-theme-terminal/layouts/partials/header.html
Normal file
16
themes/hugo-theme-terminal/layouts/partials/header.html
Normal file
|
@ -0,0 +1,16 @@
|
|||
<header class="header">
|
||||
<div class="header__inner">
|
||||
<div class="header__logo">
|
||||
{{ partial "logo.html" . }}
|
||||
</div>
|
||||
{{ if len $.Site.Menus }}
|
||||
{{ partial "mobile-menu.html" . }}
|
||||
{{ end }}
|
||||
{{ if and $.Site.Params.showLanguageSelector (len $.Site.Home.AllTranslations) }}
|
||||
{{ partial "language-menu.html" . }}
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ if len $.Site.Menus }}
|
||||
{{ partial "menu.html" . }}
|
||||
{{ end }}
|
||||
</header>
|
|
@ -0,0 +1,10 @@
|
|||
<ul class="menu menu--desktop menu--language-selector">
|
||||
<li class="menu__trigger">{{ .Language.LanguageName }} ▾</li>
|
||||
<li>
|
||||
<ul class="menu__dropdown">
|
||||
{{ range $.Site.Home.AllTranslations }}
|
||||
<li><a href="{{ .Permalink }}">{{ .Language.LanguageName }}</a></li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
5
themes/hugo-theme-terminal/layouts/partials/logo.html
Normal file
5
themes/hugo-theme-terminal/layouts/partials/logo.html
Normal file
|
@ -0,0 +1,5 @@
|
|||
<a href="{{ if $.Site.Params.Logo.LogoHomeLink }}{{ $.Site.Params.Logo.LogoHomeLink }}{{else}}{{ $.Site.BaseURL }}{{ end }}">
|
||||
<div class="logo">
|
||||
{{ with $.Site.Params.Logo.logoText }}{{ . }}{{ else }}Terminal{{ end }}
|
||||
</div>
|
||||
</a>
|
33
themes/hugo-theme-terminal/layouts/partials/menu.html
Normal file
33
themes/hugo-theme-terminal/layouts/partials/menu.html
Normal file
|
@ -0,0 +1,33 @@
|
|||
<nav class="navigation-menu">
|
||||
<ul class="navigation-menu__inner menu--desktop">
|
||||
{{ if or $.Site.Params.showMenuItems ( eq .Site.Params.showMenuItems 0 ) }}
|
||||
{{ range first $.Site.Params.showMenuItems $.Site.Menus.main }}
|
||||
{{ if not .HasChildren }}
|
||||
<li><a href="{{ .URL }}" {{ if .Params.NewTab -}} target="_blank" {{- end }}>{{ .Name }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if gt (len $.Site.Menus.main) $.Site.Params.showMenuItems }}
|
||||
<li>
|
||||
<ul class="menu">
|
||||
<li class="menu__trigger">{{ $.Site.Params.MenuMore }} ▾</li>
|
||||
<li>
|
||||
<ul class="menu__dropdown">
|
||||
{{ range last (sub (len $.Site.Menus.main) $.Site.Params.showMenuItems) $.Site.Menus.main }}
|
||||
{{ if not .HasChildren }}
|
||||
<li><a href="{{ .URL }}" {{ if .Params.NewTab -}} target="_blank" {{- end }}>{{ .Name }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ else }}
|
||||
{{ range $.Site.Menus.main }}
|
||||
{{ if not .HasChildren }}
|
||||
<li><a href="{{ .URL }}" {{ if .Params.NewTab -}} target="_blank" {{- end }}>{{ .Name }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
</nav>
|
20
themes/hugo-theme-terminal/layouts/partials/mobile-menu.html
Normal file
20
themes/hugo-theme-terminal/layouts/partials/mobile-menu.html
Normal file
|
@ -0,0 +1,20 @@
|
|||
<ul class="menu menu--mobile">
|
||||
<li class="menu__trigger">Menu ▾</li>
|
||||
<li>
|
||||
<ul class="menu__dropdown">
|
||||
{{ range $.Site.Menus.main }}
|
||||
{{ if not .HasChildren }}
|
||||
<li><a href="{{ .URL }}">{{ .Name }}</a></li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ if and $.Site.Params.showLanguageSelector (len $.Site.Home.AllTranslations) }}
|
||||
<hr />
|
||||
{{ range $.Site.Home.AllTranslations }}
|
||||
<li>
|
||||
<a href="{{ .Permalink }}">{{ .Language.LanguageName }}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
16
themes/hugo-theme-terminal/layouts/partials/pagination.html
Normal file
16
themes/hugo-theme-terminal/layouts/partials/pagination.html
Normal file
|
@ -0,0 +1,16 @@
|
|||
<div class="pagination">
|
||||
<div class="pagination__buttons">
|
||||
{{ if .Paginator.HasPrev }}
|
||||
<a href="{{ .Paginator.Prev.URL }}" class="button previous">
|
||||
<span class="button__icon">←</span>
|
||||
<span class="button__text">{{ $.Site.Params.newerPosts | default "Newer posts" }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
{{ if .Paginator.HasNext }}
|
||||
<a href="{{ .Paginator.Next.URL }}" class="button next">
|
||||
<span class="button__text">{{ $.Site.Params.olderPosts | default "Older posts" }}</span>
|
||||
<span class="button__icon">→</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,26 @@
|
|||
{{ if or .NextInSection .PrevInSection }}
|
||||
<div class="pagination">
|
||||
<div class="pagination__title">
|
||||
<span class="pagination__title-h">{{ $.Site.Params.ReadOtherPosts }}</span>
|
||||
<hr />
|
||||
</div>
|
||||
<div class="pagination__buttons">
|
||||
{{ if .NextInSection }}
|
||||
<span class="button previous">
|
||||
<a href="{{ .NextInSection.Permalink }}">
|
||||
<span class="button__icon">←</span>
|
||||
<span class="button__text">{{ .NextInSection.Title }}</span>
|
||||
</a>
|
||||
</span>
|
||||
{{ end }}
|
||||
{{ if .PrevInSection }}
|
||||
<span class="button next">
|
||||
<a href="{{ .PrevInSection.Permalink }}">
|
||||
<span class="button__text">{{ .PrevInSection.Title }}</span>
|
||||
<span class="button__icon">→</span>
|
||||
</a>
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
15
themes/hugo-theme-terminal/layouts/shortcodes/code.html
Normal file
15
themes/hugo-theme-terminal/layouts/shortcodes/code.html
Normal file
|
@ -0,0 +1,15 @@
|
|||
{{ $id := delimit (shuffle (seq 1 9)) "" }}
|
||||
|
||||
{{ if .Get "language" }}
|
||||
<div class="collapsable-code">
|
||||
<input id="{{ .Get "id" | default $id }}" type="checkbox" {{ if ( eq ( .Get "isCollapsed" ) "true" ) -}} checked {{- end }} />
|
||||
<label for="{{ .Get "id" | default $id }}">
|
||||
<span class="collapsable-code__language">{{ .Get "language" }}</span>
|
||||
{{ if .Get "title" }}<span class="collapsable-code__title">{{ .Get "title" | markdownify }}</span>{{ end }}
|
||||
<span class="collapsable-code__toggle" data-label-expand="{{ .Get "expand" | default "△" }}" data-label-collapse="{{ .Get "collapse" | default "▽" }}"></span>
|
||||
</label>
|
||||
<pre {{ if .Get "language" }}class="language-{{ .Get "language" }}" {{ end }}><code>{{ .Inner | string }}</code></pre>
|
||||
</div>
|
||||
{{ else }}
|
||||
{{ errorf "If you want to use the \"collapsable code\" shortcode, you need to pass a mandatory \"language\" param. The issue occured in %q (%q)" .Page.File .Page.Permalink }}
|
||||
{{ end }}
|
|
@ -0,0 +1,8 @@
|
|||
{{ if .Get "src" }}
|
||||
<figure class="{{ with .Get "position"}}{{ . }}{{ else -}} left {{- end }}" >
|
||||
<img src="{{ .Get "src" | safeURL }}" {{ with .Get "alt" }} alt="{{ . | plainify }}" {{ end }} {{ with .Get "style" }} style="{{ . | safeCSS }}" {{ end }} />
|
||||
{{ if .Get "caption" }}
|
||||
<figcaption class="{{ with .Get "captionPosition"}}{{ . }}{{ else -}} center {{- end }}" {{ with .Get "captionStyle" }} style="{{ . | safeCSS }}" {{ end }}>{{ .Get "caption" | safeHTML }}</figcaption>
|
||||
{{ end }}
|
||||
</figure>
|
||||
{{ end }}
|
3
themes/hugo-theme-terminal/layouts/shortcodes/image.html
Normal file
3
themes/hugo-theme-terminal/layouts/shortcodes/image.html
Normal file
|
@ -0,0 +1,3 @@
|
|||
{{ if .Get "src" }}
|
||||
<img src="{{ .Get "src" | safeURL }}" {{ with .Get "alt" }} alt="{{ . | plainify }}" {{ end }} class="{{ with .Get "position"}}{{ . }}{{ else -}} left {{- end }}" {{ with .Get "style" }} style="{{ . | safeCSS }}" {{ end }} {{ with .Get "width" }} width="{{ . | plainify }}" {{ end }} {{ with .Get "height" }} height="{{ . | plainify }}" {{ end }} />
|
||||
{{ end }}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue