mirror of
https://github.com/ZetaKebab/quartz.git
synced 2025-06-22 08:44:36 +00:00
feat(giscus): expose language option for Comments component (#2012)
* add language support for Comment * docs: let users know they can customize their language preference
This commit is contained in:
@ -55,6 +55,7 @@ type GiscusElement = Omit<HTMLElement, "dataset"> & {
|
||||
strict: string
|
||||
reactionsEnabled: string
|
||||
inputPosition: "top" | "bottom"
|
||||
lang: string
|
||||
}
|
||||
}
|
||||
|
||||
@ -78,7 +79,7 @@ document.addEventListener("nav", () => {
|
||||
giscusScript.setAttribute("data-strict", giscusContainer.dataset.strict)
|
||||
giscusScript.setAttribute("data-reactions-enabled", giscusContainer.dataset.reactionsEnabled)
|
||||
giscusScript.setAttribute("data-input-position", giscusContainer.dataset.inputPosition)
|
||||
|
||||
giscusScript.setAttribute("data-lang", giscusContainer.dataset.lang)
|
||||
const theme = document.documentElement.getAttribute("saved-theme")
|
||||
if (theme) {
|
||||
giscusScript.setAttribute("data-theme", getThemeUrl(getThemeName(theme)))
|
||||
|
Reference in New Issue
Block a user