From 3007b202a82244676c9e9813ec897164f754caee Mon Sep 17 00:00:00 2001 From: George M Dias Date: Wed, 18 Dec 2024 12:02:56 -0600 Subject: [PATCH] fixed vuepress theme v64 dark/light mode issue Signed-off-by: George M Dias --- src/.vuepress/theme.ts | 70 +++++------------------------------------- 1 file changed, 7 insertions(+), 63 deletions(-) diff --git a/src/.vuepress/theme.ts b/src/.vuepress/theme.ts index cfb449519..a1ce3271e 100644 --- a/src/.vuepress/theme.ts +++ b/src/.vuepress/theme.ts @@ -37,7 +37,13 @@ export default hopeTheme({ imgLazyload: true, imgSize: true, include: true, - mark: true, + // imgMark: true, + imgMark: { + /** lightmode only IDs */ + light: ["light"], + /** darkmode only IDs */ + dark: ["dark"], + }, mermaid: true, playground: { presets: ["ts", "vue"], @@ -80,68 +86,6 @@ export default hopeTheme({ components: ["Badge", "VPCard"], }, - // Use "mark: true" to allow pictures to be marked by #light or #dark - // suffix, letting them be displayed under the appropriate color mode - markdownImage: { - figure: true, - lazyload: true, - mark: true, - size: true, - }, - - markdownTab: { - codeTabs: true, - tabs: true, - }, - - // All features are enabled for demo, only preserve features you need here - mdEnhance: { - align: true, - attrs: true, - // install chart.js before enabling it - // chart: true, - component: true, - demo: true, - // install echarts before enabling it - // echarts: true, - // install flowchart.ts before enabling it - flowchart: true, - gfm: true, - include: true, - // install katex before enabling it - // katex: true, - // install mathjax-full before enabling it - // mathjax: true, - mark: true, - mermaid: true, - // plantuml: true, - playground: { - presets: ["ts", "vue"], - }, - // install sandpack-vue3 before enabling it - // sandpack: true, - // spoiler: true, - stylize: [ - { - matcher: "Recommended", - replacer: ({ tag }) => { - if (tag === "em") - return { - tag: "Badge", - attrs: { type: "tip" }, - content: "Recommended", - }; - }, - }, - ], - sub: true, - sup: true, - // tasklist: true, - vPre: true, - // install @vue/repl before enabling it - // vuePlayground: true, - }, - // install reveal.js before enabling it // revealjs: { // plugins: ["highlight", "math", "search", "notes", "zoom"],