Skip to content

Commit

Permalink
Merge pull request #213 from fortunatomaldonado/LPD-34946
Browse files Browse the repository at this point in the history
LPD-34946 Check if values are empty and delete styles when not used
  • Loading branch information
markocikos committed Aug 29, 2024
2 parents 6dd0fb9 + 1c0304c commit 88be248
Show file tree
Hide file tree
Showing 23 changed files with 173 additions and 157 deletions.
264 changes: 132 additions & 132 deletions ckeditor/ckeditor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/kama/editor.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/kama/editor_ie.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/kama/editor_ie7.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/kama/editor_ie8.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/kama/editor_iequirks.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lexicon/editor.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lexicon/editor_gecko.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lexicon/editor_ie.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lexicon/editor_ie8.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lexicon/editor_iequirks.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lisa/editor.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lisa/editor_gecko.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lisa/editor_ie.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lisa/editor_ie8.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono-lisa/editor_iequirks.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor_gecko.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor_ie.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor_ie7.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor_ie8.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion ckeditor/skins/moono/editor_iequirks.css

Large diffs are not rendered by default.

24 changes: 20 additions & 4 deletions plugins/imagespacingbox/plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,18 +57,26 @@

var hspace = widget.data.hspace
? widget.data.hspace
: 0;
: '';

var imageElement =
widget.parts.image;

if (imageElement) {
if (imageElement && hspace !== '') {
imageElement.setStyles({
'margin-left':
hspace + 'px',
'margin-right':
hspace + 'px',
});
} else {
imageElement.removeStyle(
'margin-left'
);

imageElement.removeStyle(
'margin-right'
);
}
},
id: 'hspace',
Expand Down Expand Up @@ -127,17 +135,25 @@

var vspace = widget.data.vspace
? widget.data.vspace
: 0;
: '';

var imageElement =
widget.parts.image;

if (imageElement) {
if (imageElement && vspace !== '') {
imageElement.setStyles({
'margin-bottom':
vspace + 'px',
'margin-top': vspace + 'px',
});
} else {
imageElement.removeStyle(
'margin-bottom'
);

imageElement.removeStyle(
'margin-top'
);
}
},
id: 'vspace',
Expand Down

0 comments on commit 88be248

Please sign in to comment.