From 8073d2fc6d29ac4a1e72149c587c15ca1f0adf93 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Mon, 16 May 2022 09:42:33 +0200 Subject: [PATCH] Use correct CodeMirror mode for SCSS inputs `sass` is the indentation based SASS syntax. --- wcfsetup/install/files/acp/templates/codemirror.tpl | 2 ++ wcfsetup/install/files/acp/templates/styleAdd.tpl | 4 ++-- wcfsetup/install/files/acp/templates/styleGlobalValues.tpl | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/wcfsetup/install/files/acp/templates/codemirror.tpl b/wcfsetup/install/files/acp/templates/codemirror.tpl index 143a45708b..7f6991cad8 100644 --- a/wcfsetup/install/files/acp/templates/codemirror.tpl +++ b/wcfsetup/install/files/acp/templates/codemirror.tpl @@ -9,6 +9,8 @@ {elseif $codemirrorMode === 'text/x-less'} {* deprecated, legacy support *} 'codemirror/mode/css/css', + {elseif $codemirrorMode === 'text/x-scss'} + 'codemirror/mode/css/css', {else} 'codemirror/mode/{@$codemirrorMode}/{@$codemirrorMode}', {/if} diff --git a/wcfsetup/install/files/acp/templates/styleAdd.tpl b/wcfsetup/install/files/acp/templates/styleAdd.tpl index eb77e0ccde..c1df23fe14 100644 --- a/wcfsetup/install/files/acp/templates/styleAdd.tpl +++ b/wcfsetup/install/files/acp/templates/styleAdd.tpl @@ -1107,7 +1107,7 @@ - {include file='codemirror' codemirrorMode='sass' codemirrorSelector='#individualScssCustom, #overrideScssCustom'} + {include file='codemirror' codemirrorMode='text/x-scss' codemirrorSelector='#individualScssCustom, #overrideScssCustom'} {event name='syntaxFieldsetsCustom'} @@ -1156,7 +1156,7 @@ - {include file='codemirror' codemirrorMode='sass' codemirrorSelector='#individualScss, #overrideScss' editable=$isTainted} + {include file='codemirror' codemirrorMode='text/x-scss' codemirrorSelector='#individualScss, #overrideScss' editable=$isTainted} {event name='syntaxFieldsetsOriginal'} diff --git a/wcfsetup/install/files/acp/templates/styleGlobalValues.tpl b/wcfsetup/install/files/acp/templates/styleGlobalValues.tpl index 21672808ed..77425b4ba5 100644 --- a/wcfsetup/install/files/acp/templates/styleGlobalValues.tpl +++ b/wcfsetup/install/files/acp/templates/styleGlobalValues.tpl @@ -41,7 +41,7 @@ {/if} - {include file='codemirror' codemirrorMode='sass' codemirrorSelector='#styles'} + {include file='codemirror' codemirrorMode='text/x-scss' codemirrorSelector='#styles'} {event name='sections'} -- 2.20.1