From 8cc38f6ca319684ec1229d2bfb52f28c5107d204 Mon Sep 17 00:00:00 2001 From: Cell <1024@lruihao.cn> Date: Mon, 15 Sep 2025 21:02:07 +0800 Subject: [PATCH] fix: update MathJax options to disable menu when explicitly set to false --- layouts/_partials/assets.html | 4 ++-- layouts/_partials/init/index.html | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/layouts/_partials/assets.html b/layouts/_partials/assets.html index ff4d3798..a8e6e6e6 100644 --- a/layouts/_partials/assets.html +++ b/layouts/_partials/assets.html @@ -112,8 +112,8 @@ {{- $options := dict "targetPath" "js/lib/mathjax.min.js" "minify" hugo.IsProduction -}} {{- $mathjaxOptsConfig := $mathjax.options | default dict -}} {{- $mathjaxOpts := dict -}} - {{- with $mathjaxOptsConfig.enableMenu -}} - {{- $mathjaxOpts = dict "enableMenu" . | merge $mathjaxOpts -}} + {{- if eq $mathjaxOptsConfig.enableMenu false -}} + {{- $mathjaxOpts = dict "enableMenu" false | merge $mathjaxOpts -}} {{- end -}} {{- with $mathjaxOptsConfig.ignoreHtmlClass -}} {{- $mathjaxOpts = dict "ignoreHtmlClass" . | merge $mathjaxOpts -}} diff --git a/layouts/_partials/init/index.html b/layouts/_partials/init/index.html index f179e579..2b68f666 100644 --- a/layouts/_partials/init/index.html +++ b/layouts/_partials/init/index.html @@ -1,4 +1,4 @@ -{{- hugo.Store.Set "version" "v0.4.0-alpha.2-20250912202339-c430a012" -}} +{{- hugo.Store.Set "version" "v0.4.0-alpha.2-20250915130208-81c333ca" -}} {{- .Store.Set "this" dict -}} {{- partial "init/detection-env.html" . -}}