Commit 9ae85583 by Chris Dodge

put htmlmixed.js and css.js includes in CMS base.html so that we can support…

put htmlmixed.js and css.js includes in CMS base.html so that we can support html mode in CodeMirror
parent 0be0889d
...@@ -33,6 +33,8 @@ ...@@ -33,6 +33,8 @@
<script src="${static.url('js/vendor/jquery.leanModal.min.js')}"></script> <script src="${static.url('js/vendor/jquery.leanModal.min.js')}"></script>
<script src="${static.url('js/vendor/jquery.tablednd.js')}"></script> <script src="${static.url('js/vendor/jquery.tablednd.js')}"></script>
<script src="${static.url('js/vendor/jquery.form.js')}"></script> <script src="${static.url('js/vendor/jquery.form.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/CodeMirror/htmlmixed.js')}"></script>
<script type="text/javascript" src="${static.url('js/vendor/CodeMirror/css.js')}"></script>
<script type="text/javascript"> <script type="text/javascript">
document.write('\x3Cscript type="text/javascript" src="' + document.write('\x3Cscript type="text/javascript" src="' +
document.location.protocol + '//www.youtube.com/player_api">\x3C/script>'); document.location.protocol + '//www.youtube.com/player_api">\x3C/script>');
......
class @HTMLEditingDescriptor class @HTMLEditingDescriptor
constructor: (@element) -> constructor: (@element) ->
@edit_box = CodeMirror.fromTextArea($(".edit-box", @element)[0], { @edit_box = CodeMirror.fromTextArea($(".edit-box", @element)[0], {
mode: "text/html"
lineNumbers: true lineNumbers: true
lineWrapping: true lineWrapping: true
}) })
......
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