Loading ...
Sorry, an error occurred while loading the content.

Re: [ydn-javascript] 1/5 grids

Expand Messages
  • Nate Koechley
    Hi Benjamin and Brendan, YUI does not support 5 even columns at this point. You re welcome to log it as a feature request:
    Message 1 of 2 , Feb 4, 2008
    • 0 Attachment
      Hi Benjamin and Brendan,

      YUI does not support 5 even columns at this point. You're welcome to log it as a feature request:


      If you decide to customize your own based on Grids, I recommend that you examine how the special grid holder "gb" works. Basically, for all the .yui-u children of your grid holder, float them all left, give them all widths somewhere under 20%, and left-margin values as your desire. First the div.first child of your grid holder, set the margin-left to zero. Remember that the five widths plus the four left margins much equal 100%.

      If you're following Grids' lead and setting all these values in %, not that you need to test extensively since %-of-pixels often encounter rounding issues where the width of your five columns may be +/- 1 pixel in certain browsers. (If you set things in pixels across the board, you gain precision but users look the ability to zoom in some browsers.) This inconsistency is the primary reason Grids does not support fifths out of the box. 

      Good luck. Hope that helps a bit.

      Thanks,
      Nate


      On Jan 28, 2008, at 11:44 AM, benjamin.renaud wrote:


      First, congrats on YUI. It's a very nice piece of work.

      Second, I am pretty new to this still, but is there a way to setup a
      1/5 grid? I am trying to get a grid with 20% for each elements on the
      grid, and the current values make that impossible. Can I customize the
      %width of the grid element, or could you guys provide an grid like that?

      Thanks!
      Benjamin


    Your message has been successfully submitted and would be delivered to recipients shortly.