Improve katex markdown

This commit is contained in:
cuom1999 2024-02-05 18:32:08 -06:00
parent 08d2437d49
commit c87566673a
4 changed files with 16 additions and 19 deletions

View file

@ -6,7 +6,7 @@ from pymdownx import superfences
EXTENSIONS = [
# "pymdownx.arithmatex",
"pymdownx.arithmatex",
"pymdownx.magiclink",
"pymdownx.betterem",
"pymdownx.details",
@ -25,6 +25,9 @@ EXTENSIONS = [
]
EXTENSION_CONFIGS = {
"pymdownx.arithmatex": {
"generic": True,
},
"pymdownx.superfences": {
"custom_fences": [
{
@ -83,7 +86,6 @@ def markdown(value, lazy_load=False):
value, extensions=extensions, extension_configs=EXTENSION_CONFIGS
)
soup = BeautifulSoup(html, "html.parser")
html = bleach.clean(html, tags=ALLOWED_TAGS, attributes=ALLOWED_ATTRS)
if not html:

View file

@ -46,7 +46,6 @@ def problem_update(sender, instance, **kwargs):
cache.delete_many(
[
make_template_fragment_key("submission_problem", (instance.id,)),
make_template_fragment_key("problem_feed", (instance.id,)),
"problem_tls:%s" % instance.id,
"problem_mls:%s" % instance.id,
]