mirror of
https://github.com/Xevion/v2.xevion.dev.git
synced 2025-12-11 06:09:14 -06:00
Split default.html into two files to allow for special pages
This commit is contained in:
8
_includes/header.html
Normal file
8
_includes/header.html
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<header>Ryan Walters</header>
|
||||||
|
<nav>
|
||||||
|
<a href="/">~/</a>
|
||||||
|
:
|
||||||
|
<a href="/about/">~/about/</a>
|
||||||
|
:
|
||||||
|
<a href="/projects/">~/projects/</a>
|
||||||
|
</nav>
|
||||||
64
_layouts/base.html
Normal file
64
_layouts/base.html
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
---
|
||||||
|
layout: compress
|
||||||
|
---
|
||||||
|
<!doctype html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta content="width=device-width" name="viewport">
|
||||||
|
<link as="style" href="/assets/main.css" rel="preload">
|
||||||
|
<link href="/assets/main.css" rel="stylesheet">
|
||||||
|
<!-- build-commit-id: {{ site.github.build_revision }} -->
|
||||||
|
<!-- <link rel="stylesheet" href="/assets/print.css" media="print">-->
|
||||||
|
<link href="/assets/rouge.css" rel="stylesheet">
|
||||||
|
<title>
|
||||||
|
{%- if page.title %}
|
||||||
|
{{- page.title -}}{{- " " -}}|{{- " " -}}
|
||||||
|
{%- endif -%}
|
||||||
|
{{- site.title -}}
|
||||||
|
</title>
|
||||||
|
<link rel="icon" type="image/png" href="/favicon-16x16.png" sizes="16x16">
|
||||||
|
<link rel="icon" type="image/png" href="/favicon-32x32.png" sizes="32x32">
|
||||||
|
<link as="font" crossorigin href="/assets/fonts/-cmunrm.woff2" rel="preload">
|
||||||
|
<link as="font" crossorigin href="/assets/fonts/-cmuntt.woff2" rel="preload">
|
||||||
|
<link as="font" crossorigin href="/assets/fonts/-cmunti.woff2" rel="preload">
|
||||||
|
<link href="/feed.xml" rel="alternate" type="application/atom+xml">
|
||||||
|
{% if page._preview_description and page.title or page.name == "index.html" -%}
|
||||||
|
<meta content="website" property="og:type">
|
||||||
|
<meta property="og:url" content="{{ page.url | absolute_url }}">
|
||||||
|
<meta property="og:title" content="{{ page.title | default: "Xevion.dev" }}">
|
||||||
|
<meta name="twitter:title" content="{{ page.title | default: "Xevion.dev" }}">
|
||||||
|
{% if page._preview_description -%}
|
||||||
|
<meta property="og:description" content="{{ page._preview_description }}">
|
||||||
|
<meta property="twitter:description" content="{{ page._preview_description }}">
|
||||||
|
{% endif -%}
|
||||||
|
{%- if page._preview_image -%}
|
||||||
|
<meta property="og:image" content="{{ page._preview_image | absolute_url }}">
|
||||||
|
<meta name="twitter:image" content="{{ page._preview_image | absolute_url }}">
|
||||||
|
<meta content="summary_large_image" name="twitter:card">
|
||||||
|
{%- else -%}
|
||||||
|
<meta content="summary" name="twitter:card">
|
||||||
|
{%- endif -%}
|
||||||
|
{%- endif %}
|
||||||
|
<!-- Hide site using inline styling until CSS loads -->
|
||||||
|
<style>
|
||||||
|
html, body {
|
||||||
|
visibility: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
{% if page.wide or layout.wide %}
|
||||||
|
body {
|
||||||
|
max-width: 60em !important;
|
||||||
|
}
|
||||||
|
{% endif %}
|
||||||
|
</style>
|
||||||
|
<!-- Prevent FireFox from displaying FOUC with fake script tag. -->
|
||||||
|
<script>0</script>
|
||||||
|
{% if page.layout == "posts" %}
|
||||||
|
<script src="/assets/js/custom.js"></script>
|
||||||
|
{% endif %}
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
{{ content }}
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -1,120 +1,55 @@
|
|||||||
---
|
---
|
||||||
layout: compress
|
layout: base
|
||||||
---
|
---
|
||||||
<!doctype html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta content="width=device-width" name="viewport">
|
|
||||||
<link as="style" href="/assets/main.css" rel="preload">
|
|
||||||
<link href="/assets/main.css" rel="stylesheet">
|
|
||||||
<!-- build-commit-id: {{ site.github.build_revision }} -->
|
|
||||||
<!-- <link rel="stylesheet" href="/assets/print.css" media="print">-->
|
|
||||||
<link href="/assets/rouge.css" rel="stylesheet">
|
|
||||||
<title>
|
|
||||||
{%- if page.title %}
|
|
||||||
{{- page.title -}}{{- " " -}}|{{- " " -}}
|
|
||||||
{%- endif -%}
|
|
||||||
{{- site.title -}}
|
|
||||||
</title>
|
|
||||||
<link rel="icon" type="image/png" href="/favicon-16x16.png" sizes="16x16">
|
|
||||||
<link rel="icon" type="image/png" href="/favicon-32x32.png" sizes="32x32">
|
|
||||||
<link as="font" crossorigin href="/assets/fonts/-cmunrm.woff2" rel="preload">
|
|
||||||
<link as="font" crossorigin href="/assets/fonts/-cmuntt.woff2" rel="preload">
|
|
||||||
<link as="font" crossorigin href="/assets/fonts/-cmunti.woff2" rel="preload">
|
|
||||||
<link href="/feed.xml" rel="alternate" type="application/atom+xml">
|
|
||||||
{% if page._preview_description and page.title or page.name == "index.html" -%}
|
|
||||||
<meta content="website" property="og:type">
|
|
||||||
<meta property="og:url" content="{{ page.url | absolute_url }}">
|
|
||||||
<meta property="og:title" content="{{ page.title | default: "Xevion.dev" }}">
|
|
||||||
<meta name="twitter:title" content="{{ page.title | default: "Xevion.dev" }}">
|
|
||||||
{% if page._preview_description -%}
|
|
||||||
<meta property="og:description" content="{{ page._preview_description }}">
|
|
||||||
<meta property="twitter:description" content="{{ page._preview_description }}">
|
|
||||||
{% endif -%}
|
|
||||||
{%- if page._preview_image -%}
|
|
||||||
<meta property="og:image" content="{{ page._preview_image | absolute_url }}">
|
|
||||||
<meta name="twitter:image" content="{{ page._preview_image | absolute_url }}">
|
|
||||||
<meta content="summary_large_image" name="twitter:card">
|
|
||||||
{%- else -%}
|
|
||||||
<meta content="summary" name="twitter:card">
|
|
||||||
{%- endif -%}
|
|
||||||
{%- endif %}
|
|
||||||
<!-- Hide site using inline styling until CSS loads -->
|
|
||||||
<style>
|
|
||||||
html, body {
|
|
||||||
visibility: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
{% if page.wide or layout.wide %}
|
<div class="body-container">
|
||||||
body {
|
{% include header.html %}
|
||||||
max-width: 60em !important;
|
{% if page.hide_header or layout.hide_header %}
|
||||||
}
|
{% else %}
|
||||||
{% endif %}
|
{% if page.title %}
|
||||||
</style>
|
{% if page.date %}
|
||||||
<!-- Prevent FireFox from displaying FOUC with fake script tag. -->
|
{% if page._link %}
|
||||||
<script>0</script>
|
<h1>
|
||||||
{% if page.layout == "posts" %}
|
<a href="{{ page._link }}">
|
||||||
<script src="/assets/js/custom.js"></script>
|
{{ page.title }}
|
||||||
{% endif %}
|
</a>
|
||||||
</head>
|
</h1>
|
||||||
<body>
|
{% else %}
|
||||||
<header>Ryan Walters</header>
|
<h1>{{ page.title }}</h1>
|
||||||
<nav>
|
{% endif %}
|
||||||
<a href="/">~/</a>
|
{% else %}
|
||||||
:
|
<h1>{{ page.title }}</h1>
|
||||||
<a href="/about/">~/about/</a>
|
{% endif %}
|
||||||
:
|
{% endif %}
|
||||||
<a href="/projects/">~/projects/</a>
|
{% endif %}
|
||||||
</nav>
|
|
||||||
{% if page.hide_header or layout.hide_header %}
|
|
||||||
{% else %}
|
|
||||||
{% if page.title %}
|
|
||||||
{% if page.date %}
|
|
||||||
{% if page._link %}
|
|
||||||
<h1>
|
|
||||||
<a href="{{ page._link }}">
|
|
||||||
{{ page.title }}
|
|
||||||
</a>
|
|
||||||
</h1>
|
|
||||||
{% else %}
|
|
||||||
<h1>{{ page.title }}</h1>
|
|
||||||
{% endif %}
|
|
||||||
{% else %}
|
|
||||||
<h1>{{ page.title }}</h1>
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if page.date %}
|
{% if page.date %}
|
||||||
<p>
|
<p>
|
||||||
<i>
|
<i>
|
||||||
<a href="{{ page.url }}">
|
<a href="{{ page.url }}">
|
||||||
<time datetime="{{ page.date | date: '%Y-%m-%dT%H:%M:%SZ' }}">
|
<time datetime="{{ page.date | date: '%Y-%m-%dT%H:%M:%SZ' }}">
|
||||||
{{- page.date | date: '%Y-%m-%d %H:%M %Z' -}}
|
{{- page.date | date: '%Y-%m-%d %H:%M %Z' -}}
|
||||||
</time>
|
</time>
|
||||||
</a>
|
</a>
|
||||||
{%- for tag in page.tags -%}
|
{%- for tag in page.tags -%}
|
||||||
{{- " " -}}{{- tag -}}
|
{{- " " -}}{{- tag -}}
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
</i>
|
</i>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<article>
|
<article>
|
||||||
{{ content }}
|
{{ content }}
|
||||||
</article>
|
</article>
|
||||||
<p>
|
<p>
|
||||||
{% if page.custom_js %}
|
{% if page.custom_js %}
|
||||||
{% for file in page.custom_js %}
|
{% for file in page.custom_js %}
|
||||||
<script type="text/javascript" src="{{ site.baseurl }}/assets/js/{{ file }}"></script>
|
<script type="text/javascript" src="{{ site.baseurl }}/assets/js/{{ file }}"></script>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if layout.medium_zoom %}
|
{% if layout.medium_zoom %}
|
||||||
<script crossorigin="anonymous" integrity="sha256-EdPgYcPk/IIrw7FYeuJQexva49pVRZNmt3LculEr7zM=" src="https://cdn.jsdelivr.net/npm/medium-zoom@1.0.6/dist/medium-zoom.min.js"></script>
|
<script crossorigin="anonymous" integrity="sha256-EdPgYcPk/IIrw7FYeuJQexva49pVRZNmt3LculEr7zM=" src="https://cdn.jsdelivr.net/npm/medium-zoom@1.0.6/dist/medium-zoom.min.js"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
mediumZoom("[data-zoomable]", {background: "#0e0e0e"})
|
mediumZoom("[data-zoomable]", {background: "#0e0e0e"})
|
||||||
</script>
|
</script>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</p>
|
</p>
|
||||||
</body>
|
</div>
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
Reference in New Issue
Block a user