Skip to content

Commit

Permalink
modernize
Browse files Browse the repository at this point in the history
(cherry picked from commit 01c7af0)
  • Loading branch information
rhukster authored and gizmecano committed Feb 11, 2020
1 parent f2193b0 commit c1c8910
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 15 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# v1.4.0
## mm/dd/2019

1. [](#new)
* Set Dependency of Grav 1.5.10+ which has support for new **Deferred Block** Twig extension
* Implement assets rendering using **Deferred Block** Twig extension

# v1.3.0
## 07/14/2016

Expand Down
4 changes: 3 additions & 1 deletion blueprints.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Mediator
version: 1.3.0
version: 1.4.0
description: "Mediator theme by Dirk Fabisch ported to **Grav**"
icon: bullseye
author:
Expand All @@ -11,6 +11,8 @@ demo: http://demo.getgrav.org/mediator-skeleton
keywords: mediator, theme, modern, fast, responsive, blog
bugs: https://github.com/getgrav/grav-theme-mediator/issues
license: MIT
dependencies:
- { name: grav, version: '>=1.5.10' }

form:
validation: loose
27 changes: 15 additions & 12 deletions templates/partials/base.html.twig
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="{{ grav.language.getLanguage ?: 'en' }}">
<html lang="{{ grav.language.getActive ?: grav.config.site.default_lang }}">
<head>
<meta charset="utf-8">
<!-- (1) Optimize for mobile versions: http://goo.gl/EOpFl -->
Expand All @@ -8,25 +8,25 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">

<title>{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{{ site.description }}" />

{% include 'partials/metadata.html.twig' %}
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">

{% for meta in page.metadata %}
<meta {% if meta.name %}name="{{ meta.name }}" {% endif %}{% if meta.http_equiv %}http-equiv="{{ meta.http_equiv }}" {% endif %}{% if meta.charset %}charset="{{ meta.charset }}" {% endif %}{% if meta.property %}property="{{ meta.property }}" {% endif %}{% if meta.content %}content="{{ meta.content }}" {% endif %}/>
{% endfor %}

<link rel="canonical" href="{{ page.url() }}">
<link rel="shortcut icon" href="{{ theme_url }}/images/favicon.png">
<link rel="stylesheet" href="http://brick.a.ssl.fastly.net/Linux+Libertine:400,400i,700,700i/Open+Sans:400,400i,700,700i">
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">

{% do assets.addCss('theme://css/main.css') %}
{# {% do assets.addCss('theme://css/print.css') %} #}
{{ assets.css() }}
{% block stylesheets %}
{% do assets.addCss('theme://css/main.css') %}
{# {% do assets.addCss('theme://css/print.css') %} #}
{% endblock %}

{% block assets deferred %}
{{ assets.css()|raw }}
{% endblock %}
</head>
{% block body %}
<body>
Expand Down Expand Up @@ -62,7 +62,10 @@
<!-- footer end -->
{% endblock %}

{% include 'partials/javascripts.html.twig' %}

{% include 'partials/javascripts.html.twig' %}
{% block bottom %}
{{ assets.js()|raw }}
{{ assets.js('bottom')|raw }}
{% endblock %}
</body>
</html>
2 changes: 0 additions & 2 deletions templates/partials/javascripts.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
{% do assets.addJs('theme://js/index.js') %}
{% do assets.addJs('theme://js/readingTime.min.js') %}

{{ assets.js() }}

<script>
(function ($) {
"use strict";
Expand Down

0 comments on commit c1c8910

Please sign in to comment.