feat: add ui examples

This commit is contained in:
sthag 2024-08-15 22:41:12 +02:00
parent 26f5539f3f
commit 3a867c169a
10 changed files with 660 additions and 0 deletions

29
source/templates/demo/_app.njk Executable file
View file

@ -0,0 +1,29 @@
<!-- demo.app.template -->
<!DOCTYPE html>
<html lang="de" class="{{ pageClass }}" id="{{ pageId }}">
<head>
<meta charset="utf-8">
{% block head %}
<title>{{ hippie.titlePrefix }}
{%- block title %}{% endblock %}{{ hippie.titlePostfix }}</title>
{% block meta %}
{% include "demo/partials/_meta.njk" %}
<base href="/">
{% endblock %}
{% block links %}
{% endblock %}
{% endblock %}
</head>
<body class="{{ bodyClass }}">
{% block body %}{% endblock %}
{% block script %}
{% endblock %}
</body>
</html>

View file

@ -0,0 +1,15 @@
<!-- states.macro -->
{% macro coord(id, text='X: #, Y: ##') %}
<span id="{{ id }}">{{ text }}</span>
{% endmacro %}
{% macro time(id, text='00:00:00', postfix=' Uhr') %}
<span id="{{ id }}">{{ text }}</span><span>{{ postfix }}</span>
{% endmacro %}
{% macro date() %}
<span id="{{ id }}">
<span id="day">Wochentag</span>,
<span id="dayNumb">##</span>.
<span id="month">Monat</span>
<span id="year">####</span>
</span>
{% endmacro %}