accessibility maxxing

This commit is contained in:
sundae 2025-09-11 19:30:58 +03:00
parent 6c9294f0a0
commit f18a342ae5
No known key found for this signature in database
64 changed files with 320 additions and 205 deletions

View file

@ -8,10 +8,10 @@ theme: "M16 6a1 1 0 010 20Zm0-4a1 1 0 000 28A1 1 0 0016 2"
<html lang="en">
<head>
<title>
{{site.name}}
{%if title%}
- {{page.fileSlug|capitalize}}
{%endif%}
{{ site.name }}
{% if title %}
- {{ page.fileSlug|capitalize }}
{% endif %}
</title>
<link rel="icon" href="/assets/img/icon/sundae.png">
<meta name="viewport" content="width=device-width, initial-scale=1">
@ -19,73 +19,84 @@ theme: "M16 6a1 1 0 010 20Zm0-4a1 1 0 000 28A1 1 0 0016 2"
<link rel="stylesheet" href="/assets/css/reset.css">
<link rel="stylesheet" href="/assets/css/default/default.css">
<link rel="stylesheet" href="/assets/css/default/system.css" id="custom">
{%if page.url === "/home/"%}
<link rel="stylesheet" href="/assets/css/pokesprite-pokemon-gen8.css"/>
{%endif%}
{%set availableStyles = ['home', 'blog', 'gallery']%}
{%if page.url%}
{%if availableStyles.indexOf(page.url|firstSegment) !== -1%}
<link rel="stylesheet" href="/assets/css/default/{{page.url|firstSegment}}.css">
{%endif%}
{%endif%}
{% if page.url === "/home/" %}
<link rel="stylesheet" href="/assets/css/pokesprite-pokemon-gen8.css"/>
{% endif %}
{% set availableStyles = ['home', 'blog', 'gallery'] %}
{% if page.url %}
{% if availableStyles.indexOf(page.url|firstSegment) !== -1 %}
<link rel="stylesheet" href="/assets/css/default/{{ page.url|firstSegment }}.css">
{% endif %}
{% endif %}
</head>
<body id="{{page.url|firstSegment}}">
<body id="{{ page.url|firstSegment }}">
<nav>
<details open="">
<summary>
<svg width="20" height="20" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path d="{{paw}}"></svg>
<svg viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path d="{{ paw }}"></svg>
Navigation
</summary>
{%set currentUrl%}{{page.url}}{%endset%}
{%set sortedPages = collections.pages|sort(attribute='data.order')%}
{% set currentUrl %}{{ page.url }}{% endset %}
{% set sortedPages = collections.pages|sort(attribute='data.order') %}
<ul role="list">
<li>
<a href="../">
<svg width="20" height="20" viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg">
<path d="{{back}}"></path>
<svg viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path d="{{ back }}"></path>
</svg>
Back
</a>
</li>
<li>
<button id="theme-toggle">
<svg width="20" height="20" viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg">
<path d="{{theme}}"></svg>
<svg viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path d="{{ theme }}"></svg>
Toggle theme
</button>
</li>
{%for page in sortedPages%}
{% for page in sortedPages %}
<li>
<a {%if currentUrl === page.url%} aria-current="page" {%endif%} href="{{page.url}}">
<svg width="20" height="20" viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg">
<path d="{{page.data.icon}}"></path>
<a {% if currentUrl === page.url %} aria-current="page" {% endif %} href="{{ page.url }}">
<svg viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path d="{{ page.data.icon }}"></path>
</svg>
{{page.data.title}}</a>
{{ page.data.title }}</a>
</li>
{%endfor%}
{% endfor %}
<script src="/assets/js/theme.js"></script>
</li>
</ul>
</details>
<details open="">
<summary>
<svg width="20" height="20" viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path d="{{paw}}"></svg>
<svg viewbox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path d="{{ paw }}"></svg>
Outgoing
</summary>
<ul role="list">
{%for item in outgoing.items%}
{% for item in outgoing.items %}
<li>
<a href="{{item.src}}"><img src="{{item.icon}}" alt="">{{item.title}}</a>
<a href="{{ item.src }}"><img src="{{ item.icon }}" alt="" aria-hidden="true">{{ item.title }}</a>
</li>
{%endfor%}
{% endfor %}
</ul>
</details>
<script src="/assets/js/nav-details.js"></script>
</nav>
<header>
<h1>
{% for page in sortedPages %}
{% if currentUrl|firstSegment === page.url|firstSegment %}
<svg viewbox="0 0 32 32" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path d="{{ page.data.icon }}"></path>
</svg>
{% endif %}
{% endfor %}
{{ page.url|firstSegment|slugify|capitalize }}</h1>
</header>
<main>
{{content | safe}}
{{ content | safe }}
</main>
</body>
</html>

View file

@ -5,6 +5,6 @@ layout: base
<article>
{{content|safe}}
<section aria-label="Postscript">
{{blurb|safe}} <img src="{{avatar}}">
{{blurb|safe}} <img src="{{avatar}}" alt="Profile picture">
</section>
</article>

View file

@ -3,13 +3,13 @@ layout: base
---
<article id="art">
<h3>{{page.fileSlug}}{%for flag in flags%}<img src="{{flag.src}}">{%endfor%}</h3>
<h1>{{page.fileSlug}}{%for flag in flags%}<img src="{{flag.src}}">{%endfor%}</h1>
{{content|safe}}
<section>
{%for image in images%}
<a href="{{image.src}}">
<figure>
<img src="{{image.src}}" alt="{{image.alt}}" {%if image.pixel%} style="image-rendering: pixelated" {%endif%}>
<img src="{{image.src}}" alt="" {%if image.pixel%} style="image-rendering: pixelated" {%endif%}>
<figcaption>{{image.alt}}</figcaption>
<time datetime="{{image.date|ISO}}">{{image.date|readable}}</time>
</figure>