projects
/
roojs1
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e2c994e
)
Roo/htmleditor/BlockFigure.js
author
Alan
<alan@roojs.com>
Wed, 5 Jan 2022 04:58:13 +0000
(12:58 +0800)
committer
Alan
<alan@roojs.com>
Wed, 5 Jan 2022 04:58:13 +0000
(12:58 +0800)
Roo/htmleditor/BlockFigure.js
patch
|
blob
|
history
diff --git
a/Roo/htmleditor/BlockFigure.js
b/Roo/htmleditor/BlockFigure.js
index
c52c260
..
016bceb
100644
(file)
--- a/
Roo/htmleditor/BlockFigure.js
+++ b/
Roo/htmleditor/BlockFigure.js
@@
-196,6
+196,8
@@
Roo.extend(Roo.htmleditor.BlockFigure, Roo.htmleditor.Block, {
var d = document.createElement('div');
d.innerHTML = this.caption;
+ var m = this.width == '50%' && this.align == 'center' ? '0 auto' : 0;
+
return {
tag: 'figure',
'data-block' : 'Figure',
@@
-205,7
+207,7
@@
Roo.extend(Roo.htmleditor.BlockFigure, Roo.htmleditor.Block, {
float : this.align ,
'max-width': this.width,
width : 'auto',
- margin:
0
,
+ margin:
m
,
padding: '10px'
},