Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update template basis #156

Merged
merged 1 commit into from
May 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 0 additions & 21 deletions footer.php

This file was deleted.

15 changes: 0 additions & 15 deletions header.php

This file was deleted.

27 changes: 12 additions & 15 deletions views/base.twig
Original file line number Diff line number Diff line change
@@ -1,28 +1,26 @@
{% block html_head_container %}

{% include 'html-header.twig' %}
{% block head %}
{% endblock %}
</head>
<!doctype html>
<html {{ site.language_attributes }}>
{% block head %}
{% include 'head.twig' %}
{% endblock %}

<body class="{{body_class}}" data-template="base.twig">
<body class="{{body_class}}">
{{ function('wp_body_open') }}
<a class="skip-link screen-reader-text" href="#content">{{ _e( 'Skip to content') }}</a>
<header class="header" >
{% block header %}
<div class="wrapper">
<h1 class="hdr-logo" role="banner">
<a class="hdr-logo-link" href="{{site.url}}" rel="home">{{site.name}}</a>
<h1 class="hdr-logo">
<a class="hdr-logo-link" href="{{site.url}}">{{site.name}}</a>
</h1>
<nav id="nav-main" class="nav-main" role="navigation">
<nav id="nav-main" class="nav-main">
{% include "menu.twig" with {'items': menu.get_items} %}
</nav><!-- #nav -->
</div>
{% endblock %}
</header>

<section id="content" role="main" class="content-wrapper">
<section id="content" class="content-wrapper">
{% if title %}<h1>{{title}}</h1>{% endif %}
<div class="wrapper">
{% block content %}
Expand All @@ -37,10 +35,9 @@
</section>

{% block footer %}
<footer id="footer">
{% include 'footer.twig' %}
</footer>
{{ function('wp_footer') }}
{% include 'footer.twig' %}
{% endblock %}
{{ function('wp_footer') }}
{% do action('get_footer') %}
</body>
</html>
4 changes: 3 additions & 1 deletion views/footer.twig
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
Copyright {{"now"|date('Y')}}
<footer id="footer">
Copyright {{"now"|date('Y')}}
</footer>
6 changes: 2 additions & 4 deletions views/html-header.twig → views/head.twig
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
<!doctype html>
<!--[if lt IE 9]><html class="no-js no-svg ie lt-ie9 lt-ie8 lt-ie7" {{ site.language_attributes }}> <![endif]-->
<!--[if IE 9]><html class="no-js no-svg ie ie9 lt-ie9 lt-ie8" {{ site.language_attributes }}> <![endif]-->
<!--[if gt IE 9]><!--><html class="no-js no-svg" {{ site.language_attributes }}> <!--<![endif]-->
<head>
<meta charset="{{ site.charset }}" />
<meta name="description" content="{{ site.description }}">
Expand All @@ -12,4 +8,6 @@
<link rel="author" href="{{ site.theme.link }}/humans.txt" />
<link rel="pingback" href="{{ site.pingback_url }}" />
<link rel="profile" href="http://gmpg.org/xfn/11">
{% do action('get_header') %}
{{function('wp_head')}}
</head>
7 changes: 0 additions & 7 deletions views/page-plugin.twig

This file was deleted.

Loading