mirror of
https://github.com/tcsenpai/obsidiangarden_netlify.git
synced 2025-06-06 04:35:20 +00:00
Adds user selected language in <html lang=""> (#208)
This commit uses the SITE_MAIN_LANGUAGE set in the .env for all lang attributes in html elements. This improves accessibility.
This commit is contained in:
parent
c44066a556
commit
9d74cb1997
@ -1,6 +1,6 @@
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="{{ meta.mainLanguage }}">
|
||||
<head>
|
||||
<title>Nothing here</title>
|
||||
<link href="/styles/digital-garden-base.css" rel="stylesheet">
|
||||
|
@ -48,7 +48,7 @@ module.exports = async (data) => {
|
||||
bodyClasses.push("backlinks-note-icon");
|
||||
noteIconsSettings.backlinks = true;
|
||||
}
|
||||
if(styleSettingsCss){
|
||||
if (styleSettingsCss) {
|
||||
bodyClasses.push("css-settings-manager");
|
||||
}
|
||||
|
||||
@ -66,6 +66,7 @@ module.exports = async (data) => {
|
||||
timestampSettings,
|
||||
baseTheme: process.env.BASE_THEME || "dark",
|
||||
siteName: process.env.SITE_NAME_HEADER || "Digital Garden",
|
||||
mainLanguage: process.env.SITE_MAIN_LANGUAGE || "en",
|
||||
siteBaseUrl: baseUrl,
|
||||
styleSettingsCss,
|
||||
buildDate: new Date(),
|
||||
|
@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="{{ meta.mainLanguage }}">
|
||||
<head>
|
||||
<title>{% if title %}{{ title }}{% else %}{{ page.fileSlug }}{% endif %}</title>
|
||||
{%include "components/pageheader.njk"%}
|
||||
|
@ -2,7 +2,7 @@
|
||||
permalink: "notes/{{ page.fileSlug | slugify }}/"
|
||||
---
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="{{ meta.mainLanguage }}">
|
||||
<head>
|
||||
<title>{% if title %}{{ title }}{% else %}{{ page.fileSlug }}{% endif %}</title>
|
||||
{%include "components/pageheader.njk"%}
|
||||
|
Loading…
x
Reference in New Issue
Block a user