Skip to content

Commit

Permalink
Merge pull request #580 from oat-sa/feature/BSA-391/2.3.0/allow-to-di…
Browse files Browse the repository at this point in the history
…sable-figure-widgets

Feature/BSA-391/2.3.0/Allow to disable figure widgets
  • Loading branch information
jsconan authored Dec 11, 2023
2 parents 0365f86 + e4b27a6 commit e083b6c
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 5 deletions.
28 changes: 26 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@oat-sa/tao-core-ui",
"version": "2.2.0",
"version": "2.3.0",
"displayName": "TAO Core UI",
"description": "UI libraries of TAO",
"scripts": {
Expand Down
5 changes: 3 additions & 2 deletions src/mediaEditor/plugins/mediaAlignment/helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* Copyright (c) 2021-2022 (original work) Open Assessment Technologies SA;
* Copyright (c) 2021-2023 (original work) Open Assessment Technologies SA;
*/
import context from 'context';
import _ from 'lodash';

export const FLOAT_LEFT_CLASS = 'wrap-left';
Expand Down Expand Up @@ -74,7 +75,7 @@ export const positionFloat = function positionFloat(widget, position) {
widget.element.removeAttr('class');
}

if (prevClassName !== className) {
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);
// avoid changes on Figure in a prompt
Expand Down

0 comments on commit e083b6c

Please sign in to comment.