Skip to content

Commit

Permalink
Merge pull request #608 from oat-sa/fix/AUT-3960/gapmatch-cant-remove…
Browse files Browse the repository at this point in the history
…-asset

Fix/AUT-3960/GapMatchinteraction ckeditor console error on image wrap
  • Loading branch information
olga-kulish authored Dec 9, 2024
2 parents 0d1483a + df92011 commit 89b2fdd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/mediaEditor/plugins/mediaAlignment/helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,11 @@ export const positionFloat = function positionFloat(widget, position) {

if (!context.featureFlags['FEATURE_FLAG_DISABLE_FIGURE_WIDGET'] && prevClassName !== className) {
// Re-build Figure widget to toggle between inline/block
const parent = searchRecurse(widget.element.bdy.rootElement.bdy, widget.serial);
const parent = searchRecurse(widget.element.rootElement.bdy, widget.serial);
// If it's Image not Figure (Choice, GapMatch/HotText qti-flow-container)
if (!parent) {
return;
}
// If Figure is not in A-block (Prompt, TextReader PCI)
if (parent.contentModel === 'inlineStatic' || widget.$container.closest('.qti-customInteraction').length) {
_.defer(() => {
Expand Down

0 comments on commit 89b2fdd

Please sign in to comment.