PDA

View Full Version : White space gaps in ContentPanel



udeleng
18 May 2018, 4:38 PM
We recently upgraded to Sencha GXT 4.0.2, and I was trying to create an Accordion Panel by adding a content panel with a list view. Accordion panel itself creates a content panel with a hidden header internally.

What I noticed is that content panel's body panel (which is wrapped by bodyWrap) is 2 pixels smaller, which create a gap in the ui. So for example the bodyWrap element will have a implicit width of 234 which matches the parent width, but the next inter element "body" will have an explicit of 232. Looking at the dev tools, I don't see any borders, paddings or margins that might affect this. As a results, anything put into the content panel's body is smaller than it should be.

The structure of content panel looks like this, and the gap shows up between bodyWrap and body:

<div class="{style.panel}">
<div class="{style.header}"></div>
<div class="{style.bodyWrap}">
<div class="{style.body}"></div>
<div class="{style.footer}"></div>
</div>
</div>