moved the sitetitle and sitebase options to the [metadata] section
This commit is contained in:
parent
1663d178ca
commit
a4ddb02bfe
|
@ -41,12 +41,6 @@ tldr = "clipboard-list"
|
|||
todo = "circle-check"
|
||||
warning = "triangle-alert"
|
||||
|
||||
[generate]
|
||||
# The site base URL. If supplied, this will be added to a <base> element in the page metadata.
|
||||
sitebase = ""
|
||||
# The site title. If supplied, this will be included in page metadata and used to formulate the default title.
|
||||
sitetitle = ""
|
||||
|
||||
[templates]
|
||||
# The template directory name under the Obsidian vault. Default is ".dragonglass.tmpl".
|
||||
directory = ".dragonglass.tmpl"
|
||||
|
@ -58,3 +52,7 @@ stylesheet = "dragonglass.css"
|
|||
[metadata]
|
||||
# If true, use page title as default description.
|
||||
description-title = false
|
||||
# The site base URL. If supplied, this will be added to a <base> element in the page metadata.
|
||||
sitebase = ""
|
||||
# The site title. If supplied, this will be included in page metadata and used to formulate the default title.
|
||||
sitetitle = ""
|
||||
|
|
|
@ -109,13 +109,13 @@ class Context:
|
|||
@property
|
||||
def site_base(self) -> str | None:
|
||||
"""Returns the configured site base URL."""
|
||||
generate_section = self.config.get("generate", {})
|
||||
generate_section = self.config.get("metadata", {})
|
||||
return generate_section.get("sitebase", None)
|
||||
|
||||
@property
|
||||
def site_title(self) -> str | None:
|
||||
"""Returns the configured site title."""
|
||||
generate_section = self.config.get("generate", {})
|
||||
generate_section = self.config.get("metadata", {})
|
||||
return generate_section.get("sitetitle", None)
|
||||
|
||||
@property
|
||||
|
|
Loading…
Reference in New Issue
Block a user