Skip to content

Commit

Permalink
Issue #112: Make sure the class is only added once (#118)
Browse files Browse the repository at this point in the history
  • Loading branch information
indigoxela authored Jun 25, 2024
1 parent 5338b31 commit d28c77a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion js/tinymce-integration.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@
options.convert_urls = false;

// Add tiny's skin name to body classes for easier styling.
$('body').addClass('tinymce-skin-' + options.skin);
let skinClass = 'tinymce-skin-' + options.skin;
if (!$('body').hasClass(skinClass)) {
$('body').addClass(skinClass);
}

// Additional variables from hook.
for (let item in format.editorSettings.backdrop) {
Expand Down

0 comments on commit d28c77a

Please sign in to comment.