The legacy video uploads page in Studio has been replaced with a new
view in the Authoring MFE. The legacy page has not been available for
some time, so it's all dead code. This PR removes it.
Please note that there's a waffle flag which enables the MFE version
of the video uploads page: `contentstore.new_studio_mfe.use_new_video_uploads_page`.
Unlike the other Studio MFE waffles, we're NOT going to remove this one now,
because the video uploads page has always been broken for sites other
than edx.org (or sites that have reverse-engineered their video pipeline) so
we'd like to keep the flag until it's either fixed for the community or
removed (https://github.com/openedx/openedx-platform/issues/37972).
This work is part of https://github.com/openedx/edx-platform/issues/36108
Co-Authored-By: Kyle McCormick <kyle@axim.org>
- Styles to make component cards selectable.
- Action to select a component and send a message to the parent of the iframe
- Handler for a "deselect all" message and for selecting a specific component
The legacy textbooks page has been replaced with an authoring MFE
equivalent. We don't need to keep the old one around.
This work is part of https://github.com/openedx/edx-platform/issues/36108
BREAKING CHANGE: With this change the `legacy_studio.textbooks` waffle
flag will no longer be respected and the system will behave as if the
flag is always set to False.
The announcements editor was never ported to frontend-app-authoring, and
the announcements display was never ported to frontend-app-learner-dashboard.
This announcements feature is rarely used, undocumented, non-a11y-friendly, and
there were no volunteers to port it to the new frontends. It is the last
remaining part of the legacy Studio "Maintenance" dashboard. So, we are
removing it.
BREAKING CHANGE: This removes...
* Studio Maintenance dashboard legacy frontend
* Studio Edit Announcements legacy frontend
* The snippet of legacy learner dashboard which renders announcements
* openedx/features/announcements djangoapp
* The ENABLE_ANNOUNCEMENTS feature flag
Not removed:
* The announcements_announcement table from openedx/features/announcements .
The table is most likely very small, as it is only populated by administrators. Removing
it would be more labor for us and more risk of toil for operators than is worthwhile.
Closes: https://github.com/openedx/edx-platform/issues/36263
- Adds `blockType` and `is_modified` to the `showXBlockLibraryChangesPreview` iframe message.
- Add title to the `xblock_iframe`
- Add `is-modified` to `studio_xblock_wrapper`
- Add `disable_staff_debug_info` as a query param in `render_xblock`
- `downstream_is_modified` added to ComponentLink and ContainerLink
* feat: allow editing html block imported from upstream
The modified field is left untouched in future sync while storing the
upstream values in hidden fields to allow authors to revert to upstream
version at any point.
* fix: sync downstream_customized field for copy-pasted modified block
* test: add more tests
* fix: lint issues
* test: copy paste
* feat: skip sync if html data is modified
* feat: update upstream fields only when modified
* refactor: use version_synced field to skip sync
* feat: edit title inplace for library source components
* fixup! feat: edit title inplace for library source components
* fix: edit title button style
* fix: test case
* fix: lint issue
* refactor: don't show different icon for modified upstream blocks
* Revert "refactor: use version_synced field to skip sync"
This reverts commit 8b784fff2f49b43702c952e7f955bd4048e8cc69.
* feat: only skip sync for modified blocks if updated as part of container
* refactor: update sync behaviour when synced individually and as part of parent
* feat: include ready to sync children info in downstream link get api
* test: fix failing tests
* fix: lint issues
* feat: new tests and update api to allow overriding modified fields in sync
* test: api changes
* refactor: edit options should be visible for individual imports
* docs: update api docs
* chore: remove old comments
* It was this error 'Uncaught TypeError: el.timepicker is not a function' while rendering the editor. It's fixed adding the timepicker pluging in xblock_v2/xblock_iframe.html
* Added '.openassessment_cancel_button' and '.openassessment_save_button' as action buttons.
* Use openassessment manifest.json to load css from dist
This feature introduces functionalities to improve XBlock interactions within iframes:
* Add styles that adopt default styles for Split Test which renders chromless template via iframe in MFE Authoring.
* When the isIframeEmbed option is enabled, the XBlock sends a postMessage to the parent window. When sending such a message, the standard link transition is cancelled and the transition is carried out in MFE Authoring.
* Adds padding to the text of the competition block editor.
* Fix the style of the Save and Cancel buttons of the PDF block editor.
* Moves the Save and Cancel buttons to the bottom of the modal.
* Moves the Save and Cancel button to the right.
* Which edX user roles will this change impact? "Course Author"
Fixes the styles for the advanced editors (poll, survey, LTI Provider, etc). Updated the code if `xblock_v2/xblock_iframe.html` to use `course-unit-mfe-iframe-bundle.scss`
This introduces improvements for XBlock interactions within iframes:
* Add default styles for Library Content that renders in the iframe in the new Studio unit page
* When the `isIframeEmbed` option is enabled, the XBlock sends a `postMessage` to the parent window. When sending such a message, the standard link transition is cancelled and the transition is carried out in the MFE.
This is part of the effort to support the new Studio Unit Page embedded in the authoring MFE. It introduces several changes to improve the handling of XBlock events and the user interface in the CMS. The most important changes include adding event listeners for message handling, refining the postMessage logic, and updating the CSS for better visual consistency.
This recreates the Zooming Image Tool template for the HTML block. It
does it in such a way that doesn't depend on any external resources:
both the loupe code and sample image are inlined.
Some benefits to this version are:
* We can now maintain the loupe javascript code properly
* Because the javascript is included in the contents of the block
itself, the course author can customize it as needed
* As opposed to the previous iteration, the magnified image URL is now
optional: if it's not present, the regular image will be used for
magnification
* There can now be two or more instances of the tool in the same unit.
This also removes some CSS left over from the previous iteration.
The Studio Maintenance app had two features:
* "Force Course Publish", which literally doesn't do anything. All it
does is tell you what version *would* be seen by users *if* the course
were to be published--no publishing actually occurs via this feature.
* "Announcements", which writes to the announcements_announcement
database table, but doesn't actually display anywhere.
Having these pages in the platform is actively misleading and creates a
maintenance burden for edx-platform developers, so we remove them.
Note that this commit does not include a migration for the announcements
Django app. So, announcements_announcement table will not be deleted.
Given the small expected size of any past-authored announcements, we are
not worried about leaving them in the database perpetually.
* fix: problem block could not be used with versioned handler URls
* refactor: simplify REST API handling of usage keys
* feat: add more version awareness and update tests
* fix: make the preview changes modal bigger as requested
* refactor: parse version at the urlconf layer too
The first attempt at creating a new MFE-driven page for Studio Unit
rendering involved rendering each XBlock separately in its own iframe.
This turned out to be prohibitively slow because of the many redundant
assets and JavaScript processing (e.g. MathJax) that happens for each
XBlock component.
In order to mitigate some of these issues, we decided to try a hybrid
approach where we render the entire Unit's worth of XBlocks at once on
the server side in a Studio view + template, and then invoke that from
frontend-app-authoring as an iframe. The frontend-app-authoring MFE
would still be responsible for displaying most of the interactive UI,
but the per-component actions like "edit" would be triggered by buttons
on the server-rendered Unit display. When one of those buttons is
pressed, the server-rendered UI code in the iframe would use
postMessage to communicate to the frontend-app-authoring MFE, which
would then display the appropriate actions.
To make this work, we're making a new view and template that copies
a lot of existing code used to display the Unit in pre-MFE Studio, and
then modifying that to remove things like the header/footer so that it
can be invoked from an iframe.
This entire design is a compromise in order to do as much of the UI
development in frontend-app-authoring as possible while keeping
XBlock rendering performance tolerable. We hope that we can find
better solutions for this later.
Authored-by: Sagirov Eugeniy <evhenyj.sahyrov@raccoongang.com>
* feat: add share link modal when hide from toc is enabled
Adds a new button in the child subsections of sections with Hide From TOC enabled.
This button displays a new modal with two tabs. The first tab displays a button
that allows you to copy the link of that subsection to the clipboard. The second
tab displays a button that allows you to copy the embedded link of the same
subsection to the clipboard.
Ref: https://openedx.atlassian.net/wiki/spaces/OEPM/pages/3853975595/Feature+Enhancement+Proposal+Hide+Sections+from+course+outline
Exposes the hide_from_toc xblock attribute so course authors can configure it as a section visibility option in Studio. Before this change, the Hide from TOC functionality was mainly used by OLX components. Hence, it wasn't available for configuration through the Studio UI. Still, its implementation existed in the platform and could be used by setting the attribute: hide_from_toc=true as part of the OLX definition.
Ref: https://openedx.atlassian.net/wiki/spaces/OEPM/pages/3853975595/Feature+Enhancement+Proposal+Hide+Sections+from+course+outline
* style: drawer-cover color updated for all tagging drawers
* feat: Update TagList component when a tag is updated on Manage tags drawer
* feat: Refactor TagCount to be able to refresh the count
* feat: Sync tag count in units
Refactors and reworks the LibraryContentBlock so that its
sync-from-library operations are asynchronous and work with
V2 content libraries. This also required us to make
library_content block duplication asynchronous, as that
involves syncing from the source library.
For the sake of clarity, this PR includes two major method renames:
* update_children(...) -> sync_from_library(...)
* refresh_library(...) -> sync_from_library(upgrade_to_latest=True, ...)
an an XBlock HTTP handler rename:
/refresh_children -> /upgrade_and_sync
There are still a couple issues with import or duplication
of library_content blocks referencing V2 libraries other than
latest. These will be resolved in an upcoming PR.
Part of: https://openedx.atlassian.net/wiki/spaces/COMM/pages/3820617729/Spec+Memo+Content+Library+Authoring+Experience+V2
Follow-up work: https://github.com/openedx/edx-platform/issues/33640
Co-authored-by: Connor Haugh <chaugh@2u.com>
Co-authored-by: Eugene Dyudyunov <evgen.dyudyunov@raccoongang.com>