From bdac5c9d780cc065da474cc549cec38922c98a55 Mon Sep 17 00:00:00 2001 From: YangFong Date: Tue, 20 Aug 2024 13:21:28 +0800 Subject: [PATCH] feat: add more code block themes (#331) --- .../EditorHeader/StyleOptionMenu.vue | 2 +- src/config/index.js | 110 ++++++++++++++---- 2 files changed, 86 insertions(+), 26 deletions(-) diff --git a/src/components/CodemirrorEditor/EditorHeader/StyleOptionMenu.vue b/src/components/CodemirrorEditor/EditorHeader/StyleOptionMenu.vue index a2ef385..45f5193 100644 --- a/src/components/CodemirrorEditor/EditorHeader/StyleOptionMenu.vue +++ b/src/components/CodemirrorEditor/EditorHeader/StyleOptionMenu.vue @@ -48,7 +48,7 @@ function setStyle(title, value) { {{ props.title }} - + { + const url = `${codeBlockUrlPrefix}${codeBlockTheme}` + const label = codeBlockTheme.replace(`.min.css`, ``) + return { + label, + value: url, + } + }), ] export const legendOptions = [