Remove the live preview code from the html and raw modules, in preparation for updating the preview on save
This commit is contained in:
@@ -4,7 +4,6 @@ from lxml import etree
|
||||
|
||||
from xmodule.x_module import XModule
|
||||
from xmodule.raw_module import RawDescriptor
|
||||
from pkg_resources import resource_string
|
||||
|
||||
log = logging.getLogger("mitx.courseware")
|
||||
|
||||
@@ -26,9 +25,6 @@ class HtmlDescriptor(RawDescriptor):
|
||||
module_class = HtmlModule
|
||||
filename_extension = "html"
|
||||
|
||||
js = {'coffee': [resource_string(__name__, 'js/module/html.coffee')]}
|
||||
js_module = 'HTML'
|
||||
|
||||
# TODO (cpennington): Delete this method once all fall 2012 course are being
|
||||
# edited in the cms
|
||||
@classmethod
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
class @HTML
|
||||
constructor: (@element) ->
|
||||
@edit_box = $(".edit-box", @element)
|
||||
@preview = $(".preview", @element)
|
||||
@edit_box.on('input', =>
|
||||
@preview.empty().append(@edit_box.val())
|
||||
)
|
||||
|
||||
save: -> @edit_box.val()
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
class @Raw
|
||||
constructor: (@element) ->
|
||||
@edit_box = $(".edit-box", @element)
|
||||
@preview = $(".preview", @element)
|
||||
@edit_box.on('input', =>
|
||||
@preview.empty().text(@edit_box.val())
|
||||
)
|
||||
|
||||
save: -> @edit_box.val()
|
||||
|
||||
Reference in New Issue
Block a user