documents panel: properly compute margin on resize
This commit is contained in:
parent
a2d5f74a91
commit
2dae77989c
1 changed files with 7 additions and 5 deletions
|
@ -710,14 +710,16 @@ pandora.ui.documentsPanel = function(options) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function resizeItem() {
|
function resizeItem() {
|
||||||
var inputWidth = ui.documentSize - 16 - Ox.UI.SCROLLBAR_SIZE,
|
var size = getPreviewSize(),
|
||||||
previewSize = getPreviewSize();
|
width = ui.documentSize - 16 - Ox.UI.SCROLLBAR_SIZE;
|
||||||
$preview.options({
|
$preview.options({
|
||||||
height: previewSize.height,
|
height: size.height,
|
||||||
width: previewSize.width
|
width: size.width
|
||||||
|
}).css({
|
||||||
|
margin: size.margin
|
||||||
});
|
});
|
||||||
$form.options('items').forEach(function($item) {
|
$form.options('items').forEach(function($item) {
|
||||||
$item.options({width: inputWidth});
|
$item.options({width: width});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue