PDA

View Full Version : Collapsible panel width changes



extjser12
12 Mar 2012, 3:41 AM
Hi

If I collapse the "Element 1" and expand it, the width of the panel is not as originally. But much less widely.


Ext.onReady(function() {
Ext.create('Ext.container.Viewport', {
layout: 'border',
items: [{
region: 'north',
autoHeight: true,
border: false,
margins: '0 0 5 0'
}, {
region: 'west',
collapsible: true,
title: 'Navigation',
width: 180,
split: true,
layout: 'fit',
items: [
tree
]
}, {
region: 'center',
border: false,
id:'column-panel',
layout:{
type: 'hbox',
align: 'stretch'
},
bodyStyle: 'padding:5px',
defaults: {bodyStyle:'padding:15px'},
items: [{
title: 'Element 1',
flex: 6,
collapsible: true,
html: '<p>This is some short content.</p>'
},{
xtype: 'fieldcontainer',
title: 'Width = 0.75',
flex: 4,
layout: {
type: 'vbox',
align: 'stretch'
},
items: [{
title: 'Element 2',
collapsible: true,
flex: 1,
html: '<p>This is some longer content.</p><p>This is some longer content.</p><p>This is some longer content.</p><p>This is some longer content.</p><p>This is some longer content.</p><p>This is some longer content.</p>'
}, {
title: 'Element 3',
collapsible: true,
flex: 2,
html: 'Not much here!'
}]
}]
}]
});
})


Can somebody help me to fix this layout problem?

Thanks in advance!
extjser12

mitchellsimoens
12 Mar 2012, 7:48 AM
This looks to be a bug in 4.0.7 that was fixed in 4.1.0

extjser12
12 Mar 2012, 10:53 AM
Can you say me, when the Ext JS version 4.1 is out of the beta stage?

Thanks & regards
extjser12

mitchellsimoens
12 Mar 2012, 10:53 AM
This month more than likely.