1
0
mirror of https://github.com/alanorth/hugo-theme-bootstrap4-blog.git synced 2025-05-07 21:16:00 +02:00

layouts: Set dir="auto" on some HTML elements

When a site is rendered in Arabic the root HTML element gets the
dir="rtl" attribute, but even Arabic sites might have an English
title or footer, etc so we should set dir="auto" on those elements.
This commit is contained in:
2019-04-18 23:38:53 +03:00
parent 2db85d8ab6
commit 9934368215
2 changed files with 4 additions and 4 deletions

View File

@ -55,8 +55,8 @@
{{ if (ne .Site.Params.header_visible false) }}
<header class="blog-header">
<div class="container">
<h1 class="blog-title"><a href="{{ .Site.BaseURL }}" rel="home">{{ .Site.Title | safeHTML }}</a></h1>
{{ if .Site.Params.description }}<p class="lead blog-description">{{ .Site.Params.description | markdownify }}</p>{{ end }}
<h1 class="blog-title" dir="auto"><a href="{{ .Site.BaseURL }}" rel="home">{{ .Site.Title | safeHTML }}</a></h1>
{{ if .Site.Params.description }}<p class="lead blog-description" dir="auto">{{ .Site.Params.description | markdownify }}</p>{{ end }}
</div>
</header>
{{ end }}
@ -81,7 +81,7 @@
{{ block "footer" . }}
<footer class="blog-footer">
<p>
<p dir="auto">
{{ if .Site.Copyright }}
{{ .Site.Copyright | markdownify }}
{{ else }}