From 4dc2e04b4cddecd2bd8f8e01813bde1c068e7a46 Mon Sep 17 00:00:00 2001 From: PC <@> Date: Mon, 25 Nov 2024 11:40:31 +0800 Subject: [PATCH] - --- CrossDown/Core.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CrossDown/Core.py b/CrossDown/Core.py index 609adfd..21dfc96 100644 --- a/CrossDown/Core.py +++ b/CrossDown/Core.py @@ -195,7 +195,7 @@ class InlineCode: """ self.variable = variable - def __call__(self, source: str, language: str, css_class: str, md: markdown.core.Markdown): # 自定义的单行代码格式化器 + def __call__(self, source: str, language: str, css_class: str, md: markdown.core.Markdown) -> str: # 自定义的单行代码格式化器 """ InlineHiliteExtension的自定义格式化器 :param source: 原始单行代码 @@ -288,7 +288,7 @@ def main(text: str, variable: Variable = None) -> tuple[str, Variable]: { 'name': '*', 'class': 'block', - 'format': InlineCode(variable=variable), + 'format': InlineCode(variable=variable), # 传入变量 }, ] ),