diff options
author | David Luevano Alvarado <david@luevano.xyz> | 2022-12-13 20:44:08 -0600 |
---|---|---|
committer | David Luevano Alvarado <david@luevano.xyz> | 2022-12-13 20:44:08 -0600 |
commit | abc0de079b895af1b705894eb2b63596e3e37274 (patch) | |
tree | c51d24dce55da8d9b227cbac6c2ef64a59d8e9dc /pyssg.xyz/plt | |
parent | db4b3736d4f45137a733ce5eb1e50aec968ca1d2 (diff) |
add pyssg.xyz configs and templates
Diffstat (limited to 'pyssg.xyz/plt')
-rw-r--r-- | pyssg.xyz/plt/base.html | 12 | ||||
-rw-r--r-- | pyssg.xyz/plt/body/footer.html (renamed from pyssg.xyz/plt/body_footer.html) | 12 | ||||
-rw-r--r-- | pyssg.xyz/plt/body/header.html (renamed from pyssg.xyz/plt/body_header.html) | 0 | ||||
-rw-r--r-- | pyssg.xyz/plt/root_page.html (renamed from pyssg.xyz/plt/root_index.html) | 43 |
4 files changed, 43 insertions, 24 deletions
diff --git a/pyssg.xyz/plt/base.html b/pyssg.xyz/plt/base.html index 8f9fbdc..d5cb77b 100644 --- a/pyssg.xyz/plt/base.html +++ b/pyssg.xyz/plt/base.html @@ -9,27 +9,22 @@ {%block head_title%}{%endblock head_title%} {%block head_description%}{%endblock head_description%} {%block head_rss%}{%endblock head_rss%} - <!-- general style --> <link rel="stylesheet" type="text/css" href="css/style.css"> <link rel="stylesheet" type="text/css" href="fork-awesome/css/fork-awesome.min.css"> <link rel="stylesheet" type="text/css" href="font-awesome/css/all.min.css"> - <!-- theme related --> <script type="text/javascript" src="scripts/theme.js"></script> <link id="theme-css" rel="stylesheet" type="text/css" href="css/theme.css"> - - <!-- extra -->> + <!-- extra --> {%block head_extra%}{%endblock head_extra%} - <!-- og meta --> {%block head_og%}{%endblock head_og%} </head> <body> <header> - {%import "body_header.html" as body_header%} - {{body_header.print(config)}} + {%block body_header%}{%endblock body_header%} </header> <main> @@ -37,8 +32,7 @@ </main> <footer> - {%import "body_footer.html" as body_footer%} - {{body_footer.print(config)}} + {%block body_footer%}{%endblock body_footer%} </footer> </body> </html>
\ No newline at end of file diff --git a/pyssg.xyz/plt/body_footer.html b/pyssg.xyz/plt/body/footer.html index 1bcf4c6..32dcaf0 100644 --- a/pyssg.xyz/plt/body_footer.html +++ b/pyssg.xyz/plt/body/footer.html @@ -1,26 +1,32 @@ -{%macro print(config)%} +{%macro contact(config)%} <span> <i class="fas fa-address-card" alt="Contact"></i> <a href="{{config['url']['main']}}/contact.html">Contact</a> </span> +{%endmacro%} +{%macro donate(config)%} <span> <i class="fas fa-donate" alt="Donate"></i> <a href="{{config['url']['main']}}/donate.html">Donate</a> </span> +{%endmacro%} +{%macro rss(config)%} <span> <i class="fas fa-rss" alt="RSS"></i> <a target="_blank" href="{{config['url']['main']}}/rss.xml">RSS</a> </span> +{%endmacro%} -<br> +{%macro created_with()%} <span class="created-with"> <i class="fas fa-hammer" alt="Hammer"></i> Created with <a href="https://github.com/luevano/pyssg">pyssg</a> </span> +{%endmacro%} -<br> +{%macro copyright()%} <span class="copyright"> Copyright <i class="far fa-copyright" alt="Copyright"></i> 2023 David Luévano Alvarado </span> diff --git a/pyssg.xyz/plt/body_header.html b/pyssg.xyz/plt/body/header.html index 9b38511..9b38511 100644 --- a/pyssg.xyz/plt/body_header.html +++ b/pyssg.xyz/plt/body/header.html diff --git a/pyssg.xyz/plt/root_index.html b/pyssg.xyz/plt/root_page.html index 73cd8a0..7d04d98 100644 --- a/pyssg.xyz/plt/root_index.html +++ b/pyssg.xyz/plt/root_page.html @@ -1,31 +1,50 @@ {%extends "base.html"%} -{%block html_lang%}{{config['lang']}}{%endblock html_lang%} + +{%block html_lang%} +{{config['lang']}} +{%endblock html_lang%} + {%block head_title%} <title>{{config['title']}}</title> {%endblock head_title%} + {%block head_description%} <meta name="description" content="{{config['description']}}"/> {%endblock head_description%} + {%block head_rss%} -<link rel="alternate" type="application/rss+xml" href="{{config['url']['main']}}/rss.xml" title="{{config['title']}} RSS"> {%endblock head_rss%} + +{%block head_extra%} +{%endblock head_extra%} + {%block head_og%} <meta property="og:title" content="{{config['title']}}"/> <meta property="og:type" content="article"/> - <meta property="og:url" content="{{config['url']['main']}}/index.html"/> - <meta property="og:image" content="{{config['url']['static']}}{{config['url']['default_image']}}"/> + <meta property="og:url" content="{{config['url']['main']}}/{{page.name}}"/> + <meta property="og:image" content="{{config['url']['static']}}/{{config['url']['default_image']}}"/> <meta property="og:description" content="{{config['description']}}"/> <meta property="og:locale" content="{{config['lang']}}"/> <meta property="og:site_name" content="{{config['title']}}"/> {%endblock head_og%} -{%block body_content%} - <h1>{{config['info']['title']}}</h1> - <p> - Welcome to the official pyssg website. This is as of now serving as a testing ground when I'm making changes to it. - </p> +{%block body_header%} +{%import 'body/header.html' as body_header%} +{{body_header.print(config)}} +{%endblock body_header%} - <p> - Get the RSS feed: <a target="_blank" href="{{config['url']['main']}}/rss.xml">{{config['url']['main']}}/rss.xml</a> - </p> +{%block body_content%} + <h1>{{page.title}}</h1> + + {{page.content}} {%endblock body_content%} + +{%block body_footer%} +{%import 'body/footer.html' as body_footer%} +{{body_footer.contact(config)}} +{{body_footer.donate(config)}} +<br> +{{body_footer.created_with()}} +<br> +{{body_footer.copyright()}} +{%endblock body_footer%}
\ No newline at end of file |