kirubaharan12345 / blueprintcss

Automatically exported from code.google.com/p/blueprintcss
0 stars 0 forks source link

class '.clear' does not work in IE7 #59

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hey guys,
I could be mistaken, but it looks like the blueprint grid.css file is 
missing this statement to have the class '.clear' work correctly in IE7:
*:first-child+html .clear { min-height: 1px; }

the IE hack it has is:
* html .clear { height: 1%; }
but that only works in IE6, not IE7.

here is some sample markup:
<style type="text/css">
  #wrapper { border: 1px solid red; padding: 1em; }
  #main_col {
    float: right;
    border: 1px solid blue;
  }
  #sidebar_col {
    float: left;
    border: 1px solid green;
  }
</style>
<div id='wrapper' class='clear'>
  <div id='main_col'>float me left</div>
  <div id='sidebar_col'>float me right</div>
</div>

w/o the blueprint grid.css fix, you'll see a red line across the top, but
not enclosing main_col and sidebar_col.  
With the fix, the red box will wrap the main_col and sidebar_col

This is using blueprint 0.6

thanks guys,
Adam

Original issue reported on code.google.com by adam.gre...@gmail.com on 14 Nov 2007 at 12:50

GoogleCodeExporter commented 8 years ago
Thanks, I'll look into it as soon as I get my hands on an IE7 machine. :)

Original comment by ola...@gmail.com on 18 Nov 2007 at 1:20

GoogleCodeExporter commented 8 years ago
haha!

Well, if I can help (or send screen shots or a real working example vs 
pseudo-code),
let me know.
Adam

Original comment by adam.gre...@gmail.com on 18 Nov 2007 at 9:05

GoogleCodeExporter commented 8 years ago
Hi adam, your solution works as spected, but there's a much simpler solution.

In your screen.css file just add the line:
.clear {display: inline-block;}
before the line:
.clear {display: block;}

and will work the same for any IE version BUT IE/Mac. That's why there's still 
needed
the "display:block" line after the "inline-block" 

If you take a look to the grid.css in lib/ there are such lines, but they are 
lost at
the compression to screen.css (OLAV: apparently for csstidy "inline-block" and
"block" are the same thing and they are blended into the smallest one).

Original comment by digita...@gmail.com on 21 Nov 2007 at 11:41

GoogleCodeExporter commented 8 years ago
Thanks, digitart1, this was apparently a problem with csstidy. This is fixed 
with the new compressor, which 
doesn't change values. :) Fixed for the next release.

Original comment by ola...@gmail.com on 13 Jan 2008 at 3:07