Files
bridget/layouts/partials/function/currentMenuItem.html
Sped0n 7d4bed3ba6 feat: use absolute URLs for assets
closes #473, closes #476

Signed-off-by: Sped0n <hi@sped0n.com>
2025-11-12 00:10:06 +08:00

18 lines
480 B
HTML

{{- $currentPage := . -}}
{{- $identifier := "" -}}
{{- $title := "404" -}}
{{- $weight := -1 -}}
{{- range site.Menus.main -}}
{{- $menu_item_url := .URL | relLangURL -}}
{{- $page_url:= $currentPage.RelPermalink | relLangURL -}}
{{- if eq $menu_item_url $page_url -}}
{{- $identifier = .Identifier -}}
{{- $title = .Title -}}
{{- $weight = .Weight -}}
{{- end -}}
{{- end -}}
{{- return (dict "Identifier" $identifier "Title" $title "Weight" $weight) -}}