From e50d1cc83b79ca38c9e1fd8e91896ccaed634675 Mon Sep 17 00:00:00 2001 From: Feanil Patel Date: Fri, 10 Oct 2025 15:30:39 -0400 Subject: [PATCH] feat: Drop the unused edit view template. And update the studio-view function to raise a NotImplementedError since we now rely on the authoring environment to provide the edit view of this block. Unfortunately, a copy of the template lives in the lms and relies on the the underlying JS and CSS to render a tiny-mce editor in the instructor dashboard. This means we can't remove the CSS and JS until we've dropped the usage of it in the instructor dash. The good news is, that the work to replace the instructor dash is in progress so those assets should get cleaned up soon. The places where the JS and CSS is still being used are: * lms/templates/instructor/instructor_dashboard_2/instructor_dashboard_2.html * lms/djangoapps/instructor/views/instructor_dashboard.py --- cms/templates/widgets/html-edit.html | 13 ------------- xmodule/html_block.py | 8 +------- 2 files changed, 1 insertion(+), 20 deletions(-) delete mode 100644 cms/templates/widgets/html-edit.html diff --git a/cms/templates/widgets/html-edit.html b/cms/templates/widgets/html-edit.html deleted file mode 100644 index 8074e0d583..0000000000 --- a/cms/templates/widgets/html-edit.html +++ /dev/null @@ -1,13 +0,0 @@ -<%! from django.utils.translation import gettext as _ %> - -
-
-
- % if editor == 'visual': - - % endif - -
-
-
-<%include file="metadata-edit.html" /> diff --git a/xmodule/html_block.py b/xmodule/html_block.py index 3067a7cf9b..e4a9250a14 100644 --- a/xmodule/html_block.py +++ b/xmodule/html_block.py @@ -142,13 +142,7 @@ class HtmlBlockMixin( # lint-amnesty, pylint: disable=abstract-method """ Return the studio view. """ - fragment = Fragment( - self.runtime.service(self, 'mako').render_cms_template(self.mako_template, self.get_context()) - ) - add_css_to_fragment(fragment, 'HtmlBlockEditor.css') - add_webpack_js_to_fragment(fragment, 'HtmlBlockEditor') - shim_xmodule_js(fragment, 'HTMLEditingDescriptor') - return fragment + raise NotImplementedError @classmethod def get_customizable_fields(cls) -> dict[str, str | None]: