PDA

View Full Version : Dynamic height and width for an Ext.Msg window



force45
13 Aug 2018, 6:50 AM
I have a warning overlay that I display like so:


Ext.Msg.show({
title: 'title',
msg: 'message'.
buttons: Ext.Msg.OKCANCEL,
icon: Ext.Msg.WARNING,
});

However, the content displayed can be of variable length and can sometimes take up more than a single line with the default dimensions of the overlay. To handle this I set a width property to the above code like so:


Ext.Msg.show({
title: 'title',
msg: 'message'.
buttons: Ext.Msg.OKCANCEL,
icon: Ext.Msg.WARNING,
minWidth: 900,
width: 900
});


This solved the issue with the horizontal width; However, an additional space gets added to the bottom of the grid with every entry. I have attached an example below.
57663

This space seems to be a result of the overlay calculating the height before the new width (of 900) is set. As the height does not get set again, an additional space is left behind once the message is stretched horizontally. Would appreciate a few pointers on how to get this fixed. Thanks!

Forum_Adm
8 Sep 2018, 8:02 AM
Thank you for your patience! I have sent this over to a team member to assist you. We will be in touch as soon as possible.