From: Raphaƫl Gertz Date: Tue, 14 Oct 2025 09:45:25 +0000 (+0200) Subject: New context layout X-Git-Tag: 0.0.1~38 X-Git-Url: https://git.rapsys.eu/blogbundle/commitdiff_plain/71c7bfea3fba239721455861c4f430a3e7ec424a?ds=inline New context layout --- diff --git a/Resources/views/_base.html.twig b/Resources/views/_base.html.twig index 7e2c170..0b103c0 100644 --- a/Resources/views/_base.html.twig +++ b/Resources/views/_base.html.twig @@ -1,18 +1,57 @@ - - - {% block head %} - - {{ head.title }} + + + {% block meta %}{% endblock %} + {% block title %}{{ [title.page, title.section, title.site]|filter(v => v)|join(' - ') }}{% endblock %} + {% block stylesheet %} - {% if head.description is defined and head.description %} - + {% if description is defined and description %} + {% endif %} - {% if head.keywords is defined and head.keywords %} - + {% if keywords is defined and keywords %} + {% endif %} - {% if head.facebook is defined and head.facebook %} - {% for property, contents in head.facebook %} + {% if icon is defined and icon %} + + + {% for size, icon in icon.png %} + {# Apple #} + {% if size in [120, 152, 167, 180] %} + {% if size == 180 %} + + {% endif %} + + {# Windows #} + {% elseif size in [70, 150, 310] %} + + {# Others #} + {% else %} + + {% endif %} + {% endfor %} + {% endif %} + {% stopwatch 'stylesheet' %} + {# stylesheet '//fonts.googleapis.com/css?family=Irish+Grover' '//fonts.googleapis.com/css?family=La+Belle+Aurore' '@RapsysBlogBundle/css/{reset,screen}.css' #} + {% stylesheet '@RapsysBlog/css/{reset,droidsans,lemon,notoemoji,screen}.css' %} + + {% endstylesheet %} + {% endstopwatch %} + {% if canonical is defined and canonical %} + + {% endif %} + {% if alternates is defined and alternates %} + {% for lang, alternate in alternates %} + + {% endfor %} + {% endif %} + {% if prev is defined and prev %} + + {% endif %} + {% if next is defined and next %} + + {% endif %} + {% if facebook is defined and facebook %} + {% for property, contents in facebook %} {% if contents is iterable %} {% for content in contents %} @@ -22,86 +61,49 @@ {% endif %} {% endfor %} {% endif %} - {% block link %} - {% if head.icon.ico is defined and head.icon.ico is not empty %} - - {% endif %} - {% if head.icon.png is defined and head.icon.png is not empty %} - {% for size, icon in head.icon.png %} - {# Apple #} - {% if size in [120, 152, 167, 180] %} - {% if size == 180 %} - - {% endif %} - - {# Windows #} - {% elseif size in [70, 150, 310] %} - - {# Others #} - {% else %} - - {% endif %} - {% endfor %} - {% endif %} - {% if head.icon.svg is defined and head.icon.svg is not empty %} - - {% endif %} - {# stylesheet '//fonts.googleapis.com/css?family=Irish+Grover' '//fonts.googleapis.com/css?family=La+Belle+Aurore' '@RapsysBlogBundle/Resources/public/css/{reset,screen}.css' #} - {% stylesheet '@RapsysBlog/css/{reset,droidsans,lemon,notoemoji,screen}.css' %} - - {% endstylesheet %} - {% stopwatch 'stylesheet' %} - {% endstopwatch %} - {% if head.canonical is defined and head.canonical %} - - {% endif %} - {% if head.alternates is defined and head.alternates %} - {% for lang, alternate in head.alternates %} - - {% endfor %} - {% endif %} - {% if head.prev is defined and head.prev %} - - {% endif %} - {% if head.next is defined and head.next %} - - {% endif %} - {% endblock %} {% endblock %} {% block body %} {% block header %} {% endblock %} {% block message %} @@ -118,41 +120,41 @@ {% endif %} {% endfor %} {% endblock %} - {% endblock %} - {#{% block sidebar %}{% endblock %}#} - {% block content %} -
-
- {% block title %}

{{ title }}

{% endblock %}> -

{{ description }}

-
-
- {% endblock %} - {% block footer %} - + {% endblock %} {% endblock %} - {% block javascripts %} + {% block javascript %} {% stopwatch 'javascript' %} {#{% javascript '@RapsysBlog/js/*.js' %}