aboutsummaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorYaroslav de la Peña Smirnov <yps@yaroslavps.com>2021-12-24 03:32:22 +0300
committerYaroslav de la Peña Smirnov <yps@yaroslavps.com>2022-01-02 00:13:30 +0300
commit8acb898a2f2730e2a853c844f0e8b9bb2d690f49 (patch)
tree8adc60ea6bf248622973af99e8e54c80623a86cd /templates
parent89b0939c584df21981d65511576a6272ce57cdbd (diff)
downloadyaroslavps.com-8acb898a2f2730e2a853c844f0e8b9bb2d690f49.tar.gz
yaroslavps.com-8acb898a2f2730e2a853c844f0e8b9bb2d690f49.zip
Huge html+css revamp
* Plus added links to new photo gallery and donate page. * Title fix
Diffstat (limited to 'templates')
-rw-r--r--templates/base.html106
-rw-r--r--templates/donate.html30
-rw-r--r--templates/index.html216
3 files changed, 201 insertions, 151 deletions
diff --git a/templates/base.html b/templates/base.html
index 908e93c..efb1e7d 100644
--- a/templates/base.html
+++ b/templates/base.html
@@ -11,7 +11,7 @@
<meta content="width=device-width, initial-scale=1" name="viewport">
<title>
{% block title %}
- {{ config.title }}
+ Yaroslav de la Peña Smirnov
{% endblock %}
</title>
<link rel="stylesheet" href="{{ get_url(path="css/yaroslavps.css") }}">
@@ -23,26 +23,18 @@
<body>
<div class="main-container">
{% block page %}
- <div class="header-container">
- {% block header %}
- <h1><a href="/">Yaroslav de la Peña Smirnov</a></h1>
- {% endblock %}
- </div>
<div class="content-container">
+ <div class="header-container">
+ {% block header %}
+ <h1><a href="/">Yaroslav de la Peña Smirnov</a></h1>
+ {% endblock %}
+ </div>
{% block content %}
{% endblock %}
</div>
<div class="sidebar-container">
<div class="sticky-wrapper">
- <h3>
- {% if lang == "ru" %}
- Навигация
- {% elif lang == "es" %}
- En este sitio
- {% else %}
- Navigation
- {% endif %}
- </h3>
+ <h3>{{ trans(key="whats_here", lang=lang) }}</h3>
<ul class="navigation-list">
<li>
{% if lang == "ru" %}
@@ -50,19 +42,19 @@
{% elif lang == "es" %}
<a href="/es/">Inicio</a>
{% else %}
- <a href="/">Home page</a>
+ <a href="/">Home</a>
{% endif %}
- <ul>
+ <span class="extra-link">[
{% if lang != "en" %}
- <li><a href="/">English</a></li>
- {% endif %}
- {% if lang != "es" %}
- <li><a href="/es/">Español</a></li>
+ <a href="/">en</a>
{% endif %}
{% if lang != "ru" %}
- <li><a href="/ru/">Русский</a></li>
+ <a href="/ru/">ru</a>
+ {% endif %}
+ {% if lang != "es" %}
+ <a href="/es/">es</a>
{% endif %}
- </ul>
+ ]</span>
</li>
<li>
{% if lang == "ru" %}
@@ -72,6 +64,17 @@
{% else %}
<a href="/weblog/">Weblog</a>
{% endif %}
+ <span class="extra-link">[
+ {% if lang != "en" %}
+ <a href="/weblog">en</a>
+ {% endif %}
+ {% if lang != "ru" %}
+ <a href="/ru/weblog">ru</a>
+ {% endif %}
+ {% if lang != "es" %}
+ <a href="/es/weblog">es</a>
+ {% endif %}
+ ]</span>
<ul>
<li>
{% if lang == "ru" %}
@@ -92,6 +95,17 @@
{% else %}
<a href="/food/">Recipe book</a>
{% endif %}
+ <span class="extra-link">[
+ {% if lang != "en" %}
+ <a href="/food">en</a>
+ {% endif %}
+ {% if lang != "ru" %}
+ <a href="/ru/food">ru</a>
+ {% endif %}
+ {% if lang != "es" %}
+ <a href="/es/food">es</a>
+ {% endif %}
+ ]</span>
<ul>
<li>
{% if lang == "ru" %}
@@ -105,58 +119,12 @@
</ul>
</li>
</ul>
- <h3>
- {% if lang == "ru" %}
- RSS-лента
- {% elif lang == "es" %}
- RSS
- {% else %}
- RSS feeds
- {% endif %}
- </h3>
- <ul class="rss-list">
- <li>
- {% if lang == "ru" %}
- <a href="/ru/weblog/feed.xml">RSS веб-журнала</a>
- {% elif lang == "es" %}
- <a href="/es/weblog/feed.xml">RSS del weblog</a>
- {% else %}
- <a href="/weblog/feed.xml">Weblog RSS</a>
- {% endif %}
- </li>
- <li>
- {% if lang == "ru" %}
- <a href="/ru/food/feed.xml">RSS книги рецептов</a>
- {% elif lang == "es" %}
- <a href="/es/food/feed.xml">RSS del recetario</a>
- {% else %}
- <a href="/food/feed.xml">Recipe book RSS</a>
- {% endif %}
- </li>
- </ul>
<h3>Email</h3>
<a href="mailto:yps@yaroslavps.com">yps@yaroslavps.com</a>
<h3>PGP</h3>
<a href="https://www.yaroslavps.com/files/yaroslavpub.gpg">
BD900E5D624046DC
</a>
- <h3>
- {% if lang == "ru" %}
- Другие ссылки
- {% elif lang == "es" %}
- Otros vínculos
- {% else %}
- Other stuff
- {% endif %}
- </h3>
- <div class="links-container">
- <a href="https://github.com/Yaroslav-95" title="GitHub">
- <span class="icon"><img src="/svg/icons/github.svg"/></span>
- </a>
- <a href="https://git.yaroslavps.com/" title="Git server">
- <span class="icon"><img src="/svg/icons/git.svg"/></span>
- </a>
- </div>
{% if lang == "ru" %}
<p>
Это русскоязычная версия сайта. Если вам интересно
diff --git a/templates/donate.html b/templates/donate.html
index 3c5df03..18cab1d 100644
--- a/templates/donate.html
+++ b/templates/donate.html
@@ -10,31 +10,29 @@
Yaroslav's tip page
{% endif %}
</h1>
- <a href="/">
- {% if lang == "ru" %}
- Вернуться на главную
- {% elif lang == "es" %}
- Regresar a la página de inicio
- {% else %}
- Go back to home page
- {% endif %}
- </a>
+ {% if lang == "ru" %}
+ <p>вернуться на <a href="/">главную страницу Ярослава</a></p>
+ {% elif lang == "es" %}
+ <p>regresar a <a href="/">la página de inicio de Yaroslav</a></p>
+ {% else %}
+ <p>back to <a href="/">Yaroslav's homepage</a></p>
+ {% endif %}
<p>
{% if lang == "ru" %}
Если вам нравится мой сайт или то, чем я занимаюсь, вы можете мне
- отправить пожертвование. У меня временно проблемы с Paypal'ом,
- поэтому пока только принимаю пожертвования на Биткойн и Monero.
+ отправить пожертвование.
{% elif lang == "es" %}
Si te gusta mi sitio web o lo que hago en general, puedes dejarme
- una propina. Por el momento tengo problemas con Paypal, por lo tanto
- sólo estoy recibiendo donaciones a través de Bitcoin y Monero.
+ una propina.
{% else %}
If you like my site or any of the things that I do, you can leave me
- a tip. Currently I am having some troubles with Paypal, so Bitcoin
- and Monero are the only two methods available at the moment for
- receiving donations.
+ a tip.
{% endif %}
</p>
+ <h2>Paypal</h2>
+ <img class="cryptoqr" src="{{ get_url(path="img/paypal.png") }}">
+ <br>
+ <a href="https://paypal.me/yaroslavps">https://paypal.me/yaroslavps</a>
<h2>
<span class="icon">
<img src="{{ get_url(path="svg/icons/btc.svg") }}"/>
diff --git a/templates/index.html b/templates/index.html
index 91cce73..a47e545 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -1,53 +1,139 @@
{% extends "base.html" %}
{% block page %}
+ {% if lang != "en" %}
+ {% set weblog_path = "weblog/_index." ~ lang ~ ".md" %}
+ {% set recipes_path = "food/_index." ~ lang ~ ".md" %}
+ {% else %}
+ {% set weblog_path = "weblog/_index.md" %}
+ {% set recipes_path = "food/_index.md" %}
+ {% endif %}
+ {% set weblog = get_section(path=weblog_path) %}
+ {% set recipes = get_section(path=recipes_path) %}
<div class="landing-page-container">
<h1>{{ trans(key="full_name", lang=lang) }}</h1>
- <div class="links-container">
- {% if lang == "ru" %}
- <a href="/ru/weblog">Веб-журнал</a>
- <a href="/ru/food">Книга рецептов</a>
- {% elif lang == "es" %}
- <a href="/es/weblog">Weblog</a>
- <a href="/es/food">Recetario</a>
- {% else %}
- <a href="/weblog">Weblog</a>
- <a href="/food">Recipe book</a>
+ <div class="nav-container">
+ {% if lang != "en" %}
+ <a href="/">🇺🇸 English</a>
+ {% endif %}
+ {% if lang != "ru" %}
+ <a href="/ru/">🇷🇺 Русский</a>
+ {% endif %}
+ {% if lang != "es" %}
+ <a href="/es/">🇲🇽 Español</a>
{% endif %}
</div>
- <div class="links-container">
- <a href="https://github.com/Yaroslav-95" title="GitHub">
- <span class="icon"><img src="/svg/icons/github.svg"/></span>
- </a>
- <a href="https://git.yaroslavps.com/" title="Git server">
- <span class="icon"><img src="/svg/icons/git.svg"/></span>
- </a>
- </div>
+
<p>
{% if lang == "ru" %}
- Здравствуйте! Меня зовут Ярослав и это мой сайт. Здесь я пишу о том что
- я думаю или делаю, или чтобы напомнить себе как что-то делать, будь это
- настроить сервер или приготовить блюдо. Возможно вы найдёте что-нибудь
- интересного. Большая часть того что я пишу, на
- <a href="/">английском</a>. Но, бывает иногда пишу или перевожу то, что
- пишу, на русский и/или <a href="/es/">испанский</a> языки.
+ Добро пожаловать в мой уголок интернета. Чувствуйте себя как дома.
+ Иногда пишу на русском, но по большей части пишу на английском. Что
+ можно найти на моём сайте:
+ {% elif lang == "es" %}
+ Bienvenido a mi pequeño rincón de internet. Siéntete libre de echar una
+ mirada. A veces escribo en español, pero la mayor parte del contenido
+ está en inglés. Esto es lo que puedes encontrar en mi sitio:
+ {% else %}
+ Welcome to my little corner of the internet. Feel free to take a look
+ around. This is what you can find on my website:
+ {% endif %}
+ </p>
+
+ <p class="new-year">
+ {% if lang == "ru" %}
+ С Новым 2022 Годом и Рождеством!
{% elif lang == "es" %}
- Buenas y bienvenidos sean. Mi nombre es Yaroslav y éste es mi sitio.
- Aquí escribo lo que pienso o hago, o simplemente para acordarme luego de
- como hacer ciertas cosas, sea configurar un servidor, o cocinar una
- receta. Echa una mirada, a lo mejor encuentras algo interestante o útil.
- Escribo en su mayoría en <a href="/">inglés</a>, pero a veces también
- escribo o traduzco lo que escribo al español y/o al
- <a href="/ru/">ruso</a>.
+ ¡Feliz Navidad y Año Nuevo 2022!
{% else %}
- Welcome, my name is Yaroslav. I keep this site to sometimes write about
- what I do or think on my weblog, or to remind myself of how to do
- certain things, be it set up a server or how to make some dishes. You
- can take a look around, maybe you'll find something interesting or
- useful. Most of the time I write in English, but sometimes I might also
- write or translate what I write in <a href="/es/">Spanish</a> or
- <a href="/ru/">Russian</a>.
+ A Merry Christmas and a Happy New Year 2022!
+ {% endif %}
+ </p>
+
+ <h2>{{ trans(key="weblog", lang=lang) }}</h2>
+ {% set latest_weblog = weblog.pages[0] %}
+ <p>
+ {% if lang == "en" %}
+ My thoughts on different matters and some things that I would like to
+ remember.
+ {% elif lang == "es" %}
+ Mis pensamientos acerca de diferentes temas y ciertas cosas que quisiera
+ recordar.
+ {% elif lang == "ru" %}
+ Мои мысли о разных предметах и то, что мне бы хотелось запомнить.
+ {% endif %}
+ </p>
+ <div class="post-container partial">
+ <h3>
+ <a href="{{ latest_weblog.permalink }}">{{ latest_weblog.title }}</a>
+ {% if latest_weblog.date %}
+ <span class="publish-date">{{ latest_weblog.date | date }}</span>
+ {% endif %}
+ </h3>
+ {% if latest_weblog.summary %}
+ {{ latest_weblog.summary | safe }}
+ {% endif %}
+ </div>
+ <div class="nav-container">
+ <a class="see-more" href="{{ weblog.permalink }}">{{ trans(key="see_more", lang=lang) }}</a>
+ <a href="{{ weblog.permalink }}archive">{{ trans(key="archive", lang=lang) }}</a>
+ <a href="{{ weblog.permalink }}feed.xml"><span class="icon"><img src="/svg/icons/rss.svg"/></span> RSS</a>
+ </div>
+
+ <h2>{{ trans(key="recipes", lang=lang) }}</h2>
+ {% set latest_recipe = recipes.pages[0] %}
+ <p>
+ {% if lang == "en" %}
+ A collection of my favorite recipes that I often cook.
+ {% elif lang == "es" %}
+ Una colección de mis recetas favoritas que cocino con frecuencia.
+ {% elif lang == "ru" %}
+ Набор моих любимых рецептов, которые часто готовлю.
{% endif %}
</p>
+ <div class="post-container partial">
+ <h3>
+ <a href="{{ latest_recipe.permalink }}">{{ latest_recipe.title }}</a>
+ {% if latest_recipe.date %}
+ <span class="publish-date">{{ latest_recipe.date | date }}</span>
+ {% endif %}
+ </h3>
+ {% if latest_recipe.summary %}
+ {{ latest_recipe.summary | safe }}
+ {% endif %}
+ </div>
+ <div class="nav-container">
+ <a class="see-more" href="{{ recipes.permalink }}">{{ trans(key="see_more", lang=lang) }}</a>
+ <a href="{{ recipes.permalink }}archive">{{ trans(key="archive", lang=lang) }}</a>
+ <a href="{{ recipes.permalink }}feed.xml"><span class="icon"><img src="/svg/icons/rss.svg"/></span> RSS</a>
+ </div>
+
+ <h2>{{ trans(key="photos", lang=lang) }}</h2>
+ <p>
+ {% if lang == "en" %}
+ A gallery with some photographs I've taken on my free time.
+ {% elif lang == "es" %}
+ Una galería de fotografías que he tomado en mi tiempo libre.
+ {% elif lang == "ru" %}
+ Галерея с фотографиями сняты в моё свободное время.
+ {% endif %}
+ </p>
+ <div class="album-container">
+ <a href="https://www.yaroslavps.com/photos/st-petersburg-summer-2019/_DSC3948">
+ <img class="thumbnail" src="https://www.yaroslavps.com/photos/st-petersburg-summer-2019/_DSC3948/_DSC3948_thumb.jpg">
+ </a>
+ <a href="https://www.yaroslavps.com/photos/st-petersburg-summer-2019/_DSC1690">
+ <img class="thumbnail" src="https://www.yaroslavps.com/photos/st-petersburg-summer-2019/_DSC1690/_DSC1690_thumb.jpg">
+ </a>
+ <a href="https://www.yaroslavps.com/photos/navy-day-2019/_DSC3892">
+ <img class="thumbnail" src="https://www.yaroslavps.com/photos/navy-day-2019/_DSC3892/_DSC3892_thumb.jpg">
+ </a>
+ <a href="https://www.yaroslavps.com/photos/tallinn-2019/_DSC4468">
+ <img class="thumbnail" src="https://www.yaroslavps.com/photos/tallinn-2019/_DSC4468/_DSC4468_thumb.jpg">
+ </a>
+ </div>
+ <div class="nav-container">
+ <a class="see-more" href="/photos">{{ trans(key="see_more", lang=lang) }}</a>
+ </div>
+
<h2>
{% if lang == "ru" %}
Связаться
@@ -89,40 +175,38 @@
</p>
<p>
{% if lang == "ru" %}
- Публичный PGP-ключ:
+ PGP-ключ:
{% elif lang == "es" %}
- Llave pública de PGP:
+ Llave de PGP:
{% else %}
- Public PGP key:
+ PGP key:
{% endif %}
<a href="https://www.yaroslavps.com/files/yaroslavpub.gpg">BD900E5D624046DC</a>
</p>
- <h2>RSS feeds</h2>
- <p>
- {% if lang == "ru" %}
- Если вам хочеться следить за тем что я здесь публикую, вы можете
- добавить эти RSS/Atom-ссылки в свой любимый RSS-ридер:
+ <h2>{{ trans(key="other_links", lang=lang) }}</h2>
+ <div class="nav-container">
+ {% if lang == "en" %}
+ <a href="/donate" title="Leave a tip"><span class="icon"><img src="/svg/icons/btc.svg"/></span> Leave a tip</a>
{% elif lang == "es" %}
- Si te interesa estar al tanto de lo que publico aquí, cuan seguido
- yo publique, puedes agregar estas direcciones de RSS/Atom a tu
- lector RSS de preferencia:
- {% else %}
- If you are interested in following what I may publish here (however
- often it may be), you can add these RSS/Atom urls to your favorite
- RSS reader:
+ <a href="/es/donate" title="Leave a tip"><span class="icon"><img src="/svg/icons/btc.svg"/></span> Dejar propinar</a>
+ {% elif lang == "ru" %}
+ <a href="/ru/donate" title="Leave a tip"><span class="icon"><img src="/svg/icons/btc.svg"/></span> Оставить чайвые</a>
{% endif %}
- </p>
- <pre class="rss-links-list">
- {% if lang == "ru" %}
-https://www.yaroslavps.com/ru/weblog/feed.xml
-https://www.yaroslavps.com/ru/food/feed.xml
- {% elif lang == "es" %}
-https://www.yaroslavps.com/es/weblog/feed.xml
-https://www.yaroslavps.com/es/food/feed.xml
- {% else %}
-https://www.yaroslavps.com/weblog/feed.xml
-https://www.yaroslavps.com/food/feed.xml
- {% endif %}
- </pre>
+ <a href="https://git.yaroslavps.com/" title="Git server"><span class="icon"><img src="/svg/icons/git.svg"/></span> Git server</a>
+ <a href="https://github.com/Yaroslav-95" title="GitHub"><span class="icon"><img src="/svg/icons/github.svg"/></span> Github</a>
+ <a href="https://sr.ht/~yaroslav/" title="sourcehut"><span class="icon"><img src="/svg/icons/srht.svg"/></span> sourcehut</a>
+ </div>
+ <hr>
+ <div class="nav-container">
+ <p>
+ The text content in this site is
+ <a href="https://creativecommons.org/licenses/by-sa/4.0/">CC BY-SA 4.0</a>,
+ the photos are under
+ <a href="https://creativecommons.org/licenses/by-nc-sa/4.0/">CC BY-NC-SA 4.0</a>.
+ </p>
+ <p>
+ © 2018—2021 Yaroslav de la Peña Smirnov.
+ </p>
+ </div>
</div>
{% endblock %}