mirror of
https://github.com/alanorth/hugo-theme-bootstrap4-blog.git
synced 2024-12-25 03:34:29 +01: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:
parent
2db85d8ab6
commit
9934368215
@ -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 }}
|
||||
|
@ -2,7 +2,7 @@
|
||||
{{ if and (.Site.Params.sidebar) (isset .Site.Params.sidebar "about") }}
|
||||
<section class="sidebar-module sidebar-module-inset">
|
||||
<h4>{{ i18n "about" }}</h4>
|
||||
<p>{{ .Site.Params.sidebar.about | markdownify }}</p>
|
||||
<p dir="auto">{{ .Site.Params.sidebar.about | markdownify }}</p>
|
||||
</section>
|
||||
{{ end }}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user