You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The built-in HTML block's display JS (xmodule/js/src/html/display.js, bundled as HtmlBlockDisplay with collapsible.js, javascript_loader.js and imageModal.js) did four things when a block rendered. The extracted HtmlBlock (xblock_html/block.py, student_view) only does one of them, MathJax typesetting. The other three legacy content features no longer work:
Collapsible sections:Collapsible.setCollapsibles() hid .longform content and added "See full output" / "Hide output" links to .shortform.
Full-screen image modal:setupFullScreenModal() turned .image-modal markup into a zoomable, draggable full-screen image.
Script placeholders:JavascriptLoader.executeModuleScripts() loaded .script_placeholder elements (data-src) as scripts, in order.
openedx/openedx-platform#38748 removed the built-in HTML block, and these features have been off since the extracted block became the default. Content that relies on this markup now shows the long form expanded, a plain image, or nothing for the placeholder scripts.
This is mostly old (2012–2014 era) content, so it's worth deciding whether to:
port these behaviors into xblock_html (the JS is small; imageModal.js needs draggabilly), or
document them as removed, with how course teams can do the same with their own <script>.
I found this by diffing the built-in block's JS against the extracted one. I haven't checked how common this markup is in real courses.
Activity