From 9b8832902cc1a51b5c6e2e0890c576372a60e5e1 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Wed, 10 Mar 2021 16:13:52 +0100 Subject: Initial commit --- resources/views/base.twig | 21 +++++++++++++++++++++ resources/views/components/menu-item.twig | 10 ++++++++++ resources/views/index.twig | 8 ++++++++ resources/views/root.twig | 17 +++++++++++++++++ 4 files changed, 56 insertions(+) create mode 100644 resources/views/base.twig create mode 100644 resources/views/components/menu-item.twig create mode 100644 resources/views/index.twig create mode 100644 resources/views/root.twig (limited to 'resources/views') diff --git a/resources/views/base.twig b/resources/views/base.twig new file mode 100644 index 0000000..c42770a --- /dev/null +++ b/resources/views/base.twig @@ -0,0 +1,21 @@ +{% extends 'root.twig' %} + +{% block body %} +
+ {% block header %} + + {% endblock %} +
+
+ {% block main %}{% endblock %} +
+ +{% endblock %} diff --git a/resources/views/components/menu-item.twig b/resources/views/components/menu-item.twig new file mode 100644 index 0000000..5bc41fc --- /dev/null +++ b/resources/views/components/menu-item.twig @@ -0,0 +1,10 @@ +
  • + {{ item.title }} + {% if current_depth < depth and item.children %} + + {% endif %} +
  • diff --git a/resources/views/index.twig b/resources/views/index.twig new file mode 100644 index 0000000..48b345c --- /dev/null +++ b/resources/views/index.twig @@ -0,0 +1,8 @@ +{% extends 'base.twig' %} + +{% block main %} + {% for post in posts %} +

    {{ post.title }}

    +

    {{ post.content }}

    + {% endfor %} +{% endblock %} diff --git a/resources/views/root.twig b/resources/views/root.twig new file mode 100644 index 0000000..3075eba --- /dev/null +++ b/resources/views/root.twig @@ -0,0 +1,17 @@ + + + + + + + + {% block meta %}{% endblock %} + {{ function('wp_head') }} + {% block css %}{% endblock %} + + +{% block body %}{% endblock %} +{{ function('wp_footer') }} +{% block js %}{% endblock %} + + -- cgit v1.2.3