Commit 40fcee23 authored by Jérome Perrin's avatar Jérome Perrin

codemirror: support html files in ZMI

(cherry picked from commit 3d7289b9)
parent 7ae732b7
...@@ -51,6 +51,11 @@ def manage_page_footer(self): ...@@ -51,6 +51,11 @@ def manage_page_footer(self):
mode = 'javascript' mode = 'javascript'
elif 'css' in document.getContentType(): elif 'css' in document.getContentType():
mode = 'css' mode = 'css'
elif 'html' in document.getContentType():
if editor == 'codemirror':
mode = 'htmlmixed'
else:
mode = 'html'
textarea_selector = 'textarea[name="filedata:text"]' textarea_selector = 'textarea[name="filedata:text"]'
elif document.meta_type in ('Script (Python)', ): elif document.meta_type in ('Script (Python)', ):
mode = 'python' mode = 'python'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment