Grid CSS Reclaim white space

UI Components for JSF
Post Reply
jim.webguru
Posts: 40
Joined: 31 Aug 2011, 05:25

25 Sep 2016, 23:48

I am using a responsive layout with the Volt theme reponsive css and it works just fine when dynamically adding, removing, and expanding elements with javascript. That theme is using classes like Container, ContainerX, Responsive, etc...

I can't get the white space to get recovered when I changed the layout using the Grid CSS. (ui-g, ui-g-x) The containing div retains its height when the child divs are removed. My understanding is that the new Grid CSS is what the new themes are using but I can't use it if the white space doesn't get reclaimed.

Anyone with suggestions?

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

26 Sep 2016, 08:44

My first suggestion would be this: http://stackoverflow.com/help/mcve

jim.webguru
Posts: 40
Joined: 31 Aug 2011, 05:25

26 Sep 2016, 22:06

I didn't add simple test code because I was hinting the general use of the two responsive css layouts. I am using a simple container and atleast two child elements with child divs that get added and removed with javascript. Nothing else tricky.

I figured out my issue. I compared the css for Volt and the one for Grid CSS. Looks like Volt uses the older style elements with display block and float. The Grid CSS uses Flex which seems to be newer in CSS 3. So, that immediately told me it may be a browser issue. The dev environment I am using does not get updated frequently so the version of Chrome was quite old. (Version 34)

I am updating the browser now to see if it corrects this issue. I am hopeful it will fix it.

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

27 Sep 2016, 09:13

jim.webguru wrote:I didn't add simple test code because I was hinting the general use of the two responsive css layouts. I am using a simple container and atleast two child elements with child divs that get added and removed with javascript. Nothing else tricky.
There are simply to many unknown variables when you don't post code that it for you might sound simple/nothing else tricky, but for others like us there might be hidden things etc... So that is why an [mcve] is always required (the PLEASE, PLEASE, PLEASE topic also requests to always post code)

But I hope it works now

jim.webguru
Posts: 40
Joined: 31 Aug 2011, 05:25

27 Sep 2016, 18:47

Understood. I normally do post code but didn't this time. My bad. Thank You.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 35 guests